Page MenuHomeFreeBSD

aesni: Avoid modifying session keys in hmac_update()
ClosedPublic

Authored by markj on Apr 27 2021, 12:19 AM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Aug 13, 8:23 PM
Unknown Object (File)
Thu, Aug 13, 1:00 PM
Unknown Object (File)
Thu, Aug 13, 12:30 PM
Unknown Object (File)
Wed, Aug 12, 8:12 AM
Unknown Object (File)
Mon, Aug 10, 7:00 PM
Unknown Object (File)
Sun, Aug 9, 3:42 PM
Unknown Object (File)
Sat, Aug 8, 5:32 AM
Unknown Object (File)
Mon, Jul 27, 3:02 AM
Subscribers
None

Details

Summary

Otherwise aesni_process() is not thread-safe for AES+SHA-HMAC
transforms, since hmac_update() updates the caller-supplied key directly
to create the derived key. Use a buffer on the stack to store a copy of
the key used for computing inner and outer digests.

Note that this applies to stable/12 only.

Diff Detail

Repository
rG FreeBSD src repository
Lint
No Lint Coverage
Unit
No Test Coverage
Build Status
Buildable 38878
Build 35767: arc lint + arc unit

Event Timeline

markj created this revision.
This revision is now accepted and ready to land.Apr 27 2021, 2:09 PM