Page MenuHomeFreeBSD

traceroute6: Fix rights for rcvsock
ClosedPublic

Authored by markj on Mar 31 2021, 10:41 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Apr 1, 2:06 AM
Unknown Object (File)
Mar 12 2024, 1:27 AM
Unknown Object (File)
Mar 12 2024, 1:27 AM
Unknown Object (File)
Mar 12 2024, 1:27 AM
Unknown Object (File)
Mar 12 2024, 1:27 AM
Unknown Object (File)
Mar 11 2024, 7:52 AM
Unknown Object (File)
Mar 8 2024, 4:18 AM
Unknown Object (File)
Feb 28 2024, 1:37 AM
Subscribers

Details

Summary
  • Always use distinct sockets for send and recv
  • Limit rights on the recv socket
  • Limit rights before entering capability mode

For ICMP6 we were using the same socket for both, and we limited rights
on the socket such that it's impossible to receive anything.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 38229
Build 35118: arc lint + arc unit

Event Timeline

zlei added inline comments.
usr.sbin/traceroute6/traceroute6.c
937

Copy paste typo

942

It looks good entering capability mode before limiting rights. So no need to adjust here.

After addressing @zlei.huang_gmail.com points - LGTM.

markj marked an inline comment as done.

Address feedback.

This revision was not accepted when it landed; it landed in state Needs Review.Apr 1 2021, 2:01 PM
This revision was automatically updated to reflect the committed changes.