Date: Mon, 8 Jan 2007 20:32:11 +0000 From: Lee Brotherston <lee@nerds.org.uk> To: freebsd-hackers@freebsd.org Subject: TCP Checksums in mbufs Message-ID: <20070108203211.GF41066@nerds.org.uk>
next in thread | raw e-mail | index | archive | help
[-- Attachment #1 --]
Hi,
I have a bit of code I have written that uses pfil to access network
traffic as it passes between interfaces on a FreeBSD router. One of
the functions it performs is some incredibly basic rewrites of certain
packets (keeping the same length, so no issues about sequence
numbers), but it does alter the payload.
I just wanted to check what is the "proper" way to be going about
recalculating the checksums on the packet? I can write a function to
do this and write this into the packet stored in the mbuf directly,
however I wasn't sure if there was a more acceptable method such as
flagging it to be re-checksum'd as it's routed, or to offload the
computation to the NIC or something?
Any thoughts, suggestions, etc very welcome!
By the way, I'm not subscribed to the list right now, so I'd
appreciate it if people could CC me on replies.
Many thanks
Lee
--
Lee Brotherston - <lee@nerds.org.uk>
[-- Attachment #2 --]
0 *H
010 + 0 *H
400VnAMhAdQ0
*H
0b10 UZA1%0#U
Thawte Consulting (Pty) Ltd.1,0*U#Thawte Personal Freemail Issuing CA0
060505155852Z
070505155852Z0B10UThawte Freemail Member10 *H
lee@nerds.org.uk0"0
*H
0
Rb7´}a >P; @GT5ח<'y}7ow>|^abǓ?Y_~}2yu5oNGzx#,͂|PCPwF+ծ%ږщ9'<P9MJ7K6-o#3Gc!I`5}>[.X<, 1l__7) Fh
%V|!q.l'k @0>0 `HB 0U0lee@nerds.org.uk0U0 0
*H
]sw\=9j&Îh9@f֍ڨ:q#ؓx<ñ57Hʳlsw\ԙq3Eñ}UYLr({|đb`_zށ0?0
0
*H
010 UZA10UWestern Cape10U Cape Town10U
Thawte Consulting1(0&UCertification Services Division1$0"UThawte Personal Freemail CA1+0) *H
personal-freemail@thawte.com0
030717000000Z
130716235959Z0b10 UZA1%0#U
Thawte Consulting (Pty) Ltd.1,0*U#Thawte Personal Freemail Issuing CA00
*H
0 Ħ<UsUNʙZhup[v:aQP
0cZ,p+Z?qV˯<6$*+w=+>@dקe*TH<a@dr` 00U0 0CU<0:08642http://crl.thawte.com/ThawtePersonalFreemailCA.crl0U0)U"0 010UPrivateLabel2-1380
*H
HP.
fgCL!6-6/P p<ab:~ t%Pb'qW%ݩ9 Oe_N4[5MwV!x!5$F]_eO1Q0M0v0b10 UZA1%0#U
Thawte Consulting (Pty) Ltd.1,0*U#Thawte Personal Freemail Issuing CAnAMhAdQ0 + 0 *H
1 *H
0 *H
1
070108203210Z0# *H
1ɞRo5JGr<ъ%0R *H
1E0C0
*H
0*H
0
*H
@0+0
*H
(0
*H
zKq4iž5h}
cf/O\'{ℑ n&(ՌFS0|CQ9A\z!:)E]M'Қ͇Ae0#dOY)4!|H]sɴS!pz8#{cU*E;3uMiEܦhU!Yyȵ>83IQC4/pה{oNdͿ-b^LಝuF
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070108203211.GF41066>
