Pawel Jakub Dawidek f9b20fc804 MFp4 @229086:
Make use of Capsicum to protect kdump(1), as it might be used to parse data
from untrusted sources:

- Sandbox kdump(1) using capability mode.
- Limit stdin descriptor (where opened file is moved to) to only
  CAP_READ and CAP_FSTAT rights.
- Limit stdout descriptor to only CAP_WRITE, CAP_FSTAT and CAP_IOCTL.
  Plus limit allowed ioctls to TIOCGETA only, which is needed for
  isatty() to work.
- Limit stderr descriptor to only CAP_WRITE and CAP_FSTAT. In addition
  if the -s option is not given, grant CAP_IOCTL right, but allow for
  TIOCGWINSZ ioctl only, as we need screen width to dump the data.
- Before entering capability mode call catopen("libc", NL_CAT_LOCALE),
  which opens message catalogs and caches data, so that strerror(3)
  and strsignal(3) can work in a sandbox.

Sponsored by:	The FreeBSD Foundation
Discussed with:	rwatson
2013-05-28 21:25:28 +00:00
..
2013-05-10 20:02:15 +00:00
2013-03-22 13:36:03 +00:00
2013-02-28 01:22:14 +00:00
2013-03-11 13:08:32 +00:00
2013-05-11 13:46:05 +00:00
2013-03-04 02:21:06 +00:00
2013-05-23 18:07:01 +00:00
2013-05-28 21:25:28 +00:00
2013-02-19 13:32:26 +00:00
2013-05-25 15:36:15 +00:00
2013-05-25 15:36:15 +00:00
2013-05-25 07:17:16 +00:00
2013-04-11 19:05:24 +00:00
2013-03-17 06:36:04 +00:00
2013-03-16 22:37:56 +00:00
2013-03-22 13:36:03 +00:00
2013-04-23 13:03:17 +00:00
2013-03-07 23:44:35 +00:00
2013-03-28 20:33:07 +00:00
2013-05-12 22:22:12 +00:00
2013-05-10 03:49:05 +00:00
2013-03-07 23:44:35 +00:00