mirror of
https://github.com/opnsense/src.git
synced 2026-05-19 16:35:42 -04:00
cryptodev: Permit CIOCCRYPT for AEAD ciphers.
A request without AAD for an AEAD cipher can be submitted via
CIOCCRYPT rather than CIOCCRYPTAEAD.
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D32108
(cherry picked from commit 70dbebea12)
This commit is contained in:
parent
38b8a2be5c
commit
ac648e3aff
1 changed files with 7 additions and 0 deletions
|
|
@ -929,6 +929,13 @@ cryptodev_op(struct csession *cse, const struct crypt_op *cop)
|
|||
goto bail;
|
||||
}
|
||||
break;
|
||||
case CSP_MODE_AEAD:
|
||||
if (cse->ivsize != 0 && cop->iv == NULL) {
|
||||
SDT_PROBE1(opencrypto, dev, ioctl, error, __LINE__);
|
||||
error = EINVAL;
|
||||
goto bail;
|
||||
}
|
||||
/* FALLTHROUGH */
|
||||
case CSP_MODE_ETA:
|
||||
switch (cop->op) {
|
||||
case COP_ENCRYPT:
|
||||
|
|
|
|||
Loading…
Reference in a new issue