1 /* Dynamic Host Configuration Protocol / BOOTP */
4 OfferTimeout= 60, /* when an offer times out */
5 MaxLease= 60*60, /* longest lease for dynamic binding */
6 MinLease= 15*60, /* shortest lease for dynamic binding */
7 StaticLease= 30*60, /* lease for static binding */
9 IPUDPHDRSIZE= 28, /* size of an IP plus UDP header */
10 MINSUPPORTED= 576, /* biggest IP message the client must support */
12 /* lengths of some bootp fields */
34 /* bootp option types */
48 OBhostname= 12, /* 0x0c */
52 OBrootserver= 16, /* 0x10 */
68 OBrsserver= 32, /* 0x20 */
79 OBvendorinfo= 43, /* 0x2b */
84 OBxfontserver= 48, /* 0x30 */
86 OBnisplusdomain= 64, /* 0x40 */
99 ODipaddr= 50, /* 0x32 */
102 ODtype= 53, /* 0x35 */
103 ODserverid= 54, /* 0x36 */
104 ODparams= 55, /* 0x37 */
110 ODclientid= 61, /* 0x3d */
115 ODclasslessroutes= 121,
117 /* plan9 vendor info options, v4 addresses only (deprecated) */
118 OP9fsv4= 128, /* plan9 file servers */
119 OP9authv4= 129, /* plan9 auth servers */
121 /* plan9 vendor info options, textual addresses, thus v4 or v6 */
122 OP9fs= 130, /* plan9 file servers */
123 OP9auth= 131, /* plan9 auth servers */
124 OP9ipaddr= 132, /* client's address */
125 OP9ipmask= 133, /* client's subnet mask */
126 OP9ipgw= 134, /* client's gateway */
127 /* OP9dns= 135, /* dns servers */
130 /* a lease that never expires */
131 #define Lforever ~0UL
143 typedef struct Bootp Bootp;
146 /* Udphdr (included because of structure alignment on the alpha) */
147 uchar udphdr[Udphdrsize];
149 uchar op; /* opcode */
150 uchar htype; /* hardware type */
151 uchar hlen; /* hardware address len */
152 uchar hops; /* hops */
153 uchar xid[4]; /* a random number */
154 uchar secs[2]; /* elapsed since client started booting */
156 uchar ciaddr[IPv4addrlen]; /* client IP address (client tells server) */
157 uchar yiaddr[IPv4addrlen]; /* client IP address (server tells client) */
158 uchar siaddr[IPv4addrlen]; /* server IP address */
159 uchar giaddr[IPv4addrlen]; /* gateway IP address */
160 uchar chaddr[Maxhwlen]; /* client hardware address */
161 char sname[64]; /* server host name (optional) */
162 char file[Maxfilelen]; /* boot file name */
164 uchar optdata[Maxoptlen];