From f738842adba3a50a6019ff6d0360763e7540659d Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Mon, 31 Oct 2022 12:01:12 +1300 Subject: [PATCH] tests: Replace OpenSSL MD4 invocation with a python3 call This will allow the test to pass on Ubuntu 22.04 which has MD4 disabled in OpenSSL by default. Signed-off-by: Andrew Bartlett Reviewed-by: Stefan Metzmacher --- source3/script/tests/test_rpcclient_pw_nt_hash.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source3/script/tests/test_rpcclient_pw_nt_hash.sh b/source3/script/tests/test_rpcclient_pw_nt_hash.sh index 33e49a86f92..24d81519c4c 100755 --- a/source3/script/tests/test_rpcclient_pw_nt_hash.sh +++ b/source3/script/tests/test_rpcclient_pw_nt_hash.sh @@ -15,7 +15,7 @@ PASSWORD="$2" SERVER="$3" RPCCLIENT="$4" -HASH=$(echo -n $PASSWORD | iconv -t utf16le | openssl md4 | cut -d ' ' -f2) +HASH=$(echo -n $PASSWORD | iconv -t utf16le | $PYTHON -c 'import sys, binascii, samba, samba.crypto; sys.stdout.buffer.write(binascii.hexlify(samba.crypto.md4_hash_blob(sys.stdin.buffer.read(1000))))') RPCCLIENTCMD="$RPCCLIENT $SERVER --pw-nt-hash -U$USERNAME%$HASH -c queryuser"