|
@@ -4,6 +4,7 @@ import random # For simulation, not cryptography!
|
|
import math
|
|
import math
|
|
import sys
|
|
import sys
|
|
import logging
|
|
import logging
|
|
|
|
+import resource
|
|
|
|
|
|
import network
|
|
import network
|
|
import dirauth
|
|
import dirauth
|
|
@@ -86,6 +87,7 @@ if __name__ == '__main__':
|
|
|
|
|
|
# Uncomment to see all the debug messages
|
|
# Uncomment to see all the debug messages
|
|
# logging.basicConfig(level=logging.DEBUG)
|
|
# logging.basicConfig(level=logging.DEBUG)
|
|
|
|
+ logging.basicConfig(level=logging.INFO)
|
|
|
|
|
|
# Set the Walking Onions style to use
|
|
# Set the Walking Onions style to use
|
|
network.thenetwork.set_wo_style(womode, snipauthmode)
|
|
network.thenetwork.set_wo_style(womode, snipauthmode)
|
|
@@ -96,3 +98,8 @@ if __name__ == '__main__':
|
|
|
|
|
|
# Create the simulation
|
|
# Create the simulation
|
|
simulator = Simulator(relaytarget, clienttarget)
|
|
simulator = Simulator(relaytarget, clienttarget)
|
|
|
|
+
|
|
|
|
+ network.thenetwork.nextepoch()
|
|
|
|
+
|
|
|
|
+ maxmemmib = resource.getrusage(resource.RUSAGE_SELF).ru_maxrss/1024
|
|
|
|
+ logging.info("%d MiB used", maxmemmib)
|