Enter libcasper service to enter capability mode,and adjust how tftpd interacts with
socket,because it violates capability.
I reimplemented the underlying file operation with cap_fileargs.
Sponsored by: Google, Inc. (GSoC 2024)
Paths
| Differential D46281 Authored by hanslu952_gmail.com on Aug 13 2024, 11:54 AM.
Details Summary Enter libcasper service to enter capability mode,and adjust how tftpd interacts with Sponsored by: Google, Inc. (GSoC 2024) Test Plan Trivial:$ mkdir /tftproot $ cd /tftproot $ vim testfile $ tftp localhost tftp> get testfile Normal:$ cd /usr/tests/libexec/tftpd $ kyua test -k Kyuafile one case testing $ kyua debug -k Kyuafile functional:testcase Set up enotcapable to get coredump sysctl kern.trap_enotcap=1 sysctl kern.corefile= /tmp/coredumps/%N.core gdb executable corefile
Diff Detail
Event TimelineHerald added subscribers: jonathan, imp. · View Herald TranscriptAug 13 2024, 11:54 AM2024-08-13 11:54:01 (UTC+0) hanslu952_gmail.com requested review of this revision.Aug 13 2024, 11:54 AM2024-08-13 11:54:01 (UTC+0) Harbormaster completed remote builds in B59001: Diff 142037.Aug 13 2024, 11:54 AM2024-08-13 11:54:02 (UTC+0) hanslu952_gmail.com edited the summary of this revision. (Show Details)Aug 15 2024, 5:29 PM2024-08-15 17:29:42 (UTC+0)
Revision Contents
Diff 142037 libexec/tftpd/Makefile
libexec/tftpd/tftp-io.c
libexec/tftpd/tftpd.c
|