freebsd-dev/sys
Alex Richardson 0482d7c9e9 Fix fget_only_user() to return ENOTCAPABLE on a failed capsicum check
After eaad8d1303 four additional
capsicum-test tests started failing. It turns out this is because
fget_only_user() was returning EBADF on a failed capsicum check instead
of forwarding the return value of cap_check_inline() like
fget_unlocked_seq().

capsicum-test failures before this:
```
[  FAILED  ] 7 tests, listed below:
[  FAILED  ] Capability.OperationsForked
[  FAILED  ] Capability.NoBypassDAC
[  FAILED  ] Pdfork.OtherUserForked
[  FAILED  ] PipePdfork.WildcardWait
[  FAILED  ] OpenatTest.WithFlag
[  FAILED  ] ForkedOpenatTest_WithFlagInCapabilityMode._
[  FAILED  ] Select.LotsOFileDescriptorsForked
```
After:
```
[  FAILED  ] 3 tests, listed below:
[  FAILED  ] Capability.NoBypassDAC
[  FAILED  ] Pdfork.OtherUserForked
[  FAILED  ] PipePdfork.WildcardWait
```

Reviewed By:	mjg
MFC after:	1 week
Differential Revision: https://reviews.freebsd.org/D28691
2021-02-15 22:55:12 +00:00
..
amd64 linux: drop unneeded casts 2021-02-15 13:14:15 +00:00
arm arm32: Align arguments of sync_icache() syscall to cacheline size. 2021-02-09 12:53:09 +01:00
arm64 arm64: Add a SOC_BRCM_NS2 option 2021-02-10 21:15:50 +01:00
bsm Add aio_writev and aio_readv 2021-01-02 19:57:58 -07:00
cam cam: Properly find the sim in the assertion in xpt_pollwait(). 2021-02-11 14:06:58 -08:00
cddl arm64: Improve DDB backtrace support 2021-02-01 14:15:57 +00:00
compat epoll: Store epoll_event udata member in ext member of kevent. 2021-02-08 02:46:14 +03:00
conf Only require mac_veriexec for verified_exec 2021-02-14 09:20:41 -08:00
contrib zfs: Avoid updating the L2ARC device header unnecessarily 2021-02-15 10:56:08 +01:00
crypto armv8crypto: Extract GCM state into a structure 2021-02-08 09:19:10 -05:00
ddb ddb: add ability to print user registers 2021-01-08 14:53:06 -04:00
dev Fix for locking order reversal in USB audio driver, when using mmap(). 2021-02-14 20:32:33 +01:00
dts Remove DTS files for arm boards we don't support 2021-01-27 10:02:01 +00:00
fs Enforce net epoch in in6_selectsrc(). 2021-02-15 22:33:12 +00:00
gdb gdb(4): allow bulk write of registers 2020-12-23 14:37:05 -04:00
geom opencrypto: Introduce crypto_dispatch_async() 2021-02-08 09:19:19 -05:00
gnu Remove the old dts imported tree. 2021-01-15 20:09:55 +01:00
i386 Fix a typo. 2021-01-27 21:52:41 -08:00
isa
kern Fix fget_only_user() to return ENOTCAPABLE on a failed capsicum check 2021-02-15 22:55:12 +00:00
kgssapi opencrypto: Introduce crypto_dispatch_async() 2021-02-08 09:19:19 -05:00
libkern Restore the augmented strlen commentary 2021-02-08 19:15:21 +00:00
mips mips: fix NLM platforms breakage caused by e0a0a3ef 2021-01-31 23:56:22 -08:00
modules ZFS: fix assertions with INVARIANTS 2021-02-08 16:41:35 -07:00
net Remove now-unused RTF_RNH_LOCKED route flag. 2021-02-15 20:49:59 +00:00
net80211
netgraph netgraph/ng_bridge: Add counters for the first link, too 2021-02-10 19:05:37 +01:00
netinet Remove per-packet ifa refcounting from IPv6 fast path. 2021-02-15 22:33:12 +00:00
netinet6 Remove per-packet ifa refcounting from IPv6 fast path. 2021-02-15 22:33:12 +00:00
netipsec Revert "SO_RERROR indicates that receive buffer overflows should be handled as errors." 2021-02-08 22:32:32 +00:00
netpfil pf: Slightly relax pf_rule_addr validation 2021-02-14 12:07:31 +01:00
netsmb
nfs
nfsclient
nfsserver
nlm
ofed Fix mismerge in OFED update 2021-02-04 13:58:24 -05:00
opencrypto ktls: Avoid wakeups and locking for synchronous callbacks 2021-02-08 09:19:27 -05:00
powerpc powerpc64: Fix boot on virtual-mode OF (PowerMac G5) 2021-02-07 16:13:55 -06:00
riscv riscv: add SBI system reset extension 2021-01-27 19:19:54 -04:00
rpc nfs-over-tls: handle res.gid.gid_val correctly for memory allocation 2021-01-12 13:59:52 -08:00
security Convert remaining cap_rights_init users to cap_rights_init_one 2021-01-12 13:16:10 +00:00
sys lockmgr: shrink struct lock by 8 bytes on LP64 2021-02-15 13:57:25 +00:00
teken loader: implement framebuffer console 2021-01-02 21:41:36 +02:00
tests Enable running fib tests inside vnet jail. 2021-01-17 20:32:26 +00:00
tools syscalls.master: Add a new syscall type: RESERVED 2021-01-26 18:27:44 +00:00
ufs Fix bug 253158 - Panic: snapacct_ufs2: bad block - mksnap_ffs(8) crash 2021-02-11 21:31:16 -08:00
vm vm: Honour the "noreuse" flag to vm_page_unwire_managed() 2021-02-10 11:10:27 -05:00
x86 mca: Handle inconsistent CMCI capability reporting 2021-02-08 14:42:54 -05:00
xdr
xen xen: remove .swp file from public headers 2021-01-11 18:14:11 +01:00
Makefile