{"action":"created","issue":{"url":"https://api.github.com/repos/puppetlabs/facter/issues/1081","labels_url":"https://api.github.com/repos/puppetlabs/facter/issues/1081/labels{/name}","comments_url":"https://api.github.com/repos/puppetlabs/facter/issues/1081/comments","events_url":"https://api.github.com/repos/puppetlabs/facter/issues/1081/events","html_url":"https://github.com/puppetlabs/facter/pull/1081","id":97565980,"number":1081,"title":"(FACT-1147, FACT-1150) Fix network interfaces with multiple addresses.","user":{"login":"peterhuene","id":509666,"avatar_url":"https://avatars.githubusercontent.com/u/509666?v=3","gravatar_id":"","url":"https://api.github.com/users/peterhuene","html_url":"https://github.com/peterhuene","followers_url":"https://api.github.com/users/peterhuene/followers","following_url":"https://api.github.com/users/peterhuene/following{/other_user}","gists_url":"https://api.github.com/users/peterhuene/gists{/gist_id}","starred_url":"https://api.github.com/users/peterhuene/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/peterhuene/subscriptions","organizations_url":"https://api.github.com/users/peterhuene/orgs","repos_url":"https://api.github.com/users/peterhuene/repos","events_url":"https://api.github.com/users/peterhuene/events{/privacy}","received_events_url":"https://api.github.com/users/peterhuene/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":16,"created_at":"2015-07-27T22:06:57Z","updated_at":"2015-08-03T22:17:36Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/puppetlabs/facter/pulls/1081","html_url":"https://github.com/puppetlabs/facter/pull/1081","diff_url":"https://github.com/puppetlabs/facter/pull/1081.diff","patch_url":"https://github.com/puppetlabs/facter/pull/1081.patch"},"body":"Network interfaces with multiple assigned addresses were not being\r\nhandled properly.  Facter was considering the last address enumerated to\r\nbe the address of the interface.  This may not be correct as the order\r\nmay have a non-link-local address first and a link-local address later.\r\nThis would result in facter favoring the link-local address which is not\r\ndesired (FACT-1150).\r\n\r\nAdditionally, if the interface had only link-local addresses, the last\r\naddress was being selected rather than the first (FACT-1147).\r\n\r\nThe fix is for the resolvers to return an array of bound addresses for\r\neach network interface. The base resolver now selects what it considers\r\nto be the address of the interface by finding the first address that is\r\nnot link-local. If all addresses are link-local, then the first bound\r\naddress is used.\r\n\r\nAdditionally, if network interfaces have more than one bound address,\r\na new `bindings` (or `bindings6` for IPv6) element will appear on the\r\ninterface containing an array of structures containing the address,\r\nnetwork, and netmask for each binding.  This will allow users to see all\r\naddresses on the interface.\r\n\r\nThis fix also includes returning a \"primary\" element in the \"networking\"\r\nfact which is set to the name of the primary interface.  Users can use\r\nthis to quickly determine the interface that facter considers to be the\r\ninterface used for the top-level networking facts."},"comment":{"url":"https://api.github.com/repos/puppetlabs/facter/issues/comments/127420190","html_url":"https://github.com/puppetlabs/facter/pull/1081#issuecomment-127420190","issue_url":"https://api.github.com/repos/puppetlabs/facter/issues/1081","id":127420190,"user":{"login":"MikaelSmith","id":8162496,"avatar_url":"https://avatars.githubusercontent.com/u/8162496?v=3","gravatar_id":"","url":"https://api.github.com/users/MikaelSmith","html_url":"https://github.com/MikaelSmith","followers_url":"https://api.github.com/users/MikaelSmith/followers","following_url":"https://api.github.com/users/MikaelSmith/following{/other_user}","gists_url":"https://api.github.com/users/MikaelSmith/gists{/gist_id}","starred_url":"https://api.github.com/users/MikaelSmith/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MikaelSmith/subscriptions","organizations_url":"https://api.github.com/users/MikaelSmith/orgs","repos_url":"https://api.github.com/users/MikaelSmith/repos","events_url":"https://api.github.com/users/MikaelSmith/events{/privacy}","received_events_url":"https://api.github.com/users/MikaelSmith/received_events","type":"User","site_admin":false},"created_at":"2015-08-03T22:17:36Z","updated_at":"2015-08-03T22:17:36Z","body":"`bindings` seems fine to me, `ips` also seems odd with netmask going in there."}}