diff options
author | Evgeniy Khramtsov <2khramtsov@gmail.com> | 2021-02-01 19:03:57 +0000 |
---|---|---|
committer | Kristof Provost <kp@FreeBSD.org> | 2021-02-01 20:25:11 +0000 |
commit | 682c31db4ecfb8fc6cac0e8ad4945c03379ea3d1 (patch) | |
tree | 16bbec7039fd9aeced804d32a49227de94fad793 /sbin/ipfw/ipfw2.c | |
parent | 38bfc6dee33bedb290e1ea2540f97a86fe3caee0 (diff) | |
download | src-682c31db4ecfb8fc6cac0e8ad4945c03379ea3d1.tar.gz src-682c31db4ecfb8fc6cac0e8ad4945c03379ea3d1.zip |
ipfw(8) crashes when ext6hdr option is omitted
Verify that the option is passed, error out if it's not.
The problem can be trivially triggered with `ipfw add allow ext6hdr`.
PR: 253169
Reviewed by: kp@
MFC after: 3 days
Differential Revision: https://reviews.freebsd.org/D28447
Diffstat (limited to 'sbin/ipfw/ipfw2.c')
-rw-r--r-- | sbin/ipfw/ipfw2.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sbin/ipfw/ipfw2.c b/sbin/ipfw/ipfw2.c index 67303d8bb1e7..19f7f331091d 100644 --- a/sbin/ipfw/ipfw2.c +++ b/sbin/ipfw/ipfw2.c @@ -4961,6 +4961,7 @@ read_options: break; case TOK_EXT6HDR: + NEED1("missing extension header"); fill_ext6hdr( cmd, *av ); av++; break; |