public class PGPEncryptor extends AbstractPGPEncryptor
构造器和说明 |
---|
PGPEncryptor() |
限定符和类型 | 方法和说明 |
---|---|
static String |
encrypt(String strToEncrtpt,
String pulicKeyFilePath)
encrypt String
|
static String |
encrypt(String strToEncrtpt,
String pulicKeyFilePath,
String outFile) |
static byte[] |
encryptByte(String strToEncrtpt,
String pulicKeyFilePath) |
protected static void |
writeToFile(byte[] byteData,
String fileName) |
getBytesFromFile, readPublicKey, readPublicKey, readSecretKey, readSecretKey
public static String encrypt(String strToEncrtpt, String pulicKeyFilePath) throws Exception
strToEncrtpt
- strToEncrtptpulicKeyFilePath
- pulicKeyFilePathException
- if cat not encryptpublic static String encrypt(String strToEncrtpt, String pulicKeyFilePath, String outFile) throws Exception
Exception
public static byte[] encryptByte(String strToEncrtpt, String pulicKeyFilePath) throws Exception
Exception
protected static void writeToFile(byte[] byteData, String fileName) throws IOException
IOException
Copyright © 2015 jiucai.org. All rights reserved.