]> git.baikalelectronics.ru Git - kernel.git/commit
ipv4: enable IFA_TARGET_NETNSID for RTM_GETADDR
authorChristian Brauner <christian@brauner.io>
Tue, 4 Sep 2018 19:53:49 +0000 (21:53 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 6 Sep 2018 05:27:11 +0000 (22:27 -0700)
commit69bc639a806171e37246bf607f39baa0d932623c
tree5d24b0f6b7f9393e54843836e33a7b047d88d1bd
parentb3e8c0cde825cbf34ce63f569b9184cca8e919f0
ipv4: enable IFA_TARGET_NETNSID for RTM_GETADDR

- Backwards Compatibility:
  If userspace wants to determine whether ipv4 RTM_GETADDR requests
  support the new IFA_TARGET_NETNSID property it should verify that the
  reply includes the IFA_TARGET_NETNSID property. If it does not
  userspace should assume that IFA_TARGET_NETNSID is not supported for
  ipv4 RTM_GETADDR requests on this kernel.
- From what I gather from current userspace tools that make use of
  RTM_GETADDR requests some of them pass down struct ifinfomsg when they
  should actually pass down struct ifaddrmsg. To not break existing
  tools that pass down the wrong struct we will do the same as for
  RTM_GETLINK | NLM_F_DUMP requests and not error out when the
  nlmsg_parse() fails.

- Security:
  Callers must have CAP_NET_ADMIN in the owning user namespace of the
  target network namespace.

Signed-off-by: Christian Brauner <christian@brauner.io>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/devinet.c