Page MenuHomeFreeBSD

Don't indirect user pointers directly in two 802.11s ioctls.
ClosedPublic

Authored by jhb on Apr 24 2020, 8:22 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Jun 3, 7:38 AM
Unknown Object (File)
Sat, May 25, 11:34 PM
Unknown Object (File)
Thu, May 23, 9:18 PM
Unknown Object (File)
May 7 2024, 9:14 AM
Unknown Object (File)
Mar 31 2024, 7:22 PM
Unknown Object (File)
Mar 11 2024, 7:10 AM
Unknown Object (File)
Feb 8 2024, 2:16 PM
Unknown Object (File)
Jan 14 2024, 12:11 AM
Subscribers

Details

Summary

IEEE80211_MESH_RTCMD_ADD was invoking memcmp() to validate the
supplied address directly on the user pointer rather than first doing
a copyin() and validating the copied value.

IEEE80211_MESH_RTCMD_DELETE was passing the user pointer directly to
ieee80211_mesh_rt_del() rather than copying the user buffer into a
temporary kernel buffer.

Test Plan
  • found in CheriBSD where user pointers and kernel pointers are different types currently
  • compile tested only, no run-time testing

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 30713
Build 28442: arc lint + arc unit

Event Timeline

This revision is now accepted and ready to land.Apr 24 2020, 8:41 PM

These should have been reported by SMAP, but apparently nobody uses mesh ?

sys/net80211/ieee80211_mesh.c
3580

error != 0

In D24562#540481, @kib wrote:

These should have been reported by SMAP, but apparently nobody uses mesh ?

I suspect that no one uses it, yes.

jhb marked an inline comment as done.Apr 24 2020, 10:10 PM