1 /* $OpenBSD: funcs.h,v 1.11 2003/06/26 00:13:38 deraadt Exp $ */ 2 3 /* 4 * Copyright (c) 1997,2000 by Internet Software Consortium, Inc. 5 * 6 * Permission to use, copy, modify, and distribute this software for any 7 * purpose with or without fee is hereby granted, provided that the above 8 * copyright notice and this permission notice appear in all copies. 9 * 10 * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM DISCLAIMS 11 * ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES 12 * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL INTERNET SOFTWARE 13 * CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL 14 * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR 15 * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS 16 * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS 17 * SOFTWARE. 18 */ 19 20 /* Notes: 21 * This file has to be included by cron.h after data structure defs. 22 * We should reorg this into sections by module. 23 */ 24 25 void set_cron_uid(void), 26 set_cron_cwd(void), 27 load_database(cron_db *), 28 open_logfile(void), 29 sigpipe_func(void), 30 job_add(entry *, user *), 31 do_command(entry *, user *), 32 link_user(cron_db *, user *), 33 unlink_user(cron_db *, user *), 34 free_user(user *), 35 env_free(char **), 36 unget_char(int, FILE *), 37 free_entry(entry *), 38 acquire_daemonlock(int), 39 skip_comments(FILE *), 40 log_it(const char *, int, const char *, const char *), 41 log_close(void), 42 poke_daemon(const char *, unsigned char), 43 atrun(at_db *, double, time_t); 44 45 int job_runqueue(void), 46 set_debug_flags(const char *), 47 get_char(FILE *), 48 get_string(char *, int, FILE *, char *), 49 swap_gids(void), 50 swap_gids_back(void), 51 load_env(char *, FILE *), 52 cron_pclose(FILE *), 53 glue_strings(char *, size_t, const char *, const char *, char), 54 strcmp_until(const char *, const char *, char), 55 allowed(const char *, const char *, const char *), 56 strdtb(char *), 57 open_socket(void), 58 safe_p(const char *, const char *), 59 scan_atjobs(at_db *, struct timeval *); 60 61 char *env_get(char *, char **), 62 *arpadate(time_t *), 63 *mkprints(unsigned char *, unsigned int), 64 *first_word(char *, char *), 65 **env_init(void), 66 **env_copy(char **), 67 **env_set(char **, char *); 68 69 void mkprint(char *, unsigned char *, int); 70 71 user *load_user(int, struct passwd *, const char *), 72 *find_user(cron_db *, const char *); 73 74 entry *load_entry(FILE *, void (*)(const char *), struct passwd *, char **); 75 76 FILE *cron_popen(char *, char *, struct passwd *); 77 78 #ifndef HAVE_TM_GMTOFF 79 long get_gmtoff(time_t *, struct tm *); 80 #endif 81