Gleb Smirnoff
eb8dcdeac2
jail: network epoch protection for IP address lists
...
Now struct prison has two pointers (IPv4 and IPv6) of struct
prison_ip type. Each points into epoch context, address count
and variable size array of addresses. These structures are
freed with network epoch deferred free and are not edited in
place, instead a new structure is allocated and set.
While here, the change also generalizes a lot (but not enough)
of IPv4 and IPv6 processing. E.g. address family agnostic helpers
for kern_jail_set() are provided, that reduce v4-v6 copy-paste.
The fast-path prison_check_ip[46]_locked() is also generalized
into prison_ip_check() that can be executed with network epoch
protection only.
Reviewed by: jamie
Differential revision: https://reviews.freebsd.org/D33339
2021-12-26 10:45:50 -08:00
..
2021-11-24 11:26:45 -07:00
2020-09-01 22:12:58 +00:00
2020-03-25 23:12:43 +00:00
2021-12-08 08:52:56 +01:00
2020-02-28 16:05:18 +00:00
2021-12-17 12:38:34 +01:00
2021-08-02 15:50:32 -06:00
2021-12-05 23:00:25 +01:00
2021-12-05 23:00:25 +01:00
2021-03-26 19:00:22 -03:00
2020-07-25 07:48:20 +00:00
2019-05-20 00:38:23 +00:00
2021-02-15 13:57:25 +00:00
2021-08-08 10:42:24 -04:00
2020-11-07 16:57:53 +00:00
2019-03-06 22:11:45 +00:00
2020-07-25 10:29:48 +00:00
2019-12-23 20:18:05 +00:00
2020-03-07 00:55:46 +00:00
2019-03-15 22:39:55 +00:00
2020-09-01 22:12:58 +00:00
2020-02-11 18:48:07 +00:00
2021-03-18 10:44:01 +00:00
2021-12-09 13:17:13 -08:00
2021-12-17 12:38:34 +01:00
2021-07-28 13:21:12 +03:00
2020-12-25 20:43:09 +02:00
2020-04-14 20:30:48 +00:00
2021-11-24 11:26:44 -07:00
2021-08-27 11:52:26 +03:00
2021-08-22 23:00:42 +12:00
2021-11-24 11:26:45 -07:00
2019-10-15 19:44:43 +00:00
2021-04-29 11:39:02 -04:00
2021-07-28 13:50:09 -06:00
2021-11-24 11:26:45 -07:00
2021-08-08 10:42:24 -04:00
2021-09-15 09:03:17 -07:00
2021-11-24 11:26:45 -07:00
2021-11-18 23:26:33 -07:00
2021-12-07 20:29:26 +01:00
2021-08-16 23:24:05 +03:00
2020-09-01 22:12:58 +00:00
2020-04-21 17:13:06 +00:00
2019-06-24 20:34:53 +00:00
2021-04-18 11:19:15 -06:00
2021-09-17 20:29:55 +03:00
2020-11-09 00:04:58 +00:00
2020-09-01 22:12:58 +00:00
2020-09-14 05:58:12 +00:00
2021-09-15 09:03:17 -07:00
2021-12-09 17:04:57 -07:00
2020-01-22 05:47:59 +00:00
2021-08-08 10:42:24 -04:00
2020-08-01 06:31:58 +00:00
2021-09-07 09:51:48 -06:00
2020-09-01 22:12:58 +00:00
2020-09-01 22:12:58 +00:00
2021-03-21 11:55:52 -07:00
2019-03-12 04:49:47 +00:00
2020-09-01 22:12:58 +00:00
2021-12-10 04:54:48 +02:00
2021-09-03 22:18:51 -04:00
2020-06-14 06:58:58 +00:00
2020-12-31 10:29:44 -05:00
2020-03-06 19:09:01 +00:00
2019-01-29 11:04:17 +00:00
2020-01-22 23:28:42 +00:00
2021-12-05 23:00:25 +01:00
2019-11-21 11:22:08 +00:00
2019-03-25 13:50:38 +00:00
2021-11-24 02:37:51 -07:00
2020-10-24 21:07:10 +00:00
2019-10-15 23:21:52 +00:00
2018-11-23 22:24:59 +00:00
2020-10-27 06:43:24 +00:00
2019-08-13 20:06:55 +00:00
2021-08-08 10:42:24 -04:00
2021-08-16 00:59:56 -05:00
2021-12-05 23:00:25 +01:00
2020-11-23 18:27:21 +00:00
2021-07-03 20:06:48 +03:00
2021-07-03 20:06:48 +03:00
2021-10-17 02:37:13 +03:00
2021-10-17 02:37:13 +03:00
2021-12-06 20:46:49 +02:00
2021-10-17 02:37:13 +03:00
2021-09-20 22:02:35 -06:00
2021-12-02 14:45:04 -08:00
2020-08-28 17:49:56 +00:00
2021-11-23 13:29:24 -07:00
2020-12-27 12:57:26 +02:00
2021-04-18 11:14:17 -06:00
2021-05-22 09:59:00 +01:00
2020-09-01 22:12:58 +00:00
2021-12-06 11:28:03 +01:00
2021-12-06 22:18:09 +02:00
2020-09-01 22:12:58 +00:00
2021-11-24 02:38:09 -07:00
2021-12-17 12:38:35 +01:00
2020-09-09 22:12:51 +00:00
2021-01-27 13:51:26 +00:00
2021-08-08 10:42:24 -04:00
2021-04-12 16:13:33 +02:00
2021-02-02 09:53:39 +00:00
2020-11-29 19:38:03 +00:00
2020-09-01 22:12:58 +00:00
2020-11-08 04:24:29 +00:00
2021-11-17 15:51:40 -08:00
2021-10-28 20:49:21 +03:00
2021-03-10 12:35:16 +01:00
2021-05-03 13:24:30 -04:00
2021-04-30 17:43:45 +03:00
2020-09-01 22:12:58 +00:00
2020-09-01 22:12:58 +00:00
2021-12-26 10:45:50 -08:00
2019-01-29 11:04:17 +00:00
2021-03-29 12:05:43 -03:00
2021-07-18 23:06:19 -05:00
2019-02-04 21:28:25 +00:00
2021-11-12 18:56:58 +00:00
2021-11-19 15:05:53 -04:00
2021-04-17 23:46:18 -06:00
2021-02-28 01:27:29 +02:00
2020-09-01 22:12:58 +00:00
2021-10-21 09:37:17 -07:00
2019-12-29 21:16:03 +00:00
2021-04-18 11:14:17 -06:00
2021-05-22 19:53:40 +00:00
2021-12-02 14:45:04 -08:00
2020-12-01 22:28:01 +00:00
2021-05-07 14:31:08 -04:00
2021-07-29 09:46:25 -04:00
2021-05-23 17:55:27 +00:00
2020-09-01 22:12:58 +00:00
2019-10-10 18:52:24 +00:00
2020-07-22 12:30:31 +00:00
2021-05-23 17:55:27 +00:00
2020-10-28 13:46:11 +00:00
2021-08-23 18:38:05 +00:00
2021-11-04 18:53:49 +01:00
2021-09-11 20:04:52 +08:00
2020-09-02 18:12:47 +00:00
2020-09-09 22:12:51 +00:00
2021-11-12 18:56:58 +00:00
2021-12-09 18:09:53 +00:00
2021-12-10 20:06:28 +00:00
2019-01-18 22:20:29 +00:00
2021-08-11 16:33:41 -04:00
2021-12-10 23:35:53 -05:00
2020-09-01 22:12:58 +00:00
2021-10-27 18:58:36 -07:00
2021-11-25 22:50:42 +00:00
2021-12-15 20:54:57 -07:00
2021-08-14 10:59:03 -04:00
2021-04-18 11:14:17 -06:00
2020-07-24 17:32:10 +00:00
2020-04-19 00:12:30 +00:00
2021-02-21 11:38:21 +02:00
2021-11-25 19:26:04 -05:00
2019-06-25 19:55:42 +00:00
2021-01-05 10:03:05 +00:00
2021-04-28 23:00:31 +12:00
2020-09-01 22:12:58 +00:00
2021-10-18 08:41:17 -06:00
2021-12-10 04:54:48 +02:00
2020-08-13 20:48:14 +00:00
2021-12-08 18:45:41 +00:00
2021-09-17 15:42:01 +03:00
2021-08-17 21:56:05 +02:00
2021-09-16 20:11:27 +03:00
2021-04-18 11:14:17 -06:00
2021-12-15 13:28:33 +02:00
2020-10-28 13:46:11 +00:00
2021-11-04 09:02:27 -07:00
2019-09-15 02:59:53 +00:00
2021-08-08 10:42:24 -04:00
2020-10-28 13:46:11 +00:00
2020-12-07 09:21:06 +00:00
2021-08-30 12:50:53 +01:00
2021-05-29 22:04:09 +00:00
2018-12-17 17:11:00 +00:00
2021-04-12 11:42:21 -03:00
2020-07-14 18:57:31 +00:00
2021-10-27 18:58:36 -07:00
2021-03-31 19:17:37 +02:00
2021-11-05 15:45:51 -05:00
2018-12-19 23:19:05 +00:00
2021-06-23 23:46:15 +03:00
2020-09-01 22:12:58 +00:00
2021-05-25 16:59:18 -07:00
2019-01-16 05:15:57 +00:00
2021-07-16 18:06:44 +01:00
2021-10-18 09:56:58 -04:00
2021-06-25 14:12:21 -04:00
2019-02-26 22:07:59 +00:00
2021-09-23 14:31:38 -04:00
2020-03-07 00:55:46 +00:00
2020-03-07 00:55:46 +00:00
2021-04-21 16:19:15 +08:00
2021-09-17 14:19:06 -04:00
2021-07-28 09:35:09 -07:00
2021-11-09 10:50:12 -08:00
2020-10-14 09:22:54 +00:00
2020-09-01 22:12:58 +00:00
2021-03-13 16:37:28 +01:00
2020-12-27 12:57:26 +02:00
2021-04-18 11:14:17 -06:00
2019-03-18 19:23:19 +00:00
2020-09-01 22:12:58 +00:00
2020-09-01 22:12:58 +00:00
2021-06-14 16:30:16 +01:00
2021-10-27 18:58:36 -07:00
2021-12-09 02:49:10 +02:00
2021-12-09 02:49:10 +02:00
2021-11-25 22:50:42 +00:00
2021-10-15 10:21:55 +02:00
2021-12-06 20:46:49 +02:00
2019-12-16 23:55:30 +00:00
2021-12-09 02:49:10 +02:00
2021-11-03 16:03:51 -06:00
2021-05-24 20:37:55 -07:00
2021-08-08 10:42:24 -04:00
2020-09-01 22:12:58 +00:00
2020-09-01 22:12:58 +00:00
2021-07-30 17:20:22 -06:00
2020-09-01 22:12:58 +00:00
2021-08-08 10:42:24 -04:00
2021-04-09 23:42:51 +03:00
2021-04-18 11:19:15 -06:00
2021-10-16 11:47:34 -07:00
2020-04-17 18:34:49 +00:00
2020-12-25 20:43:09 +02:00
2020-04-17 18:34:49 +00:00
2020-04-17 18:34:49 +00:00
2020-04-17 18:34:49 +00:00
2019-07-24 23:04:59 +00:00
2021-12-17 12:38:34 +01:00
2021-11-22 22:36:54 +00:00
2020-11-19 04:28:39 +00:00
2020-05-20 20:58:17 +00:00
2021-07-29 12:41:29 +03:00
2021-07-29 12:48:34 +03:00
2020-11-03 01:17:45 +00:00
2021-12-09 02:48:46 +02:00
2020-11-03 01:17:45 +00:00
2021-08-08 10:16:06 +02:00
2021-11-24 11:26:45 -07:00
2020-10-10 21:52:00 +00:00
2019-05-13 16:38:48 +00:00
2021-12-10 19:53:57 +00:00
2019-05-20 00:38:23 +00:00