Date: Thu, 20 Sep 2001 21:50:23 -0500 (CDT) From: Les Biffle <les@safety.net> To: davep@afterswish.com Cc: Alfred Perlstein <bright@mu.org>, hackers@FreeBSD.ORG Subject: Re: sendto not sending what I asked... Message-ID: <200109210250.f8L2oO615274@ns3.safety.net> In-Reply-To: <01092111231604.36513@development.wgtn.csg.co.nz>
next in thread | previous in thread | raw e-mail | index | archive | help
> pkt.ipbit.ip_sum=in_cksum((unsigned short*)(void*)&pkt,20); > pkt.tcpbit.th_sum=tcpsum(&pkt.ipbit); You need to do the TCP checksum first. It changes the payload (the TCP checksum). The IP checksum includes all data, so must be done after the payload changes are done. -Les -- Les Biffle (480) 585-4099 les@safety.net http://www.les.safety.net/ Network Safety Corp., 5831 E. Dynamite Blvd., Cave Creek, AZ 85331 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200109210250.f8L2oO615274>