31
|
1 |
/*
|
|
2 |
* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
|
|
3 |
* All rights reserved.
|
|
4 |
* This component and the accompanying materials are made available
|
|
5 |
* under the terms of "Eclipse Public License v1.0"
|
|
6 |
* which accompanies this distribution, and is available
|
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
8 |
*
|
|
9 |
* Initial Contributors:
|
|
10 |
* Nokia Corporation - initial contribution.
|
|
11 |
*
|
|
12 |
* Contributors:
|
|
13 |
*
|
|
14 |
* Description:
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
/* $NetBSD: netconfig.h,v 1.1 2000/06/02 22:57:54 fvdl Exp $ */
|
|
18 |
/* $FreeBSD: src/include/netconfig.h,v 1.3 2002/03/23 17:24:53 imp Exp $ */
|
|
19 |
|
|
20 |
|
|
21 |
#ifndef _NETCONFIG_H_
|
|
22 |
#define _NETCONFIG_H_
|
|
23 |
|
|
24 |
#include <sys/cdefs.h>
|
|
25 |
|
|
26 |
#define NETCONFIG "/etc/netconfig"
|
|
27 |
#define NETPATH "NETPATH"
|
|
28 |
|
|
29 |
struct netconfig {
|
|
30 |
char *nc_netid; /* Network ID */
|
|
31 |
unsigned long nc_semantics; /* Semantics (see below) */
|
|
32 |
unsigned long nc_flag; /* Flags (see below) */
|
|
33 |
char *nc_protofmly; /* Protocol family */
|
|
34 |
char *nc_proto; /* Protocol name */
|
|
35 |
char *nc_device; /* Network device pathname */
|
|
36 |
unsigned long nc_nlookups; /* Number of directory lookup libs */
|
|
37 |
char **nc_lookups; /* Names of the libraries */
|
|
38 |
unsigned long nc_unused[9]; /* reserved */
|
|
39 |
};
|
|
40 |
|
|
41 |
typedef struct {
|
|
42 |
struct netconfig **nc_head;
|
|
43 |
struct netconfig **nc_curr;
|
|
44 |
} NCONF_HANDLE;
|
|
45 |
|
|
46 |
/*
|
|
47 |
* nc_semantics values
|
|
48 |
*/
|
|
49 |
#define NC_TPI_CLTS 1
|
|
50 |
#define NC_TPI_COTS 2
|
|
51 |
#define NC_TPI_COTS_ORD 3
|
|
52 |
#define NC_TPI_RAW 4
|
|
53 |
|
|
54 |
/*
|
|
55 |
* nc_flag values
|
|
56 |
*/
|
|
57 |
#define NC_NOFLAG 0x00
|
|
58 |
#define NC_VISIBLE 0x01
|
|
59 |
#define NC_BROADCAST 0x02
|
|
60 |
|
|
61 |
/*
|
|
62 |
* nc_protofmly values
|
|
63 |
*/
|
|
64 |
#define NC_NOPROTOFMLY "-"
|
|
65 |
#define NC_LOOPBACK "loopback"
|
|
66 |
#define NC_INET "inet"
|
|
67 |
#define NC_INET6 "inet6"
|
|
68 |
#define NC_IMPLINK "implink"
|
|
69 |
#define NC_PUP "pup"
|
|
70 |
#define NC_CHAOS "chaos"
|
|
71 |
#define NC_NS "ns"
|
|
72 |
#define NC_NBS "nbs"
|
|
73 |
#define NC_ECMA "ecma"
|
|
74 |
#define NC_DATAKIT "datakit"
|
|
75 |
#define NC_CCITT "ccitt"
|
|
76 |
#define NC_SNA "sna"
|
|
77 |
#define NC_DECNET "decnet"
|
|
78 |
#define NC_DLI "dli"
|
|
79 |
#define NC_LAT "lat"
|
|
80 |
#define NC_HYLINK "hylink"
|
|
81 |
#define NC_APPLETALK "appletalk"
|
|
82 |
#define NC_NIT "nit"
|
|
83 |
#define NC_IEEE802 "ieee802"
|
|
84 |
#define NC_OSI "osi"
|
|
85 |
#define NC_X25 "x25"
|
|
86 |
#define NC_OSINET "osinet"
|
|
87 |
#define NC_GOSIP "gosip"
|
|
88 |
|
|
89 |
/*
|
|
90 |
* nc_proto values
|
|
91 |
*/
|
|
92 |
#define NC_NOPROTO "-"
|
|
93 |
#define NC_TCP "tcp"
|
|
94 |
#define NC_UDP "udp"
|
|
95 |
#define NC_ICMP "icmp"
|
|
96 |
|
|
97 |
|
|
98 |
#endif /* _NETCONFIG_H_ */
|