curl / Mailing Lists / curl-users / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

Re: Making HTTP2 requests

From: Luke Schlather via curl-users <curl-users_at_lists.haxx.se>
Date: Sat, 15 Jul 2023 07:54:11 -0700

Ah, no I was just looking at the version and I thought 8.01 did but I guess
it's not listed in features.

> curl -V
curl 8.0.1 (Windows) libcurl/8.0.1 Schannel WinIDN
Release-Date: 2023-03-20
Protocols: dict file ftp ftps http https imap imaps pop3 pop3s smtp smtps
telnet tftp
Features: AsynchDNS HSTS HTTPS-proxy IDN IPv6 Kerberos Largefile NTLM
SPNEGO SSL SSPI threadsafe Unicode UnixSockets

It's odd that it accepts the http2 options if it doesn't support it.

On Sat, Jul 15, 2023 at 4:53 AM Daniel Stenberg <daniel_at_haxx.se> wrote:

> On Fri, 14 Jul 2023, Luke Schlather via curl-users wrote:
>
> > I am attempting to test a local .NET Kestrel server which only accepts
> > http2 requests. However it seems that even when I specify --http2 it
> sends
> > http1 requests.
> >
> >> curl --http2 -i http://localhost:5000/health
>
> Doing HTTP/2 with a HTTP:// URL scheme means that curl makes a HTTP/1
> request
> with an upgrade header.
>
> >> curl --http2-prior-knowledge -i http://localhost:5000/health
> > HTTP/1.1 400 Bad Request
> > Connection: close
> > Content-Type: text/plain
> > Content-Length: 56
> >
> > An HTTP/1.x request was sent to an HTTP/2 only endpoint.
>
> This is unexpected. Are you sure your curl supports HTTP/2 ?
>
> --
>
> / daniel.haxx.se
> | Commercial curl support up to 24x7 is available!
> | Private help, bug fixes, support, ports, new features
> | https://curl.se/support.html
>


-- 
Unsubscribe: https://lists.haxx.se/mailman/listinfo/curl-users
Etiquette:   https://curl.se/mail/etiquette.html
Received on 2023-07-15