Skip to content

hyper: root cause of curl test 265 failure #8853

@pmk21

Description

@pmk21

I did this

Ran curl test 265, analyzed the debug trace and generated logs, concluded that hyper is probably closing the connection on receiving a HTTP/1.0 response.

I switched HTTP/1.0 with HTTP/1.1 at these locations -

HTTP/1.0 407 Authorization Required to proxy me my dear

HTTP/1.0 407 Authorization Required to proxy me my dear

The test seems to be passing, though there are a few small differences in the output -

265: protocol FAILED:
--- log/check-expected  2022-05-14 16:27:59.457379329 +0530
+++ log/check-generated 2022-05-14 16:27:59.457379329 +0530
@@ -1,16 +1,16 @@
-CONNECT test.remote.example.com.265:44167 HTTP/1.1[LF]
+CONNECT test.remote.example.com.265:44167 HTTP/1.1[CR][LF]
 Host: test.remote.example.com.265:44167[CR][LF]
 Proxy-Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA=[CR][LF]
 User-Agent: curl/7.83.1-DEV[CR][LF]
 Proxy-Connection: Keep-Alive[CR][LF]
 [CR][LF]
-CONNECT test.remote.example.com.265:44167 HTTP/1.1[LF]
+CONNECT test.remote.example.com.265:44167 HTTP/1.1[CR][LF]
 Host: test.remote.example.com.265:44167[CR][LF]
 Proxy-Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAAIAAgAeAAAAAAAAAAAAAAAhoIBAFpkQwKRCZFMhjj0tw47wEjKHRHlvzfxQamFcheMuv8v+xeqphEO5V41xRd7R9deOXRlc3R1c2VyY3VybGhvc3Q=[CR][LF]
 User-Agent: curl/7.83.1-DEV[CR][LF]
 Proxy-Connection: Keep-Alive[CR][LF]
 [CR][LF]
-POST /path/2650002 HTTP/1.1[LF]
+POST /path/2650002 HTTP/1.1[CR][LF]
 Host: test.remote.example.com.265:44167[CR][LF]
 User-Agent: curl/7.83.1-DEV[CR][LF]
 Accept: */*[CR][LF]

I expected the following

After switching to HTTP/1.1, I expected the test case to pass, but there are a few small differences.

curl/libcurl version

curl 7.83.1-DEV (x86_64-pc-linux-gnu) libcurl/7.83.1-DEV OpenSSL/1.1.1o zlib/1.2.12 brotli/1.0.9 zstd/1.5.2 libidn2/2.3.2 libpsl/0.21.1 (+libidn2/2.3.0) librtmp/2.3 Hyper/0.14.18 OpenLDAP/2.6.1
Release-Date: [unreleased]
Protocols: dict file ftp ftps gopher gophers http https imap imaps ldap ldaps mqtt pop3 pop3s rtmp smb smbs smtp smtps telnet tftp 
Features: alt-svc AsynchDNS brotli Debug HSTS HTTP2 HTTPS-proxy IDN Largefile libz NTLM NTLM_WB PSL SSL TLS-SRP TrackMemory UnixSockets zstd

operating system

Linux msi 5.15.38-1-MANJARO #1 SMP PREEMPT Mon May 9 07:52:21 UTC 2022 x86_64 GNU/Linux

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions