mikeboers/PyTomCrypt — pull request #27 by dvanduzer (2014-03-23 23:32:49+00:00)
Title: first pass at adding GCM support

I've only tested this with AES so far, and the additional authenticated
data probably isn't actually optional in this commit. I *have* verified
that encryption/decryption works in both directions when interacting with
cryptography.io's OpenSSL backend. So that's a plus.

See https://github.com/pyca/cryptography/issues/846 if interested in other details... The *internal* interface inconsistencies *within* TomCrypt and OpenSSL are confusing enough as it is, but maybe you have some other ideas. The EAX header and the GCM aad can possible use the same interface, but in GCM you can't add unencrypted data after adding the encrypted payload. Details.