RFC: fix clientaddr for 5.8
I've committed the following fix to the 5.7-patches branch: https://sourceforge.net/p/net-snmp/code/ci/3defab66a7aee60ba582a8254412abd2e630c321/ It turns out that when you specify a clientaddr, the steps the function takes are: - zero out addr_pair - store the remote address in addr_pair - lookup the clientaddr - zero out addr_pair - store the clientaddr in addr_pair The second zeroing out (added in cea974008da30de8d39a1f8ede7189265d93d598) results in the remote address being 0.0.0.0, which results in simply getting an error from sendto because you can not send to 0.0.0.0. I'd like to merge this to master so that sessions using clientaddr work in the 5.8 release. Thanks, Bill -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot___ Net-snmp-coders mailing list Net-snmp-coders@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
Re: RFC: fix clientaddr for 5.8
On 05/14/18 08:00, Bill Fenner wrote: I've committed the following fix to the 5.7-patches branch: https://sourceforge.net/p/net-snmp/code/ci/3defab66a7aee60ba582a8254412abd2e630c321/ It turns out that when you specify a clientaddr, the steps the function takes are: - zero out addr_pair - store the remote address in addr_pair - lookup the clientaddr - zero out addr_pair - store the clientaddr in addr_pair The second zeroing out (added in cea974008da30de8d39a1f8ede7189265d93d598) results in the remote address being 0.0.0.0, which results in simply getting an error from sendto because you can not send to 0.0.0.0. I'd like to merge this to master so that sessions using clientaddr work in the 5.8 release. If you want to avoid that commit fc14e89dd2a2 ("ifm_media changed from u_int to uint64_t in OpenBSD 5.9") ends up on the master branch you will have to do a git cherry-pick instead of git merge. Otherwise I'm in favor of the above proposal. Bart. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Net-snmp-coders mailing list Net-snmp-coders@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
Re: RFC: fix clientaddr for 5.8
On Mon, 14 May 2018 08:44:19 -0700 Bart wrote: BVA> > https://sourceforge.net/p/net-snmp/code/ci/3defab66a7aee60ba582a8254412abd2e630c321/ BVA> > BVA> > It turns out that when you specify a clientaddr, the steps BVA> > the function takes are: BVA> > BVA> > - zero out addr_pair BVA> > - store the remote address in addr_pair BVA> > - lookup the clientaddr BVA> > - zero out addr_pair BVA> > - store the clientaddr in addr_pair BVA> > BVA> > The second zeroing out (added in BVA> > cea974008da30de8d39a1f8ede7189265d93d598) results in the BVA> > remote address being 0.0.0.0, which results in simply BVA> > getting an error from sendto because you can not send to BVA> > 0.0.0.0. BVA> > BVA> > I'd like to merge this to master so that sessions using BVA> > clientaddr work in the 5.8 release. BVA> BVA> If you want to avoid that commit fc14e89dd2a2 ("ifm_media BVA> changed from u_int to uint64_t in OpenBSD 5.9") ends up on the BVA> master branch you will have to do a git cherry-pick instead of BVA> git merge. Otherwise I'm in favor of the above proposal. +1 on both counts (commit it, but use cherry-pick). Robert -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Net-snmp-coders mailing list Net-snmp-coders@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
Re: RFC: fix clientaddr for 5.8
Den 14-05-2018 kl. 20:05 skrev Robert Story: +1 on both counts (commit it, but use cherry-pick). +1 (and I wouldn't mind the OpenBSD part getting merged too) /Niels -- Niels Baggesen - @home - Ã…rhus - Denmark - n...@users.sourceforge.net The purpose of computing is insight, not numbers --- R W Hamming -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Net-snmp-coders mailing list Net-snmp-coders@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
Re: RFC: fix clientaddr for 5.8
I got myself confused again with the rewritten transport code. "Applying the patch to 5.8" is nonsense, so, nevermind this request. Bill -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot___ Net-snmp-coders mailing list Net-snmp-coders@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/net-snmp-coders