udhcp: add support for 0x21 ROUTES and 0xf9 MS_STATIC_ROUTES options
Signed-off-by: Vladislav Grishenko <themiron@mail.ru> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
parent
04bcd998ca
commit
7d3a48a003
@ -37,6 +37,7 @@ const struct dhcp_optflag dhcp_optflags[] = {
|
|||||||
{ OPTION_U8 , 0x17 }, /* DHCP_IP_TTL */
|
{ OPTION_U8 , 0x17 }, /* DHCP_IP_TTL */
|
||||||
{ OPTION_U16 , 0x1a }, /* DHCP_MTU */
|
{ OPTION_U16 , 0x1a }, /* DHCP_MTU */
|
||||||
{ OPTION_IP | OPTION_REQ, 0x1c }, /* DHCP_BROADCAST */
|
{ OPTION_IP | OPTION_REQ, 0x1c }, /* DHCP_BROADCAST */
|
||||||
|
{ OPTION_IP_PAIR | OPTION_LIST , 0x21 }, /* DHCP_ROUTES */
|
||||||
{ OPTION_STRING , 0x28 }, /* DHCP_NIS_DOMAIN */
|
{ OPTION_STRING , 0x28 }, /* DHCP_NIS_DOMAIN */
|
||||||
{ OPTION_IP | OPTION_LIST , 0x29 }, /* DHCP_NIS_SERVER */
|
{ OPTION_IP | OPTION_LIST , 0x29 }, /* DHCP_NIS_SERVER */
|
||||||
{ OPTION_IP | OPTION_LIST | OPTION_REQ, 0x2a }, /* DHCP_NTP_SERVER */
|
{ OPTION_IP | OPTION_LIST | OPTION_REQ, 0x2a }, /* DHCP_NTP_SERVER */
|
||||||
@ -54,6 +55,7 @@ const struct dhcp_optflag dhcp_optflags[] = {
|
|||||||
{ OPTION_SIP_SERVERS , 0x78 }, /* DHCP_SIP_SERVERS */
|
{ OPTION_SIP_SERVERS , 0x78 }, /* DHCP_SIP_SERVERS */
|
||||||
#endif
|
#endif
|
||||||
{ OPTION_STATIC_ROUTES , 0x79 }, /* DHCP_STATIC_ROUTES */
|
{ OPTION_STATIC_ROUTES , 0x79 }, /* DHCP_STATIC_ROUTES */
|
||||||
|
{ OPTION_STATIC_ROUTES , 0xf9 }, /* DHCP_MS_STATIC_ROUTES */
|
||||||
{ OPTION_STRING , 0xfc }, /* DHCP_WPAD */
|
{ OPTION_STRING , 0xfc }, /* DHCP_WPAD */
|
||||||
|
|
||||||
/* Options below have no match in dhcp_option_strings[],
|
/* Options below have no match in dhcp_option_strings[],
|
||||||
@ -95,6 +97,7 @@ const char dhcp_option_strings[] ALIGN1 =
|
|||||||
"ipttl" "\0" /* DHCP_IP_TTL */
|
"ipttl" "\0" /* DHCP_IP_TTL */
|
||||||
"mtu" "\0" /* DHCP_MTU */
|
"mtu" "\0" /* DHCP_MTU */
|
||||||
"broadcast" "\0" /* DHCP_BROADCAST */
|
"broadcast" "\0" /* DHCP_BROADCAST */
|
||||||
|
"routes" "\0" /* DHCP_ROUTES */
|
||||||
"nisdomain" "\0" /* DHCP_NIS_DOMAIN */
|
"nisdomain" "\0" /* DHCP_NIS_DOMAIN */
|
||||||
"nissrv" "\0" /* DHCP_NIS_SERVER */
|
"nissrv" "\0" /* DHCP_NIS_SERVER */
|
||||||
"ntpsrv" "\0" /* DHCP_NTP_SERVER */
|
"ntpsrv" "\0" /* DHCP_NTP_SERVER */
|
||||||
@ -114,6 +117,7 @@ const char dhcp_option_strings[] ALIGN1 =
|
|||||||
// doesn't work in udhcpd.conf since OPTION_STATIC_ROUTES
|
// doesn't work in udhcpd.conf since OPTION_STATIC_ROUTES
|
||||||
// is not handled yet by "string->option" conversion code:
|
// is not handled yet by "string->option" conversion code:
|
||||||
"staticroutes" "\0"/* DHCP_STATIC_ROUTES */
|
"staticroutes" "\0"/* DHCP_STATIC_ROUTES */
|
||||||
|
"msstaticroutes""\0"/* DHCP_MS_STATIC_ROUTES */
|
||||||
"wpad" "\0" /* DHCP_WPAD */
|
"wpad" "\0" /* DHCP_WPAD */
|
||||||
;
|
;
|
||||||
|
|
||||||
|
@ -123,6 +123,7 @@ enum {
|
|||||||
//#define DHCP_IP_TTL 0x17
|
//#define DHCP_IP_TTL 0x17
|
||||||
//#define DHCP_MTU 0x1a
|
//#define DHCP_MTU 0x1a
|
||||||
//#define DHCP_BROADCAST 0x1c
|
//#define DHCP_BROADCAST 0x1c
|
||||||
|
//#define DHCP_ROUTES 0x21
|
||||||
//#define DHCP_NIS_DOMAIN 0x28
|
//#define DHCP_NIS_DOMAIN 0x28
|
||||||
//#define DHCP_NIS_SERVER 0x29
|
//#define DHCP_NIS_SERVER 0x29
|
||||||
//#define DHCP_NTP_SERVER 0x2a
|
//#define DHCP_NTP_SERVER 0x2a
|
||||||
@ -144,6 +145,7 @@ enum {
|
|||||||
//#define DHCP_DOMAIN_SEARCH 0x77 /* RFC 3397. set of ASCIZ string, DNS-style compressed */
|
//#define DHCP_DOMAIN_SEARCH 0x77 /* RFC 3397. set of ASCIZ string, DNS-style compressed */
|
||||||
//#define DHCP_SIP_SERVERS 0x78 /* RFC 3361. flag byte, then: 0: domain names, 1: IP addrs */
|
//#define DHCP_SIP_SERVERS 0x78 /* RFC 3361. flag byte, then: 0: domain names, 1: IP addrs */
|
||||||
//#define DHCP_STATIC_ROUTES 0x79 /* RFC 3442. (mask,ip,router) tuples */
|
//#define DHCP_STATIC_ROUTES 0x79 /* RFC 3442. (mask,ip,router) tuples */
|
||||||
|
//#define DHCP_MS_STATIC_ROUTES 0xf9 /* Microsoft's pre-RFC 3442 code for 0x79? */
|
||||||
//#define DHCP_WPAD 0xfc /* MSIE's Web Proxy Autodiscovery Protocol */
|
//#define DHCP_WPAD 0xfc /* MSIE's Web Proxy Autodiscovery Protocol */
|
||||||
#define DHCP_END 0xff
|
#define DHCP_END 0xff
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user