public class GPG extends Object
| Constructor and Description |
|---|
GPG(String gpgFilename,
LogChannelInterface logInterface)
Constructs a new GnuPG
|
| Modifier and Type | Method and Description |
|---|---|
String |
decrypt(String cryptedText,
String passPhrase)
Decrypt a string
|
void |
decryptFile(org.apache.commons.vfs2.FileObject cryptedFilename,
String passPhrase,
org.apache.commons.vfs2.FileObject decryptedFilename)
Decrypt a file
|
void |
decryptFile(String cryptedFilename,
String passPhrase,
String decryptedFilename)
Decrypt a file
|
String |
encrypt(String plainText,
String keyID)
Encrypt a string
|
void |
encryptFile(org.apache.commons.vfs2.FileObject filename,
String userID,
org.apache.commons.vfs2.FileObject cryptedFilename,
boolean asciiMode)
Encrypt a file
|
void |
encryptFile(String filename,
String userID,
String cryptedFilename,
boolean asciiMode)
Encrypt a file
|
String |
getGpgExeFile()
Returns GPG program location
|
String |
sign(String stringToSign,
String passPhrase)
Sign
|
String |
signAndEncrypt(String plainText,
String userID,
String passPhrase)
Signs and encrypts a string
|
void |
signAndEncryptFile(org.apache.commons.vfs2.FileObject file,
String userID,
org.apache.commons.vfs2.FileObject cryptedFile,
boolean asciiMode)
Sign and encrypt a file
|
void |
signAndEncryptFile(String filename,
String userID,
String cryptedFilename,
boolean asciiMode)
Sign and encrypt a file
|
void |
signFile(org.apache.commons.vfs2.FileObject file,
String userID,
org.apache.commons.vfs2.FileObject signedFile,
boolean asciiMode)
Sign a file
|
void |
signFile(String filename,
String userID,
String signedFilename,
boolean asciiMode)
Sign a file
|
String |
toString() |
void |
verifyDetachedSignature(org.apache.commons.vfs2.FileObject signatureFile,
org.apache.commons.vfs2.FileObject originalFile)
Verify a signature for detached file
|
void |
verifyDetachedSignature(String signatureFilename,
String originalFilename)
Verify a signature for detached file
|
void |
verifySignature(org.apache.commons.vfs2.FileObject filename)
Verify a signature
|
void |
verifySignature(String filename)
Verify a signature
|
public GPG(String gpgFilename, LogChannelInterface logInterface) throws KettleException
gpgFilename - gpg program locationlogInterface - LogChannelInterfaceKettleExceptionpublic String getGpgExeFile()
public void decryptFile(org.apache.commons.vfs2.FileObject cryptedFilename,
String passPhrase,
org.apache.commons.vfs2.FileObject decryptedFilename)
throws KettleException
cryptedFilename - crypted filenamepassPhrase - passphrase for the personal private key to sign withdecryptedFilename - decrypted filenameKettleExceptionpublic void decryptFile(String cryptedFilename, String passPhrase, String decryptedFilename) throws KettleException
cryptedFilename - crypted filenamepassPhrase - passphrase for the personal private key to sign withdecryptedFilename - decrypted filenameKettleExceptionpublic void encryptFile(org.apache.commons.vfs2.FileObject filename,
String userID,
org.apache.commons.vfs2.FileObject cryptedFilename,
boolean asciiMode)
throws KettleException
filename - file to encryptuserID - specific user id keycryptedFilename - crypted filenameasciiMode - output ASCII fileKettleExceptionpublic void encryptFile(String filename, String userID, String cryptedFilename, boolean asciiMode) throws KettleException
filename - file to encryptuserID - specific user id keycryptedFilename - crypted filenameasciiMode - output ASCII fileKettleExceptionpublic void signAndEncryptFile(org.apache.commons.vfs2.FileObject file,
String userID,
org.apache.commons.vfs2.FileObject cryptedFile,
boolean asciiMode)
throws KettleException
file - file to encryptuserID - specific user id keycryptedFile - crypted filenameasciiMode - output ASCII fileKettleExceptionpublic void signAndEncryptFile(String filename, String userID, String cryptedFilename, boolean asciiMode) throws KettleException
filename - file to encryptuserID - specific user id keycryptedFilename - crypted filenameasciiMode - output ASCII fileKettleExceptionpublic void signFile(String filename, String userID, String signedFilename, boolean asciiMode) throws KettleException
filename - file to encryptuserID - specific user id keycryptedFilename - crypted filenameasciiMode - output ASCII fileKettleExceptionpublic void signFile(org.apache.commons.vfs2.FileObject file,
String userID,
org.apache.commons.vfs2.FileObject signedFile,
boolean asciiMode)
throws KettleException
file - file to encryptuserID - specific user id keysignedFile - crypted filenameasciiMode - output ASCII fileKettleExceptionpublic void verifySignature(org.apache.commons.vfs2.FileObject filename)
throws KettleException
filename - filenameKettleExceptionpublic void verifySignature(String filename) throws KettleException
filename - filenameKettleExceptionpublic void verifyDetachedSignature(String signatureFilename, String originalFilename) throws KettleException
signatureFilename - filenameoriginalFilenamefill - this value in case of detached signatureKettleExceptionpublic void verifyDetachedSignature(org.apache.commons.vfs2.FileObject signatureFile,
org.apache.commons.vfs2.FileObject originalFile)
throws KettleException
signatureFile - filenameoriginalFile - fill this value in case of detached signatureKettleExceptionpublic String encrypt(String plainText, String keyID) throws KettleException
plainText - input string to encryptkeyID - key ID of the key in GnuPG's key database to encrypt withKettleExceptionpublic String signAndEncrypt(String plainText, String userID, String passPhrase) throws KettleException
plainText - input string to encryptuserID - key ID of the key in GnuPG's key database to encrypt withpassPhrase - passphrase for the personal private key to sign withKettleExceptionpublic String sign(String stringToSign, String passPhrase) throws KettleException
stringToSign - input string to signpassPhrase - passphrase for the personal private key to sign withKettleExceptionpublic String decrypt(String cryptedText, String passPhrase) throws KettleException
cryptedText - input string to decryptpassPhrase - passphrase for the personal private key to sign withKettleExceptionCopyright © 2018 Hitachi Vantara. All rights reserved.