Skip to content

Conversation

@tiran
Copy link
Member

@tiran tiran commented Mar 29, 2022

Copy link
Member

@gpshead gpshead left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like where this is heading.

@gpshead
Copy link
Member

gpshead commented Feb 6, 2023

Performance isn't looking too hot for the Linux Kernel Crypto API on my zen2:

cpython (bpo-47102-linux-kcapi)$ ../b/python -m timeit -s 'import hashlib,hmac; d = b"0 1 2 3 5 2"*1000000; ksha2 = hashlib._LinuxKCAPIHash("sha256"); sha2 = hashlib.sha256(); h = sha2' 'h.update(d)'
50 loops, best of 5: 5.24 msec per loop
cpython (bpo-47102-linux-kcapi)$ ../b/python -m timeit -s 'import hashlib,hmac; d = b"0 1 2 3 5 2"*1000000; ksha2 = hashlib._LinuxKCAPIHash("sha256"); sha2 = hashlib.sha256(); h = ksha2' 'h.update(d)'
10 loops, best of 5: 38.6 msec per loop

the socket based kernel crypto API is 7x slower than OpenSSL.

@erlend-aasland erlend-aasland changed the title bpo-47102: Linux Kernel CryptoAPI bindings (WIP) gh-91258: Linux Kernel CryptoAPI bindings Jan 4, 2024
@erlend-aasland
Copy link
Contributor

Closing, as the linked issue is closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants