Networking Forums

Networking Forums > Computer Networking > Linux Networking > Packet Manipulation advice request.

Reply
Thread Tools Display Modes

Packet Manipulation advice request.

 
 
Richard Stone
Guest
Posts: n/a

 
      08-09-2004, 10:37 AM
Hi,
I'm looking for a mechanism which would enable me to manipulate the
payload of a known UDP packet. Ideally I'm looking for solutions that
maybe already available, not sure whether IPTables could be used.

Here's the scenario.
I have a dual-homed Linux gateway. The gateway will be looking for a
certain packet/s on one of its interfaces. On receipt of the packet it
will manipulate the payload of the packet by replacing current padding
within the payload with some other data. It will then send the packet
out of it's other interface to the intended recipient.

If I had the time I'd probably implement my own IPTables type of
approach but as with most things I needed to have done this by
yesterday.

Is it possible to use iptables/netfilter to perform the task?
Identifying the packet is no problem its simply the payload
manipulation I'm really concerned with.
 
Reply With Quote
 
 
 
 
P Gentry
Guest
Posts: n/a

 
      08-09-2004, 03:03 PM
(E-Mail Removed) (Richard Stone) wrote in message news:<(E-Mail Removed). com>...
> Hi,
> I'm looking for a mechanism which would enable me to manipulate the
> payload of a known UDP packet. Ideally I'm looking for solutions that
> maybe already available, not sure whether IPTables could be used.
>
> Here's the scenario.
> I have a dual-homed Linux gateway. The gateway will be looking for a
> certain packet/s on one of its interfaces. On receipt of the packet it
> will manipulate the payload of the packet by replacing current padding
> within the payload with some other data. It will then send the packet
> out of it's other interface to the intended recipient.
>
> If I had the time I'd probably implement my own IPTables type of
> approach but as with most things I needed to have done this by
> yesterday.
>
> Is it possible to use iptables/netfilter to perform the task?
> Identifying the packet is no problem its simply the payload
> manipulation I'm really concerned with.


Off the top of my head ...

It sounds like you need a proxy on the GW to handle these packets --
netfilter will handle headers and the like, but to read _and_ rewrite
the payload you're going to have to roll your own.

BTW, by rewriting the payload you'll also need to recalculate the crc
of the FCS.

Then, of course, what is the listener on the other end going to do
with this munged payload? Sounds like you'll need a proxy at that end
also unless you have reason to believe it can properly handle
"arbitrary" payloads by parsing out the munged part or blindly
accepting whatever it is sent.

Perhaps there is a better way to accomplish your needs?

hth,
prg
email above disabled
 
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Request for advice - UPS for my PC Brian White Home Networking 1 02-26-2008 06:26 PM
Request advice about which instant messaging to use when phone line is busy Lemmo Broadband 3 01-15-2008 08:45 AM
DHCP Request packet sent over and over Philip Herlihy Windows Networking 4 08-17-2007 11:31 AM
network traffic manipulation box jas0n Linux Networking 5 05-02-2005 07:46 PM
ARP Request packet??plz reply soon ANaiveProgrammer Linux Networking 5 11-25-2004 01:47 PM



1 2 3 4 5 6 7 8 9 10 11