On 8/17/06, Roy S. Rapoport <[EMAIL PROTECTED]> wrote:

[snip]

> Aaron, thanks for the attempted help.  It almost entirely worked :)
>
> Here's what I did.  All were with 2.3.5, and I used your patch, which was
> applied successfully:
>
> $i is the pcap file
>
> A) tcpprep -a -n server -i $i -o ${i}.cache
> B) tcpreplay -i eth0 -j eth0 -I $DMAC -k $SMAC -J $SMAC -K $DMAC -c 
> ${i}.cache -w ${i}.rewritten.pcap ${i}
>
> This chugged and chugged, and eventually ended.  When I opened the file
> in ethereal, however,
> A) MAC addresses were all 0s; and
> B) all the DNS payload shows up as "[Malformed Packet: DNS]"
>
> (A) I could probably live with, because once the transformation to
> ethernet was done, I could probably use tcprewrite to rewrite the MAC
> addresses.

Yeah, nothing really i can suggest about that right now.

> (B) is sort of bad :)

That one is actually easy to fix.  edit do_packets.c.  And go to line
218 and add the single line like so:


        l2len = 4; /* add this line.  Note that this is the length of
the HDLC header */

        /* Rewrite any Layer 2 data */
        if ((newl2len = rewrite_l2(&pkthdr, pktdata, nextpkt,
                                   linktype, l2enabled, l2data, l2len)) == 0)


That should fix it so that all the packets (not just the first one)
aren't truncated.

> I know you're busy, so I'm not expecting a resolution anytime soon, but I
> figured I'd mention :)

No prob.  Happy to help.

-- 
Aaron Turner
http://synfin.net/

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Tcpreplay-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tcpreplay-users

Reply via email to