Esempio n. 1
0
 public PGPKeys(IPGPKeyring public_keyring, IPGPKeyring private_keyring, IPGPKeyring master_keyring)
 {
     _public_keyring = public_keyring;
     _master_keyring = master_keyring;
     _private_keyring = private_keyring;
     _master_keyring.ArmorBoundary = "";
 }
Esempio n. 2
0
 public IPGPReader SetDecrypter(string passphrase, IPGPKeyring master,
     string dest_path, TSBPGPPassphraseEvent onPassphrase)
 {
     _decrypter.KeyPassphrase = passphrase;
     _decrypter.VerifyingKeys = master;
     _decrypter.DecryptingKeys = master;
     _decrypter.OnPassphrase +=  onPassphrase;
     _decrypter.OutputFile = dest_path;
     return GetDecrypter();
 }
Esempio n. 3
0
 public IPGPWriter SetEncrypter(IPGPKeyring their_public, IPGPKeyring our_private,
     string passphrase, TSBPGPKeyPassphraseEvent keyPassphrase)
 {
     _encrypter.OnKeyPassphrase +=   keyPassphrase;
     _encrypter.EncryptingKeys = their_public;
     _encrypter.SigningKeys = our_private;
     _encrypter.Passphrases.Clear();
     _encrypter.Passphrases.Add(passphrase);
     _encrypter.EncryptionType = TSBPGPEncryptionType.etPassphrase;
     return _encrypter;
 }
Esempio n. 4
0
 public IPGPWriter GetEncrypter(IPGPKeyring keys)
 {
     _encrypter.EncryptingKeys = keys;
     return _encrypter;
 }