About FlipRoles function

周斌 <[email protected]> Tue, 17 Dec 2019 15:23:43 +0800 (CST)
Newsgroups gmane.comp.security.detection.bro
Message-ID <[email protected]>
--===============0305495790==
Content-Type: multipart/alternative; 
	boundary="----=_Part_184000_431051387.1576567423996"

------=_Part_184000_431051387.1576567423996
Content-Type: text/plain;charset=UTF-8
Content-Transfer-Encoding: quoted-printable

Hi everybody,
   Sorry my English. I have noticed that in conn.cc(zeek-3.0.1\src) file th=
ere is a address translation in the method Connection::FlipRoles. The sourc=
e code is:
        IPAddr tmp_addr =3D resp_addr
=09  resp_addr =3D orig_addr
=09  orig_addr =3D tmp_addr


=09  uint32 tmp_port =3D resp_port
=09  resp_port =3D orig_port
=09  orig_port =3D tmp_port
    I have tow questions:
    1. When the function(Connection::FlipRoles) was called=EF=BC=9F
    2. Not need to think of MAC address=EF=BC=9F
  =20
   And I've run into some technical problems recently. In conn.log, You can=
 see:
  "id.orig_h":"Source IP","id.resp_h":"Destination IP",......"orig_l2_addr"=
:"Destination MAC","resp_l2_addr":"Source MAC".=20


Thanks,
Zhoubin

------=_Part_184000_431051387.1576567423996
Content-Type: text/html;charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div>Hi everybody,</div><div>&nbsp; &nbsp;Sorry my English. I have noticed =
that in conn.cc(zeek-3.0.1\src) file there is a address translation in the =
method Connection::FlipRoles. The source code is:</div><div>&nbsp; &nbsp; &=
nbsp; &nbsp; <font size=3D"2" oldel=3D"1"><i>IPAddr tmp_addr =3D resp_addr;=
</i></font></div><div><font size=3D"2" oldel=3D"1"><i><span style=3D"white-=
space:pre">=09</span>&nbsp; resp_addr =3D orig_addr;</i></font></div><div><=
font size=3D"2" oldel=3D"1"><i><span style=3D"white-space:pre">=09</span>&n=
bsp; orig_addr =3D tmp_addr;</i></font></div><div><font size=3D"2" oldel=3D=
"1"><i><br></i></font></div><div><font size=3D"2" oldel=3D"1"><i><span styl=
e=3D"white-space:pre">=09</span>&nbsp; uint32 tmp_port =3D resp_port;</i></=
font></div><div><font size=3D"2" oldel=3D"1"><i><span style=3D"white-space:=
pre">=09</span>&nbsp; resp_port =3D orig_port;</i></font></div><div><font s=
ize=3D"2" oldel=3D"1"><i><span style=3D"white-space:pre">=09</span>&nbsp; o=
rig_port =3D tmp_port;</i></font></div><div>&nbsp; &nbsp; I have tow questi=
ons:</div><div>&nbsp; &nbsp; 1. When the function(Connection::FlipRoles) wa=
s called=EF=BC=9F</div><div>&nbsp; &nbsp; 2. Not need to think of MAC addre=
ss=EF=BC=9F</div><div>&nbsp; &nbsp;</div><div>&nbsp; &nbsp;And I've run int=
o some technical problems recently. In conn.log, You can see:</div><div>&nb=
sp; "id.orig_h":"Source IP","id.resp_h":"Destination IP",......"orig_l2_add=
r":"Destination MAC","resp_l2_addr":"Source MAC".&nbsp;</div><div><br></div=
><div>Thanks,</div><div>Zhoubin</div>
------=_Part_184000_431051387.1576567423996--


--===============0305495790==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Zeek mailing list
[email protected]
http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/zeek
--===============0305495790==--