plots: fixes for multitarget

This commit is contained in:
Pascal Engélibert 2026-05-22 17:08:33 +02:00
commit f450c68039
2 changed files with 97 additions and 22 deletions

40
exp.py
View file

@ -72,14 +72,14 @@ CONFIGS = {
# i7-4790 -> pi3
"pi3": {
"experiments": [
"impl-cipher-ver",
#"impl-cipher-ver",
"impl-cert-ver",
"impl-kex-ver",
#"impl-kex-ver",
#"zrtt",
#"realistic"
],
"sides": [
"client",
#"client",
"server",
],
"tls": [
@ -113,9 +113,9 @@ CONFIGS = {
# i7-4790 -> core2
"core2": {
"experiments": [
#"impl-cipher-ver",
"impl-cipher-ver",
"impl-cert-ver",
#"impl-kex-ver",
"impl-kex-ver",
#"zrtt",
#"realistic",
],
@ -124,8 +124,8 @@ CONFIGS = {
#"server",
],
"tls": [
False,
#True,
#False,
True,
],
"records": [
{ "filename": "wp2", "repeat": 10000, "time": 300 },
@ -182,9 +182,9 @@ CONFIGS = {
# i7-4790 -> i5-7300HQ
"i5": {
"experiments": [
#"impl-cipher-ver",
#"impl-cert-ver",
"impl-kex-ver",
"impl-cipher-ver",
"impl-cert-ver",
#"impl-kex-ver",
#"zrtt",
#"realistic",
],
@ -193,13 +193,14 @@ CONFIGS = {
"server",
],
"tls": [
False,
#False,
True,
],
"records": [
{ "filename": "wp2", "repeat": 10000, "time": 300 },
#{ "filename": "yt2-ads", "repeat": 10000, "time": 600 },
#{ "filename": "yt2-ublock", "repeat": 10000, "time": 600 },
#{ "filename": "wp2", "repeat": 10000, "time": 300, "reproduce": 100 },
],
"repo_dir": "/home/tuxmain/reps/tlsbench",
"exp_dir": "/dev/shm/exp",
@ -357,7 +358,6 @@ IMPLS = [
#"openssl-static",
#"ring", # used in most Rust stuff
"symcrypt", # Microsoft's crypto
#"wolfcrypt" # used in embedded (won't build with rpxy for now)
]
# Symmetric ciphers
# They also allow to choose the TLS version.
@ -497,7 +497,7 @@ def alg_filter(kex, cert, cipher, impl):
return False
#if cert == "secp384r1" and impl == "boring":
# return False
if kex == "SECP256R1MLKEM768" and impl == "graviola":
if kex == "SECP256R1MLKEM768" and impl in ["graviola", "boring"]:
return False
if kex == "MLKEM768" and impl in ["graviola", "boring"]:
return False
@ -628,7 +628,10 @@ def run_netreplay_server(ssh, exp_dir, repo_dir, record, listen_addr, listen_por
if exp_dir[-1] != "/":
exp_dir += "/"
repo_dir = repo_dir.removesuffix("/")
env = {"RUST_LOG": "warning", "SSLKEYLOGFILE": "/dev/shm/netreplay.keys.txt"}
env = {
"RUST_LOG": "warning",
#"SSLKEYLOGFILE": "/dev/shm/netreplay.keys.txt" # exports keys for use with WireShark, but may fill memory if a lot of traffic is generated!
}
if ld_preload and impl in ld_preload:
env["LD_PRELOAD"] = ld_preload[impl]
if ciphers:
@ -651,7 +654,11 @@ def run_netreplay_client(
if exp_dir[-1] != "/":
exp_dir += "/"
repo_dir = repo_dir.removesuffix("/")
env = {"RUST_LOG": "warning", "SSLKEYLOGFILE": "/dev/shm/netreplay.keys.txt", "EARLYDATA": earlydata}
env = {
"RUST_LOG": "warning",
#"SSLKEYLOGFILE": "/dev/shm/netreplay.keys.txt",
"EARLYDATA": earlydata,
}
if ld_preload and impl in ld_preload:
env["LD_PRELOAD"] = ld_preload[impl]
if ciphers:
@ -872,6 +879,7 @@ def run_exp(config, only_record=None, idle=False, shutdown=False, debug=False):
debug=debug,
ld_preload=config["ld_preload"] if "ld_preload" in config else None,
)
time.sleep(4)
netreplay = run_netreplay_client(
ssh,
config["exp_dir"],
@ -908,6 +916,8 @@ def run_exp(config, only_record=None, idle=False, shutdown=False, debug=False):
debug=debug,
ld_preload=config["ld_preload"] if "ld_preload" in config else None,
)
# Loading the certificates takes a few seconds on the RPi3
time.sleep(4)
netreplay = run_netreplay_client(
None,
config["exp_dir"],