This repository has been archived by the owner on May 1, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Dev Tips
Stuart Mashaal edited this page Nov 14, 2017
·
9 revisions
- We will use the
lab2-NN.cs.mcgill.ca
machines as the nodes in our network, whereNN
takes on any range of values (you choose when you test or run our code) from 1 to 50. - We will use
cs-1.cs.mcgill.ca
as our directory node andcs-2.cs.mcgill.ca
as our destination node for testing the network. We will usecs-10.cs.mcgill.ca
as the originator.
- SSH into
lab2-NN.cs.mcgill.ca
NN = 1,2,3 - change the prompts so as to easily identify each one:
PS1="NODE NN > "
- SSH into
cs-NN.cs.mcgill.ca
NN = 1,2,10 - change the prompts so as to easily identify each one:
-
PS1="DIR > "
for cs-1 -
PS1="DST > "
for cs-2 -
PS1="SRC > "
for cs-10
-
- Turn on the Directory node with 5 nodes on port 5551:
python3 onion_directory.py 5 5551
- Turn on the all the Router nodes on port 5551:
python3 onion_router.py 5551
- Turn on the Destination node on port 5557:
python3 onion_destination.py 5557
- Turn on the Source node to connect to the destination node through port 5557 and communicate with the onion network through port 5551:
python3 onion_client.py cs-2 5551 -d 5557
- When debugging, add the verbose flag
-v
at the end of each onion command to get useful status messages
The McGill firewall prevents us from connecting to one of its computers over non-standard TCP ports like we're doing (it probably stops a bunch more too). To get around this, we should run the originator code on a computer inside the McGill network. For convention, let's pick cs-10.cs.mcgill.ca
.
- Useful paper on onion routing: https://www.onion-router.net/Publications/IH-1996.pdf