tzsetup: Fix VERBOSE reporting when removing _PATH_LOCALTIME for UTC.
[dragonfly.git] / include / rpcsvc / nislib.h
... / ...
CommitLineData
1/*
2 * Sun RPC is a product of Sun Microsystems, Inc. and is provided for
3 * unrestricted use provided that this legend is included on all tape
4 * media and as a part of the software program in whole or part. Users
5 * may copy or modify Sun RPC without charge, but are not authorized
6 * to license or distribute it to anyone else except as part of a product or
7 * program developed by the user.
8 *
9 * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
10 * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
11 * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
12 *
13 * Sun RPC is provided with no support and without any obligation on the
14 * part of Sun Microsystems, Inc. to assist in its use, correction,
15 * modification or enhancement.
16 *
17 * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
18 * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
19 * OR ANY PART THEREOF.
20 *
21 * In no event will Sun Microsystems, Inc. be liable for any lost revenue
22 * or profits or other special, indirect and consequential damages, even if
23 * Sun has been advised of the possibility of such damages.
24 *
25 * Sun Microsystems, Inc.
26 * 2550 Garcia Avenue
27 * Mountain View, California 94043
28 *
29 * $FreeBSD: src/include/rpcsvc/nislib.h,v 1.4 2002/03/23 17:24:55 imp Exp $
30 * $DragonFly: src/include/rpcsvc/nislib.h,v 1.2 2004/02/25 15:12:54 joerg Exp $
31 */
32
33/*
34 * Copyright (c) 1991, Sun Microsystems Inc.
35 */
36
37/*
38 * This file contains the interfaces that are visible in the SunOS 5.x
39 * implementation of NIS Plus.
40 */
41
42#ifndef _RPCSVC_NISLIB_H
43#define _RPCSVC_NISLIB_H
44
45/* From: #pragma ident "@(#)nislib.h 1.16 94/05/03 SMI" */
46
47#include <sys/cdefs.h>
48
49#define NUL '\0'
50
51struct signature {
52 int signature_len;
53 char *signature_val;
54};
55
56__BEGIN_DECLS
57
58void nis_freeresult(nis_result *);
59nis_result *nis_lookup(nis_name, u_long);
60nis_result *nis_list(nis_name, u_long,
61 int (*)(nis_name, nis_object *, void *), void *);
62nis_result *nis_add(nis_name, nis_object *);
63nis_result *nis_remove(nis_name, nis_object *);
64nis_result *nis_modify(nis_name, nis_object *);
65
66nis_result *nis_add_entry(nis_name, nis_object *, u_long);
67nis_result *nis_remove_entry(nis_name, nis_object *, u_long);
68nis_result *nis_modify_entry(nis_name, nis_object *, u_long);
69nis_result *nis_first_entry(nis_name);
70nis_result *nis_next_entry(nis_name, netobj *);
71
72nis_error nis_mkdir(nis_name, nis_server *);
73nis_error nis_rmdir(nis_name, nis_server *);
74name_pos nis_dir_cmp(nis_name, nis_name);
75
76nis_name *nis_getnames(nis_name);
77void nis_freenames(nis_name *);
78nis_name nis_domain_of(nis_name);
79nis_name nis_leaf_of(nis_name);
80nis_name nis_leaf_of_r(const nis_name, char *, size_t);
81nis_name nis_name_of(nis_name);
82nis_name nis_local_group(void);
83nis_name nis_local_directory(void);
84nis_name nis_local_principal(void);
85nis_name nis_local_host(void);
86
87void nis_destroy_object(nis_object *);
88nis_object *nis_clone_object(nis_object *, nis_object *);
89void nis_print_object(nis_object *);
90
91char *nis_sperrno(nis_error);
92void nis_perror(nis_error, char *);
93char *nis_sperror(nis_error, char *);
94void nis_lerror(nis_error, char *);
95
96void nis_print_group_entry(nis_name);
97bool_t nis_ismember(nis_name, nis_name);
98nis_error nis_creategroup(nis_name, u_long);
99nis_error nis_destroygroup(nis_name);
100nis_error nis_addmember(nis_name, nis_name);
101nis_error nis_removemember(nis_name, nis_name);
102nis_error nis_verifygroup(nis_name);
103
104void nis_freeservlist(nis_server **);
105nis_server * *nis_getservlist(nis_name);
106nis_error nis_stats(nis_server *, nis_tag *, int, nis_tag **);
107nis_error nis_servstate(nis_server *, nis_tag *, int, nis_tag **);
108void nis_freetags(nis_tag *, int);
109
110nis_result *nis_checkpoint(nis_name);
111void nis_ping(nis_name, u_long, nis_object *);
112
113/*
114 * XXX: PLEASE NOTE THAT THE FOLLOWING FUNCTIONS ARE INTERNAL
115 * TO NIS+ AND SHOULD NOT BE USED BY ANY APPLICATION PROGRAM.
116 * THEIR SEMANTICS AND/OR SIGNATURE CAN CHANGE WITHOUT NOTICE.
117 * SO, PLEASE DO NOT USE THEM. YOU ARE WARNED!!!!
118 */
119
120char **__break_name(nis_name, int *);
121int __name_distance(char **, char **);
122nis_result *nis_make_error(nis_error, u_long, u_long, u_long, u_long);
123nis_attr *__cvt2attr(int *, char **);
124void nis_free_request(ib_request *);
125nis_error nis_get_request(nis_name, nis_object *, netobj*, ib_request*);
126nis_object *nis_read_obj(char *);
127int nis_write_obj(char *, nis_object *);
128int nis_in_table(nis_name, NIS_HASH_TABLE *, int *);
129int nis_insert_item(NIS_HASH_ITEM *, NIS_HASH_TABLE *);
130NIS_HASH_ITEM *nis_find_item(nis_name, NIS_HASH_TABLE *);
131NIS_HASH_ITEM *nis_remove_item(nis_name, NIS_HASH_TABLE *);
132void nis_insert_name(nis_name, NIS_HASH_TABLE *);
133void nis_remove_name(nis_name, NIS_HASH_TABLE *);
134CLIENT *nis_make_rpchandle(nis_server *, int, u_long, u_long, u_long,
135 int, int);
136void *nis_get_static_storage(struct nis_sdata *, u_long, u_long);
137char *nis_data(char *);
138void nis_print_rights(u_long);
139void nis_print_directory(directory_obj *);
140void nis_print_group(group_obj *);
141void nis_print_table(table_obj *);
142void nis_print_link(link_obj *);
143void nis_print_entry(entry_obj *);
144nis_object *nis_get_object(char *, char *, char *, u_long, u_long,
145 zotypes);
146nis_server *__nis_init_callback(CLIENT *,
147 int (*)(nis_name, nis_object *, void *), void *);
148int nis_getdtblsize(void);
149int __nis_run_callback(netobj *, u_long, struct timeval *, CLIENT *);
150
151log_result *nis_dumplog(nis_server *, nis_name, u_long);
152log_result *nis_dump(nis_server *, nis_name,
153 int (*)(nis_name, nis_object *, void *));
154
155bool_t __do_ismember(nis_name, nis_name,
156 nis_result *(*)(nis_name, u_long));
157nis_name __nis_map_group(nis_name);
158nis_name __nis_map_group_r(nis_name, char*, size_t);
159
160nis_error __nis_CacheBind(char *, directory_obj *);
161nis_error __nis_CacheSearch(char *, directory_obj *);
162bool_t __nis_CacheRemoveEntry(directory_obj *);
163void __nis_CacheRestart(void);
164void __nis_CachePrint(void);
165void __nis_CacheDumpStatistics(void);
166bool_t writeColdStartFile(directory_obj *);
167
168CLIENT *__get_ti_clnt(char *, CLIENT *, char **, pid_t *);
169int __strcmp_case_insens(char *, char *);
170int __strncmp_case_insens(char *, char *);
171
172fd_result *nis_finddirectory(directory_obj *, nis_name);
173int __start_clock(int);
174u_long __stop_clock(int);
175
176/*
177 * This particular function is part of the FreeBSD NIS+ implementation
178 * only. Ideally it should be somewhere else, but it is used by both
179 * rpc.nisd and nis_cachemgr, and there aren't that many headers common
180 * to both programs.
181 */
182
183struct signature *__nis_calculate_encrypted_cksum(unsigned char *,
184 unsigned int, char *, int);
185
186__END_DECLS
187
188#endif /* _RPCSVC_NISLIB_H */