{"action":"created","issue":{"url":"https://api.github.com/repos/Cacti/plugin_mactrack/issues/76","repository_url":"https://api.github.com/repos/Cacti/plugin_mactrack","labels_url":"https://api.github.com/repos/Cacti/plugin_mactrack/issues/76/labels{/name}","comments_url":"https://api.github.com/repos/Cacti/plugin_mactrack/issues/76/comments","events_url":"https://api.github.com/repos/Cacti/plugin_mactrack/issues/76/events","html_url":"https://github.com/Cacti/plugin_mactrack/issues/76","id":324211397,"node_id":"MDU6SXNzdWUzMjQyMTEzOTc=","number":76,"title":"dhcp_snooping function broken","user":{"login":"jpobeda","id":13456559,"node_id":"MDQ6VXNlcjEzNDU2NTU5","avatar_url":"https://avatars1.githubusercontent.com/u/13456559?v=4","gravatar_id":"","url":"https://api.github.com/users/jpobeda","html_url":"https://github.com/jpobeda","followers_url":"https://api.github.com/users/jpobeda/followers","following_url":"https://api.github.com/users/jpobeda/following{/other_user}","gists_url":"https://api.github.com/users/jpobeda/gists{/gist_id}","starred_url":"https://api.github.com/users/jpobeda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jpobeda/subscriptions","organizations_url":"https://api.github.com/users/jpobeda/orgs","repos_url":"https://api.github.com/users/jpobeda/repos","events_url":"https://api.github.com/users/jpobeda/events{/privacy}","received_events_url":"https://api.github.com/users/jpobeda/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-05-17T22:44:44Z","updated_at":"2018-07-02T21:23:53Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"At some point, really hard to tell, this got broken. Specifically the IP and MAC collection.\r\n\r\nI printed the array_values of 'cdsBindingsIpAddress' and i get\r\n\r\n```\r\nArray\r\n(\r\n    [0] => ▒`▒\r\n    [1] => ▒`▒\r\n    [2] => ▒`▒▒\r\n    [3] => ▒`▒▒\r\n    [4] => ▒`▒▒\r\n)\r\n```\r\ncdsBindingsIpAddress gets populated right at the beginning of this function.\r\n\r\n`$cdsBindingsIpAddress \t= xform_stripped_oid('.1.3.6.1.4.1.9.9.380.1.4.1.1.4', $device);`\r\n\r\nThis OID returns Hex-STRING, that's why I apply xform_net_address to it. But it's broken right when cdsBindingsIpAddress gets populated.\r\n\r\nI thought i was something with xform_mac_address and/or xform_net_address functions but now I'm thinking it might be something with xform_stripped_oid. Not sure if there were changes made to that function.\r\n\r\nAny ideas?"},"comment":{"url":"https://api.github.com/repos/Cacti/plugin_mactrack/issues/comments/401940857","html_url":"https://github.com/Cacti/plugin_mactrack/issues/76#issuecomment-401940857","issue_url":"https://api.github.com/repos/Cacti/plugin_mactrack/issues/76","id":401940857,"node_id":"MDEyOklzc3VlQ29tbWVudDQwMTk0MDg1Nw==","user":{"login":"jpobeda","id":13456559,"node_id":"MDQ6VXNlcjEzNDU2NTU5","avatar_url":"https://avatars1.githubusercontent.com/u/13456559?v=4","gravatar_id":"","url":"https://api.github.com/users/jpobeda","html_url":"https://github.com/jpobeda","followers_url":"https://api.github.com/users/jpobeda/followers","following_url":"https://api.github.com/users/jpobeda/following{/other_user}","gists_url":"https://api.github.com/users/jpobeda/gists{/gist_id}","starred_url":"https://api.github.com/users/jpobeda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jpobeda/subscriptions","organizations_url":"https://api.github.com/users/jpobeda/orgs","repos_url":"https://api.github.com/users/jpobeda/repos","events_url":"https://api.github.com/users/jpobeda/events{/privacy}","received_events_url":"https://api.github.com/users/jpobeda/received_events","type":"User","site_admin":false},"created_at":"2018-07-02T21:23:53Z","updated_at":"2018-07-02T21:23:53Z","author_association":"CONTRIBUTOR","body":"@netniV I think the problem came after a yum update that has updated a whole bunch of php modules included php-snmp and the net-snmp package as well. Does this make sense to you?\r\n\r\nUnfortunately I can't downgrade it since packages aren't available. I'll try to reproduce this issue on a new VM with CentOS 7, that'll clarify.\r\n\r\nI've got a vm on my laptop with a \"similar\" setup which I haven't run yum update for a while and tested the latest develop branch and works fine. \r\n\r\nCurrent Prod server (CentOS 7.4 and Cacti 1.1.37) -> does NOT work\r\n\r\n> php-snmp.x86_64                    5.4.16-45.el7            @base\r\n\r\nTest VM (CentOS 6.9 and Cacti 1.1.37) -> works\r\n\r\n> php-snmp.x86_64        5.3.3-49.el6     @base\r\n\r\nThis function is mainly calling existing functions such as xform_stripped_oid which calls cacti_snmp_walk.\r\n\r\nAny ideas?\r\n\r\nWhat confuses me is that I've put a `print_r(array_values($cdsBindingsIpAddress));` right after it populates the variable and it prints all these funny characters, so only function involved is xform_stripped_oid and of course all the other functions that it calls.\r\n\r\n`$cdsBindingsIpAddress   = xform_stripped_oid('.1.3.6.1.4.1.9.9.380.1.4.1.1.4', $device);`\r\n\r\n\r\n\r\n"}}
{"actor":{"display_login":"jpobeda"}}