xref: /onnv-gate/usr/src/cmd/cmd-inet/sbin/dhcpagent/defaults.h (revision 9633:309290318ad0)
10Sstevel@tonic-gate /*
20Sstevel@tonic-gate  * CDDL HEADER START
30Sstevel@tonic-gate  *
40Sstevel@tonic-gate  * The contents of this file are subject to the terms of the
52546Scarlsonj  * Common Development and Distribution License (the "License").
62546Scarlsonj  * You may not use this file except in compliance with the License.
70Sstevel@tonic-gate  *
80Sstevel@tonic-gate  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
90Sstevel@tonic-gate  * or http://www.opensolaris.org/os/licensing.
100Sstevel@tonic-gate  * See the License for the specific language governing permissions
110Sstevel@tonic-gate  * and limitations under the License.
120Sstevel@tonic-gate  *
130Sstevel@tonic-gate  * When distributing Covered Code, include this CDDL HEADER in each
140Sstevel@tonic-gate  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
150Sstevel@tonic-gate  * If applicable, add the following below this CDDL HEADER, with the
160Sstevel@tonic-gate  * fields enclosed by brackets "[]" replaced with your own identifying
170Sstevel@tonic-gate  * information: Portions Copyright [yyyy] [name of copyright owner]
180Sstevel@tonic-gate  *
190Sstevel@tonic-gate  * CDDL HEADER END
200Sstevel@tonic-gate  */
210Sstevel@tonic-gate /*
22*9633Sjames.d.carlson@sun.com  * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
232546Scarlsonj  * Use is subject to license terms.
240Sstevel@tonic-gate  */
250Sstevel@tonic-gate 
260Sstevel@tonic-gate #ifndef	DEFAULTS_H
270Sstevel@tonic-gate #define	DEFAULTS_H
280Sstevel@tonic-gate 
290Sstevel@tonic-gate #include <sys/types.h>
300Sstevel@tonic-gate 
310Sstevel@tonic-gate /*
320Sstevel@tonic-gate  * defaults.[ch] encapsulate the agent's interface to the dhcpagent
330Sstevel@tonic-gate  * defaults file.  see defaults.c for documentation on how to use the
340Sstevel@tonic-gate  * exported functions.
350Sstevel@tonic-gate  */
360Sstevel@tonic-gate 
370Sstevel@tonic-gate #ifdef	__cplusplus
380Sstevel@tonic-gate extern "C" {
390Sstevel@tonic-gate #endif
400Sstevel@tonic-gate 
410Sstevel@tonic-gate /*
420Sstevel@tonic-gate  * tunable parameters -- keep in the same order as defaults[] in defaults.c
430Sstevel@tonic-gate  */
440Sstevel@tonic-gate 
450Sstevel@tonic-gate enum {
460Sstevel@tonic-gate 
470Sstevel@tonic-gate 	DF_RELEASE_ON_SIGTERM,	/* send RELEASE on each if upon SIGTERM */
482546Scarlsonj 	_UNUSED_DF_IGNORE_FAILED_ARP,
490Sstevel@tonic-gate 	DF_OFFER_WAIT,		/* how long to wait to collect offers */
502546Scarlsonj 	_UNUSED_DF_ARP_WAIT,
510Sstevel@tonic-gate 	DF_CLIENT_ID,		/* our client id */
520Sstevel@tonic-gate 	DF_PARAM_REQUEST_LIST,	/* our parameter request list */
533431Scarlsonj 	DF_REQUEST_HOSTNAME,	/* request hostname associated with interface */
543431Scarlsonj 	DF_DEBUG_LEVEL,		/* set debug level (undocumented) */
55*9633Sjames.d.carlson@sun.com 	DF_VERBOSE,		/* set verbose mode (undocumented) */
56*9633Sjames.d.carlson@sun.com 	DF_VERIFIED_LEASE_ONLY,	/* send RELEASE on SIGTERM and need verify */
57*9633Sjames.d.carlson@sun.com 	DF_PARAM_IGNORE_LIST	/* our parameter ignore list */
580Sstevel@tonic-gate };
590Sstevel@tonic-gate 
600Sstevel@tonic-gate #define	DHCP_AGENT_DEFAULTS	"/etc/default/dhcpagent"
610Sstevel@tonic-gate 
623431Scarlsonj boolean_t	df_get_bool(const char *, boolean_t, uint_t);
633431Scarlsonj int		df_get_int(const char *, boolean_t, uint_t);
643431Scarlsonj const char	*df_get_string(const char *, boolean_t, uint_t);
650Sstevel@tonic-gate 
660Sstevel@tonic-gate #ifdef	__cplusplus
670Sstevel@tonic-gate }
680Sstevel@tonic-gate #endif
690Sstevel@tonic-gate 
700Sstevel@tonic-gate #endif	/* DEFAULTS_H */
71