Page MenuHomeFreeBSD

ipsec: Validate the protocol identifier in ipsec4_ctlinput()
ClosedPublic

Authored by markj on Sep 9 2021, 5:11 PM.
Tags
None
Referenced Files
F93093795: D31890.id94949.diff
Sat, Sep 7, 6:50 AM
Unknown Object (File)
Sun, Sep 1, 10:10 PM
Unknown Object (File)
Sun, Sep 1, 1:38 AM
Unknown Object (File)
Thu, Aug 22, 12:26 AM
Unknown Object (File)
Mon, Aug 19, 11:43 AM
Unknown Object (File)
Thu, Aug 15, 10:15 AM
Unknown Object (File)
Jul 12 2024, 6:02 PM
Unknown Object (File)
Jun 9 2024, 7:35 AM
Subscribers

Details

Summary

key_allocsa() expects to handle only IPSec protocols and has an
assertion to this effect. However, ipsec4_ctlinput() has to handle
messages from ICMP unreachable packets and was not validating the
protocol number. In practice I believe such a packet would simply fail
to match any SADB entries and would thus be ignored.

Reported by: syzbot+6a9ef6fcfadb9f3877fe@syzkaller.appspotmail.com

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable