Commit | Line | Data |
---|---|---|
5ff67f98 DF |
1 | /* |
2 | * Copyright (c) 1983 Regents of the University of California. | |
0eb85d71 | 3 | * All rights reserved. |
5ff67f98 | 4 | * |
d60d530a | 5 | * %sccs.include.redist.c% |
0eb85d71 | 6 | * |
d60d530a | 7 | * @(#)af.h 5.7 (Berkeley) %G% |
5ff67f98 | 8 | */ |
8c55761d SL |
9 | |
10 | /* | |
11 | * Routing table management daemon. | |
12 | */ | |
13 | ||
14 | /* | |
15 | * Per address family routines. | |
16 | */ | |
17 | struct afswitch { | |
18 | int (*af_hash)(); /* returns keys based on address */ | |
19 | int (*af_netmatch)(); /* verifies net # matching */ | |
20 | int (*af_output)(); /* interprets address for sending */ | |
21 | int (*af_portmatch)(); /* packet from some other router? */ | |
d5568f13 | 22 | int (*af_portcheck)(); /* packet from privileged peer? */ |
4fad5a6e MK |
23 | int (*af_checkhost)(); /* tells if address is valid */ |
24 | int (*af_rtflags)(); /* get flags for route (host or net) */ | |
7892134c | 25 | int (*af_sendroute)(); /* check bounds of subnet broadcast */ |
8c55761d | 26 | int (*af_canon)(); /* canonicalize address for compares */ |
17fe297f | 27 | char *(*af_format)(); /* convert address to string */ |
8c55761d SL |
28 | }; |
29 | ||
30 | /* | |
31 | * Structure returned by af_hash routines. | |
32 | */ | |
33 | struct afhash { | |
34 | u_int afh_hosthash; /* host based hash */ | |
35 | u_int afh_nethash; /* network based hash */ | |
36 | }; | |
37 | ||
17fe297f MK |
38 | struct afswitch afswitch[]; /* table proper */ |
39 | int af_max; /* number of entries in table */ |