Skip to content

Instantly share code, notes, and snippets.

@philippTheCat
Created October 28, 2011 21:18
Show Gist options
  • Save philippTheCat/1323591 to your computer and use it in GitHub Desktop.
Save philippTheCat/1323591 to your computer and use it in GitHub Desktop.
key_friend is imported ASCII of the public Key:
-----BEGIN PGP PRIVATE KEY BLOCK-----
Version: GnuPG v1.4.11 (GNU/Linux)
lQOYBE6qnEkBCACevD9JFYzcnW1sjfZUrWywtC3dE3pKSE5Ev/yFHk1aS0Y8bhdq
.
.
.
A5AythtbrHSGsmKg+XLFZebC3TV1UaJROKmdUrcO3w==
=LEXo
-----END PGP PRIVATE KEY BLOCK-----
#importing key
self.key_friend = self.gpg.import_keys(key_friend)
#encrypting
crypt = self.gpg.encrypt(message,self.key_friend)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment