1/*
2 * CDDL HEADER START
3 *
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
7 *
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
12 *
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 *
19 * CDDL HEADER END
20 */
21
22/*
23 * Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
24 * Use is subject to license terms.
25 */
26
27#ifndef	_MOUNTD_H
28#define	_MOUNTD_H
29
30#pragma ident	"%Z%%M%	%I%	%E% SMI"
31
32#include <door.h>
33#include <nfs/nfs.h>
34
35#ifdef	__cplusplus
36extern "C" {
37#endif
38
39#define	MAXIPADDRLEN	512
40
41struct nd_hostservlist;
42extern void rmtab_load(void);
43extern void mntlist_send(SVCXPRT *transp);
44extern void mntlist_new(char *host, char *path);
45extern void mntlist_delete(char *host, char *path);
46extern void mntlist_delete_all(char *host);
47extern void netgroup_init(void);
48extern int  netgroup_check(struct nd_hostservlist *, char *, int);
49extern void export(struct svc_req *);
50extern void nfsauth_func(void *, char *, size_t, door_desc_t *, uint_t);
51extern char *inet_ntoa_r(struct in_addr, char *);
52extern int nfs_getfh(char *, int, int *, char *);
53
54extern void nfsauth_prog(struct svc_req *, SVCXPRT *);
55
56extern struct sh_list *share_list;
57extern rwlock_t sharetab_lock;
58extern void check_sharetab(void);
59
60extern void log_cant_reply(SVCXPRT *);
61
62extern void *exmalloc(size_t);
63
64extern struct share *findentry(char *);
65extern int check_client(struct share *, struct netbuf *,
66				struct nd_hostservlist *, int);
67extern struct nd_hostservlist *anon_client(char *host);
68
69/*
70 * These functions are defined here due to the fact
71 * that we can not find the proper header file to
72 * include. These functions are, at present, not
73 * listed in any other header files.
74 */
75/*
76 * These three functions are hidden functions in the
77 * bsm libraries (libbsm).
78 */
79extern void audit_mountd_setup(void);
80extern void audit_mountd_mount(char *, char *, int);
81extern void audit_mountd_umount(char *, char *);
82
83/*
84 * This is a hidden function in the rpc libraries (libnsl).
85 */
86extern int __rpc_negotiate_uid(int);
87
88/*
89 * This appears to be a hidden function in libc.
90 * Private interface to nss_search().
91 * Accepts N strings rather than 1.
92 */
93extern  int __multi_innetgr();
94
95#ifdef	__cplusplus
96}
97#endif
98
99#endif	/* _MOUNTD_H */
100