Page MenuHomeFreeBSD

Move per-operation data out of the csession structure.
ClosedPublic

Authored by jhb on Jan 16 2018, 12:59 AM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Mar 30, 2:39 PM
Unknown Object (File)
Mon, Mar 30, 2:15 AM
Unknown Object (File)
Sat, Mar 28, 6:23 AM
Unknown Object (File)
Fri, Mar 27, 6:05 AM
Unknown Object (File)
Thu, Mar 26, 8:52 AM
Unknown Object (File)
Tue, Mar 24, 6:08 PM
Unknown Object (File)
Feb 7 2026, 11:11 PM
Unknown Object (File)
Feb 7 2026, 6:20 PM
Subscribers

Details

Summary

Create a struct cryptop_data which contains state needed for a single
symmetric crypto operation and move that state out of the session. This
closes a race with the CRYPTO_F_DONE flag that can result in use after
free.

PR: 218597

Test Plan
  • cryptocheck and cryptotest.py against cryptosoft0, ccr0, and aesni0.

Diff Detail

Lint
No Lint Coverage
Unit
No Test Coverage
Build Status
Buildable 14405
Build 14557: arc lint + arc unit

Event Timeline

kib added inline comments.
sys/opencrypto/cryptodev.c
1094

What is the purpose of this locking ?

This revision is now accepted and ready to land.Jan 17 2018, 9:29 AM
sys/opencrypto/cryptodev.c
1094

Just to avoid losing wakeups() with the loop at line 1050.

This revision was automatically updated to reflect the committed changes.