Hi,
I Have Litle problem under perl 5.8.0 on redhat 8.0.
perl -v
This is perl, v5.8.0 built for i386-linux-thread-multi
Ihave litle code which use socket
use Socket 1.3;
no utf8;
socket(RAW,17, 3, 255) || die $!; #open raw socket
my $inetrface=1; #1-lo 2-eth0 3-eth1
#sending raw data to socket this data must by ethernet packet but for
+this examle this is irelevant if packet is not valid proble is same w
+ith valid packet
# ______d_a_t_a_______
send(RAW,"\255\127\255\255\255",0,pack("SniC12",17,0,$interface,0)) ||
+ die "Send :$!\n";
but if I do strace on this program Iget this line which corespondig with sent. Look closer to data on this kernel call there is \302\255 and not plain \255 but ffor \127 is same \127
sendto(3, "\302\255W\302\255\302\255\302\255", 9, 0, {sin_family=AF_PA
+CKET, proto=0000, if1, pkttype=0,addr(0)={0, }, 20) = 9
Please help with som workaround or somethin else ??
on perl 5.6.1 this is without problems ! data in perl send a at kernel call sendto is same and raw packet is valid.
Thank's for help
-=- MamuT -=-
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.