1761efaa7SDag-Erling Smørgrav /* 2761efaa7SDag-Erling Smørgrav * Copyright (c) 2006 Darren Tucker. All rights reserved. 3761efaa7SDag-Erling Smørgrav * 4761efaa7SDag-Erling Smørgrav * Permission to use, copy, modify, and distribute this software for any 5761efaa7SDag-Erling Smørgrav * purpose with or without fee is hereby granted, provided that the above 6761efaa7SDag-Erling Smørgrav * copyright notice and this permission notice appear in all copies. 7761efaa7SDag-Erling Smørgrav * 8761efaa7SDag-Erling Smørgrav * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 9761efaa7SDag-Erling Smørgrav * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 10761efaa7SDag-Erling Smørgrav * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 11761efaa7SDag-Erling Smørgrav * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 12761efaa7SDag-Erling Smørgrav * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 13761efaa7SDag-Erling Smørgrav * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 14761efaa7SDag-Erling Smørgrav * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 15761efaa7SDag-Erling Smørgrav */ 16761efaa7SDag-Erling Smørgrav 17761efaa7SDag-Erling Smørgrav #include <sys/types.h> 18761efaa7SDag-Erling Smørgrav 194a421b63SDag-Erling Smørgrav #include <pwd.h> 204a421b63SDag-Erling Smørgrav 21b15c8340SDag-Erling Smørgrav void platform_pre_listen(void); 22761efaa7SDag-Erling Smørgrav void platform_pre_fork(void); 23f7167e0eSDag-Erling Smørgrav void platform_pre_restart(void); 24761efaa7SDag-Erling Smørgrav void platform_post_fork_parent(pid_t child_pid); 25761efaa7SDag-Erling Smørgrav void platform_post_fork_child(void); 264a421b63SDag-Erling Smørgrav int platform_privileged_uidswap(void); 274a421b63SDag-Erling Smørgrav void platform_setusercontext(struct passwd *); 284a421b63SDag-Erling Smørgrav void platform_setusercontext_post_groups(struct passwd *); 29b15c8340SDag-Erling Smørgrav char *platform_get_krb5_client(const char *); 30b15c8340SDag-Erling Smørgrav char *platform_krb5_get_principal_name(const char *); 31*87c1498dSEd Maste int platform_locked_account(struct passwd *); 326888a9beSDag-Erling Smørgrav int platform_sys_dir_uid(uid_t); 33076ad2f8SDag-Erling Smørgrav void platform_disable_tracing(int); 34acc1a9efSDag-Erling Smørgrav 35acc1a9efSDag-Erling Smørgrav /* in platform-pledge.c */ 36acc1a9efSDag-Erling Smørgrav void platform_pledge_agent(void); 37acc1a9efSDag-Erling Smørgrav void platform_pledge_sftp_server(void); 38acc1a9efSDag-Erling Smørgrav void platform_pledge_mux(void); 39