2 * ----------------------------------------------------------------------------
3 * "THE BEER-WARE LICENSE" (Revision 42):
4 * <phk@FreeBSD.org> wrote this file. As long as you retain this notice you
5 * can do whatever you want with this stuff. If we meet some day, and you think
6 * this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
7 * ----------------------------------------------------------------------------
25 int jail __P((struct jail *));
30 MALLOC_DECLARE(M_PRISON);
34 * This structure describes a prison. It is pointed to by all struct
35 * ucreds's of the inmates. pr_ref keeps track of them and is used to
36 * delete the struture when the last inmate is dead.
38 * XXX: Note: this structure needs a mutex to protect the reference count
39 * and other mutable fields (pr_host, pr_linux).
44 char pr_host[MAXHOSTNAMELEN];
50 * Sysctl-set variables that determine global jail policy
52 extern int jail_set_hostname_allowed;
53 extern int jail_socket_unixiproute_only;
54 extern int jail_sysvipc_allowed;
57 * Kernel support functions for jail().
61 int jailed __P((struct ucred *cred));
62 int prison_check __P((struct ucred *cred1, struct ucred *cred2));
63 void prison_free __P((struct prison *pr));
64 void prison_hold __P((struct prison *pr));
65 int prison_if __P((struct ucred *cred, struct sockaddr *sa));
66 int prison_ip __P((struct ucred *cred, int flag, u_int32_t *ip));
67 void prison_remote_ip __P((struct ucred *cred, int flags, u_int32_t *ip));
70 #endif /* !_SYS_JAIL_H_ */