[pso] Tema 5 --- tcp flags

Mihai Iancu pso@cursuri.cs.pub.ro
Wed, 16 Jun 2004 03:16:06 -0700 (PDT)


--0-1958412181-1087380966=:22238
Content-Type: text/plain; charset=us-ascii

inlocuieste flags cu 
unsigned char  fin:1,syn:1,rst:1,psh:1,ack:1,urg:1,ece:1,cwr:1;

Rizoiu Valentin <rizoiu_valentin@yahoo.com> wrote:
Am si eu o intrebare legata de tema5 Win:
 din ce am citit in msdn structurile pt. ip/tcp/udp nu prea ar fi definite ...si prin urmare
ar cam trebui sa le definim noi... tcphdr de ex ar trebui sa arate cam ashea:
typedef struct _tcphr
{
 USHORT   src
 USHORT   dst; 
 ULONG   seq;  
 ULONG   ack; 
 UCHAR   dataoffset; 
 UCHAR   flags;    
 USHORT   window; 
 USHORT   checksum;
 USHORT   urgent; 
} tcphdr;
 
In acest caz cum se pot scoate (din campul flags) flag-urile pt. SYN / ACK / FIN ?
Ma intereseaza  care sunt biti pe care sa-i citesc/verific..
 
 
:
          



---------------------------------
Do you Yahoo!?
New and Improved Yahoo! Mail - 100MB free storage!
		
---------------------------------
Do you Yahoo!?
Yahoo! Mail is new and improved - Check it out!
--0-1958412181-1087380966=:22238
Content-Type: text/html; charset=us-ascii

<DIV>inlocuieste flags cu </DIV>
<DIV>unsigned char&nbsp; fin:1,syn:1,rst:1,psh:1,ack:1,urg:1,ece:1,cwr:1;<BR><BR><B><I>Rizoiu Valentin &lt;rizoiu_valentin@yahoo.com&gt;</I></B> wrote:</DIV>
<BLOCKQUOTE class=replbq style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #1010ff 2px solid">
<DIV>Am si eu&nbsp;o intrebare legata de tema5 Win:</DIV>
<DIV>&nbsp;din ce am citit in msdn structurile pt. ip/tcp/udp nu prea ar fi definite ...si prin urmare</DIV>
<DIV>ar cam trebui sa le definim noi... tcphdr de ex ar trebui sa arate cam ashea:<BR>typedef struct _tcphr<BR>{<BR>&nbsp;USHORT&nbsp;&nbsp;&nbsp;src</DIV>
<DIV>&nbsp;USHORT&nbsp;&nbsp;&nbsp;dst;&nbsp;<BR>&nbsp;ULONG&nbsp;&nbsp;&nbsp;seq;&nbsp;&nbsp;<BR>&nbsp;ULONG&nbsp;&nbsp;&nbsp;ack;&nbsp;<BR>&nbsp;UCHAR&nbsp;&nbsp;&nbsp;dataoffset;&nbsp;<BR>&nbsp;UCHAR&nbsp;&nbsp;&nbsp;flags;&nbsp;&nbsp;&nbsp;&nbsp;<BR>&nbsp;USHORT&nbsp;&nbsp;&nbsp;window;&nbsp;<BR>&nbsp;USHORT&nbsp;&nbsp;&nbsp;checksum;<BR>&nbsp;USHORT&nbsp;&nbsp;&nbsp;urgent;&nbsp;<BR>} tcphdr;</DIV>
<DIV>&nbsp;</DIV>
<DIV>In acest caz cum se pot scoate (din campul flags) flag-urile pt. SYN / ACK / FIN ?</DIV>
<DIV>Ma intereseaza&nbsp; care sunt biti pe care sa-i citesc/verific..</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>:</DIV>
<DIV><STRONG>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </STRONG><BR></DIV>
<P>
<HR SIZE=1>
Do you Yahoo!?<BR><A href="http://us.rd.yahoo.com/mail/taglines/*http://promotions.yahoo.com/new_mail/static/efficiency.html">New and Improved Yahoo! Mail</A> - 100MB free storage!</BLOCKQUOTE><p>
		<hr size=1>Do you Yahoo!?<br>
Yahoo! Mail is new and improved - <a href="http://us.rd.yahoo.com/mail/taglines/*http://promotions.yahoo.com/new_mail">Check it out!</a>
--0-1958412181-1087380966=:22238--