Re(2): NKE tcp redirect socket filter 10.4+
Re(2): NKE tcp redirect socket filter 10.4+
- Subject: Re(2): NKE tcp redirect socket filter 10.4+
- From: "Peter Lovell" <email@hidden>
- Date: Thu, 10 May 2007 15:25:48 -0400
On Thu, May 10, 2007, Erez Kaplan <email@hidden> wrote:
> >The documentation does exist to accomplish this on your own
>Which documentation are you referring to other than "NKEConceptual"?
>I have gone through it many times, but other than scattered hints, I
>found nothing.
>
>I am basing my work on "tcplognke"
>Is this the correct starting point?
>
>
Hi Erez,
the capability does indeed work, although it is not for the faint of heart.
Since Josh is (sort of) away, I'll help get this going for you.
The older documentation is somewhat skimpy, and possibly dates from the
time when the capability did *not* work (unless you applied kernel
patches -- wheee!!). Fortunately, those days are long gone and KPI is
your friend.
Essentially you have to replace the contents in the destination address,
usually a sockaddr_in but might also be sockaddr_in6, with your wanted
destination address and port.
Something like ...
struct sockaddr_in *sdest = (struct sockaddr_in *)to;
sdest->sin_port = myDest.sin_port;
sdest->sin_addr.s_addr = myDest.sin_addr.s_addr;
Regards.....Peter
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden