Date: Thu, 5 Mar 2020 17:29:36 +0100 From: Nick Hibma <nick@van-laarhoven.org> To: "Alexander V. Chernikov" <melifaro@ipfw.ru> Cc: FreeBSD Architecture Mailing List <freebsd-arch@freebsd.org> Subject: Re: change divert socket to use a sockaddr_div struct Message-ID: <BFE8EA16-7EF4-4C46-8F04-571939BBC730@van-laarhoven.org> In-Reply-To: <8181583419268@vla1-c477e3898c96.qloud-c.yandex.net> References: <FDA3F6E5-5CB3-4A28-BE61-34A374886B9A@van-laarhoven.org> <8181583419268@vla1-c477e3898c96.qloud-c.yandex.net>
next in thread | previous in thread | raw e-mail | index | archive | help
Thanks for the prod. I've created a diff in Phabricator: https://reviews.freebsd.org/D23972 <https://reviews.freebsd.org/D23972> I would appreciate comments on this. Nick Hibma nick@van-laarhoven.org -- Open Source: We stand on the shoulders of giants. > On 05/03 /2020, at 15:42, Alexander V. Chernikov <melifaro@ipfw.ru> = wrote: >=20 > 27.02.2020, 09:16, "Nick Hibma" <nick@van-laarhoven.org>: >> Folks, > Hi Nick, >>=20 >> We would like to use FIBs for routing, but currently cannot because = the FIB is lost when the packet goes through a divert socket for = processing. I've attached a patch that should fix this situation, and = while there fix the limit of 7 characters for the interface name which = some people got bitten by. This fix was suggested some time ago by = Warner Losh. > It looks like the patch got stripped by the mailing list. > Could you please publish it on https://reviews.freebsd.org ? >>=20 >> I've changed the sockaddr_in to a sockaddr_di struct to pass the FIB = number and the complete interface, and other info in and out. But this = seems to lead to memory corruption. Perhaps someone who knows the API = can tell me where I should look for memory corruption issues, because = this patch causes random crashes. I assume it's because of overwriting = random memory. >>=20 >> Thanks in advance. >>=20 >> Nick Hibma >> nick@van-laarhoven.org >>=20 >> -- Open Source: We stand on the shoulders of giants. >>=20 >> _______________________________________________ >> freebsd-arch@freebsd.org mailing list >> https://lists.freebsd.org/mailman/listinfo/freebsd-arch >> To unsubscribe, send any mail to = "freebsd-arch-unsubscribe@freebsd.org" >=20
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?BFE8EA16-7EF4-4C46-8F04-571939BBC730>