Gray Hole Attack in NS2

69 views
Skip to first unread message

Rizki Asriyanda

unread,
Jan 31, 2023, 9:05:00 AM1/31/23
to Network Simulator 2 (NS2)
May i get the patch file for simulating Greyhole Attack with AOMDV Protocol?

knudfl

unread,
Feb 10, 2023, 11:37:13 AM2/10/23
to Network Simulator 2 (NS2)
Students etc. who once developed ns2 code / ns2 additions did not usually upload the code.
From the ten thousands of projects, only a 100 pieces of code were uploaded / saved.

Besides that, ns2 has not been supported for many years.

------------------------
Gray-hole attack for ns3 is mentioned here  https://ns3simulation.com/phd-in-ns3-simulation/
Ref.  Google search :   ns3 greyhole   /   ns3 grayhole

Rizki Asriyanda

unread,
Feb 15, 2023, 2:15:19 PM2/15/23
to Network Simulator 2 (NS2)
so is it true that ns2 doesn't support grayhole, can you give me some real proof in the form of anything that says ns2 doesn't support grayhole? thanks in advance 🙏🏻

knudfl

unread,
Feb 15, 2023, 4:42:52 PM2/15/23
to Network Simulator 2 (NS2)
"ns2 .... support grayhole" : grayholeaodv is available   https://drive.google.com/file/d/0B7S255p3kFXNZEthbi1SSUxpeWs/view?usp=sharing

Google       ns2 greyhole aomdv

If you want  "grayholeAOMDV" , I guess it's for you to port the available AODV code to AOMDV, if possible.

-

Rizki Asriyanda

unread,
Feb 16, 2023, 3:15:29 AM2/16/23
to Network Simulator 2 (NS2)
I have previously also tried running grayholeAODV but it didn't work

knudfl

unread,
Feb 16, 2023, 6:34:16 AM2/16/23
to Network Simulator 2 (NS2)
Build example with grayholeaodv_ns235.patch
tar xvf ns-allinone-2.35_gcc5.tar.gz                 //  2014 update
https://drive.google.com/file/d/0B7S255p3kFXNVVlxR0ZNRGVORjQ/view?usp=sharing
cd ns-allinone-2.35/
patch -p0 < grayholeaodv_ns235.patch
https://drive.google.com/file/d/0B7S255p3kFXNZEthbi1SSUxpeWs/view?usp=sharing
export CC=gcc-4.8 CXX=g++-4.8 && ./install
cd ns-2.35/
cp ns ns235-grey
sudo cp ns235-grey /usr/local/bin/
-----  Simulation  --------
ns235-grey file.tcl
________________________________________
grayholeaodv__sketchy-ex-1.tar.gz  →  May work, or may not all work
https://drive.google.com/file/d/15leQpuDs-XU6vNUMT_ULnOBzyxsJEnkz/view?usp=sharing

Testing ......
$ ns235-grey bb.tcl              OK
$ ns235-grey Gray-aodv-50.tcl     OK
!    grayholeaodv.tcl  is a configuration file


-

Rizki Asriyanda

unread,
Feb 17, 2023, 3:47:58 AM2/17/23
to Network Simulator 2 (NS2)

I will try it, but if it doesn't work I will ask again, thank you sir!
Reply all
Reply to author
Forward
0 new messages