From f0cf1bbf19657385340129d3c1bff5be9b0cbc2f Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Thu, 2 Jan 2020 00:15:27 +0000 Subject: [PATCH] xdh: End-to-end tests for the new DH key agreement groups Signed-off-by: Ian Jackson --- stest/common.tcl | 5 +++++ stest/t-dh-x25519 | 7 +++++++ stest/t-dh-x448 | 7 +++++++ 3 files changed, 19 insertions(+) create mode 100755 stest/t-dh-x25519 create mode 100755 stest/t-dh-x448 diff --git a/stest/common.tcl b/stest/common.tcl index 5d45183..00e0e75 100644 --- a/stest/common.tcl +++ b/stest/common.tcl @@ -365,6 +365,11 @@ proc adj-after {timeout args} { eval after $timeout $args } +proc sitesconf-hook-dh {l dh} { + regsub {^\s+dh .*$} $l "dh $dh;\n" l + return $l +} + proc test-kex {} { udp-proxy spawn-secnet in inside diff --git a/stest/t-dh-x25519 b/stest/t-dh-x25519 new file mode 100755 index 0000000..3df0b4b --- /dev/null +++ b/stest/t-dh-x25519 @@ -0,0 +1,7 @@ +#! /usr/bin/tclsh + +source stest/common.tcl + +proc sitesconf_hook {l} { return [sitesconf-hook-dh $l x25519] } + +test-kex diff --git a/stest/t-dh-x448 b/stest/t-dh-x448 new file mode 100755 index 0000000..ca6e654 --- /dev/null +++ b/stest/t-dh-x448 @@ -0,0 +1,7 @@ +#! /usr/bin/tclsh + +source stest/common.tcl + +proc sitesconf_hook {l} { return [sitesconf-hook-dh $l x448] } + +test-kex -- 2.30.2