diff options
author | brian <brian@FreeBSD.org> | 2000-03-14 01:47:27 +0000 |
---|---|---|
committer | brian <brian@FreeBSD.org> | 2000-03-14 01:47:27 +0000 |
commit | 1bc8ab9f4fde76438c6683101c2d510c86e8d978 (patch) | |
tree | 04d2970ad1d86e4a24bfa1b4c7a2b7e16e96b535 /usr.sbin/ppp/ipcp.h | |
parent | 041ec329dc4111a616c48d22712dfcaf9cbfe9bb (diff) | |
download | FreeBSD-src-1bc8ab9f4fde76438c6683101c2d510c86e8d978.zip FreeBSD-src-1bc8ab9f4fde76438c6683101c2d510c86e8d978.tar.gz |
Add the ``resolv'' command for telling ppp how to deal with resolv.conf.
You can now ``resolv restore'' in ppp.linkdown !
Add DNS0 and DNS1 macros.
Diffstat (limited to 'usr.sbin/ppp/ipcp.h')
-rw-r--r-- | usr.sbin/ppp/ipcp.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/usr.sbin/ppp/ipcp.h b/usr.sbin/ppp/ipcp.h index 6f87eb7..38583d8 100644 --- a/usr.sbin/ppp/ipcp.h +++ b/usr.sbin/ppp/ipcp.h @@ -87,6 +87,14 @@ struct ipcp { struct slstat slstat; /* VJ statistics */ } vj; + struct { + unsigned resolver : 1; /* Found resolv.conf ? */ + unsigned writable : 1; /* Can write resolv.conf ? */ + struct in_addr dns[2]; /* Current DNS addresses */ + char *resolv; /* Contents of resolv.conf */ + char *resolv_nons; /* Contents of resolv.conf without ns */ + } ns; + struct sticky_route *route; /* List of dynamic routes */ unsigned heis1172 : 1; /* True if he is speaking rfc1172 */ @@ -99,6 +107,8 @@ struct ipcp { struct in_addr my_ip; /* IP address I'm willing to use */ u_int32_t my_compproto; /* VJ params I'm willing to use */ + struct in_addr dns[2]; /* DNSs to REQ/ACK */ + u_int32_t peer_reject; /* Request codes rejected by peer */ u_int32_t my_reject; /* Request codes I have rejected */ @@ -133,6 +143,9 @@ extern void ipcp_AddUrgentPort(struct port_range *, u_short); extern void ipcp_RemoveUrgentPort(struct port_range *, u_short); extern void ipcp_ClearUrgentPorts(struct port_range *); extern struct in_addr addr2mask(struct in_addr); +extern int ipcp_WriteDNS(struct ipcp *); +extern void ipcp_RestoreDNS(struct ipcp *); +extern void ipcp_LoadDNS(struct ipcp *); #define ipcp_IsUrgentTcpPort(ipcp, p1, p2) \ ipcp_IsUrgentPort(&(ipcp)->cfg.urgent.tcp, p1, p2) |