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
- LogChannelInterfaceKettleException
public 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 filenameKettleException
public void decryptFile(String cryptedFilename, String passPhrase, String decryptedFilename) throws KettleException
cryptedFilename
- crypted filenamepassPhrase
- passphrase for the personal private key to sign withdecryptedFilename
- decrypted filenameKettleException
public 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 fileKettleException
public void encryptFile(String filename, String userID, String cryptedFilename, boolean asciiMode) throws KettleException
filename
- file to encryptuserID
- specific user id keycryptedFilename
- crypted filenameasciiMode
- output ASCII fileKettleException
public 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 fileKettleException
public void signAndEncryptFile(String filename, String userID, String cryptedFilename, boolean asciiMode) throws KettleException
filename
- file to encryptuserID
- specific user id keycryptedFilename
- crypted filenameasciiMode
- output ASCII fileKettleException
public void signFile(String filename, String userID, String signedFilename, boolean asciiMode) throws KettleException
filename
- file to encryptuserID
- specific user id keycryptedFilename
- crypted filenameasciiMode
- output ASCII fileKettleException
public 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 fileKettleException
public void verifySignature(org.apache.commons.vfs2.FileObject filename) throws KettleException
filename
- filenameKettleException
public void verifySignature(String filename) throws KettleException
filename
- filenameKettleException
public void verifyDetachedSignature(String signatureFilename, String originalFilename) throws KettleException
signatureFilename
- filenameoriginalFilenamefill
- this value in case of detached signatureKettleException
public 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 signatureKettleException
public 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 withKettleException
public 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 withKettleException
public String sign(String stringToSign, String passPhrase) throws KettleException
stringToSign
- input string to signpassPhrase
- passphrase for the personal private key to sign withKettleException
public String decrypt(String cryptedText, String passPhrase) throws KettleException
cryptedText
- input string to decryptpassPhrase
- passphrase for the personal private key to sign withKettleException
Copyright © 2018 Hitachi Vantara. All rights reserved.