summaryrefslogtreecommitdiffstats
path: root/include/sysutils/NetlinkEvent.h
diff options
context:
space:
mode:
authorLorenzo Colitti <lorenzo@google.com>2013-08-12 17:03:32 +0900
committerLorenzo Colitti <lorenzo@google.com>2013-11-01 14:05:02 +0900
commitb185e90dcc6ac111bff908edcc6d89fd6b37dc11 (patch)
tree6a9932232f45cd39a78940e2b6e60f6b319c5d80 /include/sysutils/NetlinkEvent.h
parentf1e072780eee546a18c5dda9f328c5f1dfcc0127 (diff)
downloadsystem_core-b185e90dcc6ac111bff908edcc6d89fd6b37dc11.zip
system_core-b185e90dcc6ac111bff908edcc6d89fd6b37dc11.tar.gz
system_core-b185e90dcc6ac111bff908edcc6d89fd6b37dc11.tar.bz2
Support parsing RDNSS ND options from netlink.
The RDNSS options (RFC 6106) used to configure DNS servers via router advertisements are passed from the kernel to userspace via RTM_NEWNDUSEROPT netlink messages. Add code to NetlinkEvent to parse them. Also fix a compiler warning and a couple of style issues. Bug: 9180552 Change-Id: I6c532c8f0ceef3afdc977a431a036df398013e1a
Diffstat (limited to 'include/sysutils/NetlinkEvent.h')
-rw-r--r--include/sysutils/NetlinkEvent.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/sysutils/NetlinkEvent.h b/include/sysutils/NetlinkEvent.h
index f3501cf..c0a9418 100644
--- a/include/sysutils/NetlinkEvent.h
+++ b/include/sysutils/NetlinkEvent.h
@@ -36,6 +36,7 @@ public:
const static int NlActionLinkUp;
const static int NlActionAddressUpdated;
const static int NlActionAddressRemoved;
+ const static int NlActionRdnss;
NetlinkEvent();
virtual ~NetlinkEvent();
@@ -49,9 +50,10 @@ public:
void dump();
protected:
- bool parseIfAddrMessage(int type, struct ifaddrmsg *ifaddr, int rtasize);
bool parseBinaryNetlinkMessage(char *buffer, int size);
bool parseAsciiNetlinkMessage(char *buffer, int size);
+ bool parseIfAddrMessage(int type, struct ifaddrmsg *ifaddr, int rtasize);
+ bool parseNdUserOptMessage(struct nduseroptmsg *msg, int optsize);
};
#endif