net/tls: Remove VLA usage
authorKees Cook <keescook@chromium.org>
Wed, 11 Apr 2018 00:52:34 +0000 (17:52 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 13 Apr 2018 01:46:10 +0000 (21:46 -0400)
commitb16520f7493d06d8ef6d4255bdfcf7a803d7874a
treeb3ef990644cc23ce82112531b9737a7618e7d97e
parent08ea556e14b56e9a49b19abd8e39f0c9e05582f2
net/tls: Remove VLA usage

In the quest to remove VLAs from the kernel[1], this replaces the VLA
size with the only possible size used in the code, and adds a mechanism
to double-check future IV sizes.

[1] https://lkml.kernel.org/r/CA+55aFzCG-zNmZwX4A2FQpadafLfEzK6CC=qPXydAacU1RqZWA@mail.gmail.com

Signed-off-by: Kees Cook <keescook@chromium.org>
Acked-by: Dave Watson <davejwatson@fb.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tls/tls_sw.c