isislovecruft / python-gnupg

A modified version of python-gnupg, including security patches, extensive documentation, and extra features.
Other
426 stars 171 forks source link

encrypt() with recipient's email address (instead of key fingerprint)? #285

Open johnnyutahh opened 2 years ago

johnnyutahh commented 2 years ago

Question: How to Python gnupg (GPG) encrypt with recipient's email address rather than their fingerprint? https://stackoverflow.com/questions/72355601/how-to-python-gnupg-gpg-encrypt-with-recipients-email-address-rather-than-the

fwiw, code excerpt from _check_option():

        :param str arg: The arguments which will be passed to the GnuPG
                        process, and, optionally their corresponding values.
                        The values are any additional arguments following the
                        GnuPG option or flag. For example, if we wanted to
                        pass ``"--encrypt --recipient isis@leap.se"`` to
                        GnuPG, then ``"--encrypt"`` would be an arg without a
                        value, and ``"--recipient"`` would also be an arg,
                        with a value of ``"isis@leap.se"``.
johnnyutahh commented 2 years ago

The solution seems to be to use python-gnupg over the pretty_bad_protocol module (whose last update was 2018):

https://stackoverflow.com/a/72355824/605356

Is it time to mark this project as obsoleted in it's README?

johnnyutahh commented 1 year ago

Is it time to mark this project as obsoleted in it's README?

(Details above.)

uncleurdnot commented 1 year ago

This project hasnt been updated since 2018, and doesnt reflect the working documentation. It should be marked as obsolete.

Just spent 3 days debugging why things weren't working when I realized pip grabbed this version instead of https://github.com/vsajip/python-gnupg