]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
tests: remove most user-agent filters
authorDaniel Stenberg <daniel@haxx.se>
Tue, 4 Nov 2025 10:22:32 +0000 (11:22 +0100)
committerDaniel Stenberg <daniel@haxx.se>
Tue, 4 Nov 2025 12:05:11 +0000 (13:05 +0100)
Use the %VERSION instead. The user-agent stripping was introduced at the
time before we had %VERSION (introduced in e6b21d4). The tests would
then remove the user-agent header to make them possible to be compared
in a version independent way.

Fixes #19355
Reported-by: Stefan Eissing
Closes #19356

37 files changed:
tests/data/test1571
tests/data/test1572
tests/data/test1573
tests/data/test1574
tests/data/test1575
tests/data/test1576
tests/data/test1577
tests/data/test1578
tests/data/test1579
tests/data/test1580
tests/data/test1581
tests/data/test1631
tests/data/test1632
tests/data/test1933
tests/data/test1934
tests/data/test1935
tests/data/test1936
tests/data/test1937
tests/data/test1938
tests/data/test1955
tests/data/test1956
tests/data/test1957
tests/data/test1958
tests/data/test1959
tests/data/test1964
tests/data/test1970
tests/data/test1971
tests/data/test1972
tests/data/test1973
tests/data/test1974
tests/data/test1975
tests/data/test1976
tests/data/test1978
tests/data/test545
tests/data/test794
tests/data/test796
tests/data/test797

index 622ec5ad15c4fa535d650ca0e829f9c782d3d29f..8a2bfb46167e0dd588a064f483d8444fa6773651 100644 (file)
@@ -75,9 +75,6 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes" nonewline="yes">
 IGLOO /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
index 36f3eef6e645ac021716563a33810537e1d15ea6..53683ed88faae5a494f3f3e77eb494144580dace 100644 (file)
@@ -75,9 +75,6 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes" nonewline="yes">
 IGLOO /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
index 62f5a0e88e59ef95302992b9f8e20f6406810990..e13522964f81eb81f9fe11dcea9f8bd88b2349f1 100644 (file)
@@ -75,9 +75,6 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes">
 IGLOO /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
index 501c40538956cf5bb8fb162be7f8a68c11773d33..fe4d7688c5893069be6457bbc56adaf6e1704c60 100644 (file)
@@ -75,9 +75,6 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes">
 IGLOO /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
index d02080b2da95343a91eac1836c572207859c25ca..53452af2c2de46a4d74726638a8f51185045ff8c 100644 (file)
@@ -75,9 +75,6 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes" nonewline="yes">
 IGLOO /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
index 8048e1329db7f01f241c2f86ae239de50b5f1283..fc24dd3e5e8e04eccd84e1d7c3361695a617b421 100644 (file)
@@ -75,9 +75,6 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes" nonewline="yes">
 CURL /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
index 42d26ae46da3b8cc724680ccd4ade055852eee9f..eeb3119fdcfa8f101c8575fc6cc846ab6822a43a 100644 (file)
@@ -75,9 +75,6 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER %TESTNUMBER
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes" nonewline="yes">
 CURL /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
index a8c9e7925a9c399d1744b25814ce92e1c973d7d7..b8e7c308c000350a12bfdb99344f346a30c53f63 100644 (file)
@@ -75,9 +75,6 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes" nonewline="yes">
 CURL /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
index 309f17a8bb2a3fe42218a62f3a2c7f93833861e9..c835eaf70ef27a0443e58f2f01664131a31132be 100644 (file)
@@ -75,9 +75,6 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER %TESTNUMBER
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes">
 CURL /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
index e67164a4276fca4e33bb5618a66a2aa4661a0345..99626c53a24388e40895a9c690539883188169c6 100644 (file)
@@ -75,9 +75,6 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER 1578
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes" nonewline="yes">
 CURL /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
index 5dac5229f4324dc5b2b20f9d9473476523553368..f3f29757a2154751469a77e4829997f79cb8bdc1 100644 (file)
@@ -75,9 +75,6 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes" nonewline="yes">
 IGLOO /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
index 7c2f81c3ee50f42af9839e846dbe473980fadfb2..6e28263b3df9573d7409731ee383542927ae801d 100644 (file)
@@ -59,17 +59,16 @@ proxy
 # opens for us, so we can't compare with a known pre-existing number!
 <strippart>
 s/((https.proxy):(\d+))/$2:12345/
-s/^(User-Agent: curl).*/$1/
 </strippart>
 <proxy crlf="headers">
 CONNECT ftp.site.thru.https.proxy:12345 HTTP/1.1
 Host: ftp.site.thru.https.proxy:12345
-User-Agent: curl
+User-Agent: curl/%VERSION
 Proxy-Connection: Keep-Alive
 
 CONNECT ftp.site.thru.https.proxy:12345 HTTP/1.1
 Host: ftp.site.thru.https.proxy:12345
-User-Agent: curl
+User-Agent: curl/%VERSION
 Proxy-Connection: Keep-Alive
 
 </proxy>
index 90cb56f616e4975e7f9efbdd79d75fad2a6e7502..ebf91098d5f84f6af4f12dcd02858e3eb30900e1 100644 (file)
@@ -69,22 +69,21 @@ proxy
 
 <strippart>
 s/((https.proxy):(\d+))/$2:12345/
-s/^(User-Agent: curl).*/$1/
 </strippart>
 <proxy crlf="headers">
 CONNECT ftp.site.thru.https.proxy:12345 HTTP/1.1
 Host: ftp.site.thru.https.proxy:12345
-User-Agent: curl
+User-Agent: curl/%VERSION
 Proxy-Connection: Keep-Alive
 
 CONNECT ftp.site.thru.https.proxy:12345 HTTP/1.1
 Host: ftp.site.thru.https.proxy:12345
-User-Agent: curl
+User-Agent: curl/%VERSION
 Proxy-Connection: Keep-Alive
 
 CONNECT ftp.site.thru.https.proxy:12345 HTTP/1.1
 Host: ftp.site.thru.https.proxy:12345
-User-Agent: curl
+User-Agent: curl/%VERSION
 Proxy-Connection: Keep-Alive
 
 </proxy>
index a26d29585caeac5da7932602872118062520c63a..57706dcf92ab9a98aa2959b69dbdb2a2ffbb2a13 100644 (file)
@@ -55,7 +55,6 @@ http://xxx:yyy@127.0.0.1:9000/%TESTNUMBER/testapi/test 127.0.0.1:9000:%HOSTIP:%H
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 9520c8193ec89c11663a5b5579741e0074283b79..a5bead447b4425d2e659273fb8066ebbbb80f3b8 100644 (file)
@@ -55,7 +55,6 @@ http://127.0.0.1:9000/%TESTNUMBER/testapi/test 127.0.0.1:9000:%HOSTIP:%HTTPPORT
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 4e0f11cb4fdf806a7ccc8d63b2e84cd63064ad03..64f0c21e062a7c87c813bc67a0a7de34e1bde546 100644 (file)
@@ -55,7 +55,6 @@ http://127.0.0.1:9000/%TESTNUMBER/testapi/test 127.0.0.1:9000:%HOSTIP:%HTTPPORT
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index d57b8161efa376e02ec33e823f95dec01a13853a..3ee3788f2c5b215338910ded3bb45eba22aca6df 100644 (file)
@@ -55,7 +55,6 @@ http://127.0.0.1:9000/%TESTNUMBER/testapi/test 127.0.0.1:9000:%HOSTIP:%HTTPPORT
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 816b9c18d766629cbb991625d3ee3954ea47080f..72fce57c5424be44541e95016b42214cff0dd13d 100644 (file)
@@ -56,7 +56,6 @@ http://127.0.0.1:9000/%TESTNUMBER/testapi/test 127.0.0.1:9000:%HOSTIP:%HTTPPORT
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index e2ed9837e86fc8cdea4982b852a02d57170e6656..7f719376e26fbcd895bba6114a2e50b0560652cd 100644 (file)
@@ -56,7 +56,6 @@ http://127.0.0.1:9000/%TESTNUMBER/testapi/test 127.0.0.1:9000:%HOSTIP:%HTTPPORT
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index be23a9d6284151432e411edb61a2dc1e3b3160f9..93d1422e8bf9873a460e18f3864dcaafc5d6bfbe 100644 (file)
@@ -55,7 +55,6 @@ http://exam.ple.com:9000/aws_sigv4/testapi/test exam.ple.com:9000:%HOSTIP:%HTTPP
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 324de3391370882ebd4cc4e777dfab536cb21104..b8c4710f982a7a739288dc0b13c5056364c00f89 100644 (file)
@@ -55,7 +55,6 @@ http://exam.ple.com:9000/aws_sigv4/testapi/test exam.ple.com:9000:%HOSTIP:%HTTPP
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 5a3c914b5bc6bc35d347aca63fd4fb4dbe45d555..0036b606447e59095c1d07ef66e68b8d2112f3fe 100644 (file)
@@ -55,7 +55,6 @@ http://exam.ple.com:9000/aws_sigv4/testapi/test exam.ple.com:9000:%HOSTIP:%HTTPP
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 220f49aa5e8cb31989f122428f6f89a6b68d8979..f5e38868c64bee348d4acbaca840f20d4ec191b0 100644 (file)
@@ -55,7 +55,6 @@ http://exam.ple.com:9000/aws_sigv4/testapi/test exam.ple.com:9000:%HOSTIP:%HTTPP
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index e91a3128e886012676fc692796806ad286f7dc53..8f43ed625c34827431cfe0c9849c8c4674052796 100644 (file)
@@ -55,7 +55,6 @@ http://exam.ple.com:9000/aws_sigv4/testapi/test exam.ple.com:9000:%HOSTIP:%HTTPP
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 9b7e2c968b1bc47dbfb2d413ea220d271cc97427..5cadbee5bc6bac96910a8f70d0c973b286c847f9 100644 (file)
@@ -54,7 +54,6 @@ http://xxx:yyy@127.0.0.1:9000/%TESTNUMBER/testapi/test 127.0.0.1:9000:%HOSTIP:%H
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 43df45e31f5d4e7c035ca405516caa312b47aefa..af15223599e81db1a79cbb51fab647a8eafdef06 100644 (file)
@@ -55,7 +55,6 @@ http://exam.ple.com:9000/aws_sigv4/testapi/test exam.ple.com:9000:%HOSTIP:%HTTPP
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 57cb834e95242782d40419a3d5de5632631d2029..52320d43447263ed91e6002a8722a0698ba04b88 100644 (file)
@@ -48,7 +48,6 @@ http://exam.ple.com:9000/aws_sigv4/testapi/test exam.ple.com:9000:%HOSTIP:%HTTPP
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 7b4168d119a380fefb43a1182609b54ad77049c2..d16ed4f775930949cc57f936d11446a6cb87e83d 100644 (file)
@@ -58,7 +58,6 @@ http://exam.ple.com:9000/aws_sigv4/testapi/test exam.ple.com:9000:%HOSTIP:%HTTPP
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 8b10e9ec484c516ad350046978b7cc388a1a78d4..7c45ceb5d68be410f0cc9b61195a57d6d3cec1a4 100644 (file)
@@ -55,7 +55,6 @@ http://exam.ple.com:9000/aws_sigv4/testapi/test exam.ple.com:9000:%HOSTIP:%HTTPP
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 74213d0ab694621bea505068adf6552a676e97c0..bac259715e21768d54a3911acf6929e27172a52d 100644 (file)
@@ -55,7 +55,6 @@ http://exam.ple.com:9000/aws_sigv4/testapi/test exam.ple.com:9000:%HOSTIP:%HTTPP
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 92fd563da868be05117f1ca958c03505f55b4ca6..e5a29d293623d54fd9846d3ca9f01e9b21ec7254 100644 (file)
@@ -48,7 +48,6 @@ http://exam.ple.com:9000/aws_sigv4/testapi/test exam.ple.com:9000:%HOSTIP:%HTTPP
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Type:.*
 ^Accept:.*
 </strip>
index 51e3b242b866c4621801f3e6f611022627d071c4..b573bf7deddd2a75f185f6fdf770c24df00b09d3 100644 (file)
@@ -39,7 +39,6 @@ HTTP AWS_SIGV4 canonical request header sorting test
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Length:.*
 ^Accept:.*
 </strip>
@@ -53,6 +52,7 @@ Host: %HOSTIP:%HTTPPORT
 Authorization: AWS4-HMAC-SHA256 Credential=xxx/19700101/us-east-1/s3/aws4_request, SignedHeaders=host;x-amz-content-sha256;x-amz-date;x-amz-meta-test;x-amz-meta-test-two, Signature=stripped
 X-Amz-Date: 19700101T000000Z
 x-amz-content-sha256: e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855
+User-Agent: curl/%VERSION
 X-Amz-Meta-Test-Two: test2
 x-amz-meta-test: test
 
index 007bbac55ce31c75232188a5d2232db20ff1df4a..a6c1272d9aa1711d32d758a01985898380560282 100644 (file)
@@ -42,7 +42,6 @@ http://xxx:yyy@127.0.0.1:9000/%TESTNUMBER/testapi/test 127.0.0.1:9000:%HOSTIP:%H
 # Verify data after the test has been "shot"
 <verify>
 <strip>
-^User-Agent:.*
 ^Content-Length:.*
 ^Accept:.*
 </strip>
index 363fe4dd7f37d310bf0fb7f55ffbf2864e77b09f..99bf04685187f82b3f02296ac900fd51dd43c503 100644 (file)
@@ -40,9 +40,6 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER
 #
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="headers" nonewline="yes">
 POST /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
index 63d3d36ba02f46459f7a7794e09d44d1de35a114..5fd1f76a06ef560a112bb95b34653e049b3eba9a 100644 (file)
@@ -72,18 +72,17 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER --no-progress-meter -X IGLOO -d moo --locat
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes" nonewline="yes">
 IGLOO /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
+User-Agent: curl/%VERSION
 Accept: */*
 Content-Length: 3
 Content-Type: application/x-www-form-urlencoded
 
 mooGET /%TESTNUMBER0001 HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
+User-Agent: curl/%VERSION
 Accept: */*
 
 
index e8750588100848347780871974f650548791c1ee..b945556a4611c994aae0cd7f731b212856eceb45 100644 (file)
@@ -72,18 +72,17 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER -X IGLOO -d moo --follow
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes" nonewline="yes">
 IGLOO /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
+User-Agent: curl/%VERSION
 Accept: */*
 Content-Length: 3
 Content-Type: application/x-www-form-urlencoded
 
 mooGET /%TESTNUMBER0001 HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
+User-Agent: curl/%VERSION
 Accept: */*
 
 
index f1f1a1ff183b14e04d86529ae64f0f22dcf360f4..2033829d145aad1b57ecf828c0dc6f508ab1ee23 100644 (file)
@@ -72,18 +72,17 @@ http://%HOSTIP:%HTTPPORT/%TESTNUMBER -X IGLOO -d moo --follow
 
 # Verify data after the test has been "shot"
 <verify>
-<strip>
-^User-Agent:.*
-</strip>
 <protocol crlf="yes" nonewline="yes">
 IGLOO /%TESTNUMBER HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
+User-Agent: curl/%VERSION
 Accept: */*
 Content-Length: 3
 Content-Type: application/x-www-form-urlencoded
 
 mooIGLOO /%TESTNUMBER0001 HTTP/1.1
 Host: %HOSTIP:%HTTPPORT
+User-Agent: curl/%VERSION
 Accept: */*
 Content-Length: 3
 Content-Type: application/x-www-form-urlencoded