Skip to content

Commit

Permalink
Add interop tests with google for X25519MLKEM768 and x25519_kyber768
Browse files Browse the repository at this point in the history
Signed-off-by: Basil Hess <[email protected]>
  • Loading branch information
bhess committed Oct 2, 2024
1 parent 77214a4 commit c4dcd1c
Showing 1 changed file with 14 additions and 8 deletions.
22 changes: 14 additions & 8 deletions scripts/oqsprovider-externalinterop.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,6 @@ fi

# Ascertain algorithms are available:

# skipping these tests for now as per https://mailarchive.ietf.org/arch/msg/tls/hli5ogDbUudAA4tZXskVbOqeor4
# TBD replace with suitable ML-KEM hybrid tests as and when available XXX

echo " Cloudflare:"

if ! ($OPENSSL_APP list -kem-algorithms | grep x25519_kyber768); then
Expand All @@ -39,8 +36,17 @@ else
(echo -e "GET /cdn-cgi/trace HTTP/1.1\nHost: cloudflare.com\n\n"; sleep 1; echo $'\cc') | "${OPENSSL_APP}" s_client ${USE_PROXY} -connect pq.cloudflareresearch.com:443 -groups x25519_kyber768 -servername cloudflare.com -ign_eof 2>/dev/null | grep kex=X25519Kyber768Draft00
fi

#if ! ($OPENSSL_APP list -kem-algorithms | grep x25519_kyber512); then
# echo "Skipping unconfigured x25519_kyber512 interop test"
#else
# (echo -e "GET /cdn-cgi/trace HTTP/1.1\nHost: cloudflare.com\n\n"; sleep 1; echo $'\cc') | "${OPENSSL_APP}" s_client ${USE_PROXY} -connect pq.cloudflareresearch.com:443 -groups x25519_kyber512 -servername cloudflare.com -ign_eof 2>/dev/null | grep kex=X25519Kyber512Draft00
#fi
echo " Google:"

if ! ($OPENSSL_APP list -kem-algorithms | grep x25519_kyber768); then
echo "Skipping unconfigured x25519_kyber768 interop test"
else
echo -e "GET / HTTP/1.1\r\nHost: www.google.com\r\nConnection: close\r\n\r\n" | "${OPENSSL_APP}" s_client ${USE_PROXY} -connect google.com:443 -groups x25519_kyber768 -servername google.com >/dev/null 2>/dev/null
fi


if ! ($OPENSSL_APP list -kem-algorithms | grep X25519MLKEM768); then
echo "Skipping unconfigured X25519MLKEM768 interop test"
else
echo -e "GET / HTTP/1.1\r\nHost: www.google.com\r\nConnection: close\r\n\r\n" | "${OPENSSL_APP}" s_client ${USE_PROXY} -connect google.com:443 -groups X25519MLKEM768 -servername google.com >/dev/null 2>/dev/null
fi

0 comments on commit c4dcd1c

Please sign in to comment.