[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: kern/111313: packet with IP option corrupted when going through Dummynet
- To: freebsd-bugs_(_at_)_FreeBSD_(_dot_)_org
- Subject: Re: kern/111313: packet with IP option corrupted when going through Dummynet
- From: Marcin Cieslak <saper_(_at_)_SYSTEM_(_dot_)_PL>
- Date: Fri, 1 Jun 2007 21:50:06 GMT
- Cc:
- Reply-to: Marcin Cieslak <saper_(_at_)_SYSTEM_(_dot_)_PL>
The following reply was made to PR kern/111313; it has been noted by GNATS.
From: Marcin Cieslak <saper_(_at_)_SYSTEM_(_dot_)_PL>
To: bug-followup_(_at_)_FreeBSD_(_dot_)_org
Cc: luping_(_at_)_cs_(_dot_)_unc_(_dot_)_edu, remko_(_at_)_FreeBSD_(_dot_)_org
Subject: Re: kern/111313: packet with IP option corrupted when going through
Dummynet
Date: Fri, 01 Jun 2007 23:13:19 +0200
This modification goes down to the patch listed below.
I am experiencing similar problem with IPSec ESP+NAT-T
encapsulated packets, so maybe there is something there.
(It still applies cleanly to the sys/netinet/ip_output.c revision
1.242.2.15 or even 1.242.2.18 (current as of time of the writing)).
--
<< Marcin Cieslak // saper_(_at_)_system_(_dot_)_pl >>
--- ip_output.c Fri Jun 1 22:56:35 2007
+++ ip_output_111313.c Fri Jun 1 22:55:50 2007
@@ -159,6 +159,10 @@
}
ip = mtod(m, struct ip *);
+ /* luping modification */
+ struct m_tag *dn_tag;
+ dn_tag = m_tag_find(m, PACKET_TAG_DUMMYNET, NULL);
+
/*
* Fill in IP header. If we are not allowing fragmentation,
* then the ip_id field is meaningless, but we don't set it
@@ -172,7 +176,11 @@
*/
if ((flags & (IP_FORWARDING|IP_RAWOUTPUT)) == 0) {
ip->ip_v = IPVERSION;
- ip->ip_hl = hlen >> 2;
+ //luping modification
+ if (dn_tag == NULL)
+ ip->ip_hl = hlen >> 2;
+ else
+ hlen = ip->ip_hl << 2;
ip->ip_id = ip_newid();
ipstat.ips_localout++;
} else {
_______________________________________________
freebsd-bugs_(_at_)_freebsd_(_dot_)_org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-bugs
To unsubscribe, send any mail to "freebsd-bugs-unsubscribe_(_at_)_freebsd_(_dot_)_org"
Visit your host, monkey.org