Hi, On Fri, Feb 11, 2022 at 12:27:37PM +0100, Gert Doering wrote: > the crucial part is "lsi=0x0" here, I think, but I'm not sure why... we do > have a socket, we know we bound it to IPv6 (+dual-stack)...
Trying this trivial fix...
--- a/src/openvpn/mss.c
+++ b/src/openvpn/mss.c
@@ -234,7 +234,7 @@ get_ip_encap_overhead(const struct options *options,
{
/* Add the overhead of the encapsulating IP packets */
sa_family_t af;
- if (lsi->lsa)
+ if (lsi && lsi->lsa)
{
af = lsi->lsa->actual.dest.addr.sa.sa_family;
}
... moves the crash onward to
0x00005555555891b6 in datagram_overhead (proto=<error reading variable: Cannot
access memory at address 0x24>, af=10) at socket.h:617
617 overhead += (proto == PROTO_UDP) ? 8 : 20;
(gdb) where
#0 0x00005555555891b6 in datagram_overhead (proto=<error reading variable:
Cannot access memory at address 0x24>, af=10) at socket.h:617
#1 get_ip_encap_overhead (lsi=0x0, options=0x555555642280) at mss.c:248
#2 frame_calculate_mssfix (lsi=0x0, options=0x555555642280, kt=0x555555642b40,
frame=0x555555642dd0) at mss.c:305
#3 frame_calculate_dynamic (frame=frame@entry=0x555555642dd0,
kt=kt@entry=0x555555642b40, options=options@entry=0x555555642280, lsi=0x0)
at mss.c:334
#4 0x000055555557b2bb in init_instance (c=c@entry=0x555555642280,
env=<optimized out>, flags=flags@entry=10) at init.c:4234
#5 0x000055555557c4a6 in inherit_context_child
(dest=dest@entry=0x555555642280, src=src@entry=0x7fffffffc4b0) at init.c:4459
which looks weird, but is likely due to inlining.
The culprit is this one:
return datagram_overhead(af, lsi->proto);
"lsi" is still NULL...
Not sure how to fix this in a good way.
gert
--
"If was one thing all people took for granted, was conviction that if you
feed honest figures into a computer, honest figures come out. Never doubted
it myself till I met a computer with a sense of humor."
Robert A. Heinlein, The Moon is a Harsh Mistress
Gert Doering - Munich, Germany [email protected]
signature.asc
Description: PGP signature
_______________________________________________ Openvpn-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/openvpn-devel
