[python-win32] AES based win32crypt lib for python3

Tim Roberts timr at probo.com
Wed Oct 7 02:36:36 EDT 2020


On Oct 5, 2020, at 8:24 AM, Raja Sekhar <royalraja at gmail.com> wrote:
> 
> I have seen win32crypt lib for python, And it is built on DES algorithm.

Sort of.  Triple-DES is used to protect the master key derived from the credentials, but I’ve never seen Microsoft say what they actually use to encrypt the data blob.


> I am searching for such library in Python using  AES Algorithm. I have gone through pyAesCrypt, Crypto.Cipher  which is taking an explicit key for encryption. 
> I would be grateful if you could help me to find a library in python3,
> which uses AES encryption library similar to win32crypt which encrypts data using a session key derived from current user's logon credentials  as in ‘CryptProtectData’
> function.

Nope.  Remember that win32crypt is nothing but a thin layer that calls the Windows CryptProtectData API.  The API does a remote procedure call into the Windows LSA (Local Security Authority) to get access to the login credentials through an undocumented internal function.

You can certainly find AES encryption for Python, but it’s not going to use the login credentials.
— 
Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-win32/attachments/20201006/085ff958/attachment.html>


More information about the python-win32 mailing list