0

I'm using Python 3.12 in an AWS Lambda function to decrypt PGP encrypted files. I'm using the python-gnupg version 0.6.0 library to do this. It decrypts files fine on my development Mac but fails when run in the AWS environment. I figured out this makes sense because the python-gnupg library is a wrapper around the system level GnuPG binaries. These exist on my Mac but aren't present in the AWS execution environment of the lambda function.

Does anyone have suggestions, ideas or pointers how I might go about solving this problem?

4
  • Are you not able to install GnuPG on the AWS environment? I was just skimming through the Lambda FAQ earlier today and it explicitly states that it's possible. Commented Mar 10 at 18:22
  • I think this has been incorrectly migrated to Superuser.com. It's certainly not Electrical Engineering, but it's also not right here. Commented Mar 10 at 18:55
  • Answered on StackOverflow: stackoverflow.com/questions/67782720/…
    – discape
    Commented Mar 11 at 8:00
  • That stackoverflow response you reference uses a pretty old version of Python. I've resolved this be deploying my Python lambda as a Docker image, and installing GnuPG (the binary, system level stuff) in the mage.
    – writes_on
    Commented Mar 11 at 18:29

0

Browse other questions tagged .