Skip to content

Commit

Permalink
Added the ultrix timitngs
Browse files Browse the repository at this point in the history
  • Loading branch information
gdanezis committed Oct 21, 2017
1 parent 607ccad commit 97d3dc9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
6 changes: 1 addition & 5 deletions sphinxmix/UltrixClient.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,6 @@ def create_header(params, nodelist, keys, assoc=None, secrets = None, gamma=None

plain_beta_len = (max_len - 32) - len(node_id)


plain = node_id + beta[:plain_beta_len]
beta = p.xor_rho(p.hrho(asbtuples[i].aes), plain)
beta_all = [ beta ] + beta_all
Expand Down Expand Up @@ -270,6 +269,7 @@ def decode_surb(params, header, enc_dest):

from nacl.bindings import crypto_scalarmult_base, crypto_scalarmult


def test_ultrix_c25519(rep=100, payload_size=1024 * 10):
r = 5
from .SphinxParamsC25519 import Group_C25519
Expand Down Expand Up @@ -408,7 +408,3 @@ def test_minimal_ultrix():

received = receive_surb(params, surbkeytuple, delta)
assert received == message


if __name__ == "__main__":
test_c25519()
5 changes: 5 additions & 0 deletions timings_ultrix.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Run as: python -OO -m cProfile -s tottime timings.py > prof.txt

if __name__ == "__main__":
from sphinxmix.UltrixClient import test_ultrix_c25519
test_ultrix_c25519(rep=1000, payload_size=1024 * 10)

0 comments on commit 97d3dc9

Please sign in to comment.