freebsd-dev/lib/libsysdecode
Mark Johnston 869199d992 libsysdecode: Fix decoding of Capsicum rights
Capsicum rights are a bit tricky since some of them are subsets of
others, and one can have rights R1 and R2 such that R1 is a subset of
R2, but there is no collection of named rights whose union is R2.  So,
they don't behave like most other flag sets.  sysdecode_cap_rights(3)
does not handle this properly and so can emit misleading decodings.

Try to fix all of these problems:
- Include composite rights in the caprights table.
- Use a constructor to sort the caprights table such that "larger"
  rights appear first and thus are matched first.
- Don't print rights that are a subset of rights already printed, so as
  to minimize the length of the output.
- Print a trailing message if some of the specific rights are not
  matched by the table.

PR:		263165
Reviewed by:	pauamma_gundo.com (doc), jhb, emaste
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D34874
2022-04-13 10:51:30 -04:00
..
errno.c Drop cloudabi 2021-09-22 00:18:44 +03:00
flags.c libsysdecode: Fix decoding of Capsicum rights 2022-04-13 10:51:30 -04:00
Makefile Retire procfs-based process debugging. 2020-04-01 19:22:09 +00:00
Makefile.depend Update libssp paths in various Makefile.depend* files 2020-01-06 18:15:55 +00:00
mkioctls Fix compilation of libsysdecode after r365522, should have been part of it. 2020-09-09 22:18:44 +00:00
mktables libsysdecode: Fix decoding of Capsicum rights 2022-04-13 10:51:30 -04:00
signal.c Drop "All rights reserved" from my copyright statements. 2019-03-06 22:11:45 +00:00
syscallnames.c libsysdecode: Decode FreeBSD32 syscalls on arm64. 2021-09-23 00:24:50 +02:00
sysdecode_abi_to_freebsd_errno.3 Drop "All rights reserved" from my copyright statements. 2019-03-06 22:11:45 +00:00
sysdecode_cap_rights.3 libsysdecode: Fix decoding of Capsicum rights 2022-04-13 10:51:30 -04:00
sysdecode_cmsg_type.3 Add support for decoding the type of a cmsg. 2018-01-15 10:59:04 +00:00
sysdecode_enum.3 sysdecode_enum.3: Fix a typo: SIGBTRAP -> SIGTRAP. 2021-10-05 14:55:18 -07:00
sysdecode_fcntl_arg.3 Drop "All rights reserved" from my copyright statements. 2019-03-06 22:11:45 +00:00
sysdecode_ioctlname.3 Drop "All rights reserved" from my copyright statements. 2019-03-06 22:11:45 +00:00
sysdecode_kevent.3 Drop "All rights reserved" from my copyright statements. 2019-03-06 22:11:45 +00:00
sysdecode_mask.3 fd: add close_range(..., CLOSE_RANGE_CLOEXEC) 2022-03-03 17:21:58 +00:00
sysdecode_quotactl_cmd.3 Drop "All rights reserved" from my copyright statements. 2019-03-06 22:11:45 +00:00
sysdecode_sctp_sinfo_flags.3 Add a function is decode the sinfo_flags of struct sctp_sndrcvinfo. 2018-01-14 14:27:42 +00:00
sysdecode_sigcode.3 Drop "All rights reserved" from my copyright statements. 2019-03-06 22:11:45 +00:00
sysdecode_socket_protocol.3 Drop "All rights reserved" from my copyright statements. 2019-03-06 22:11:45 +00:00
sysdecode_sockopt_name.3 Drop "All rights reserved" from my copyright statements. 2019-03-06 22:11:45 +00:00
sysdecode_syscallnames.3 Drop "All rights reserved" from my copyright statements. 2019-03-06 22:11:45 +00:00
sysdecode_utrace.3 Drop "All rights reserved" from my copyright statements. 2019-03-06 22:11:45 +00:00
sysdecode.3 sysdecode.3: Remove documentation of CloudABI ABIs. 2021-09-22 17:02:17 -07:00
sysdecode.h fd: add close_range(..., CLOSE_RANGE_CLOEXEC) 2022-03-03 17:21:58 +00:00
utrace.c Renumber copyright clause 4 2017-02-28 23:42:47 +00:00