【发布时间】:2018-01-17 23:06:51
【问题描述】:
curl --http2 -i -v -d '{"aps":{"alert":"hello"}}' -H "apns-topic: xxxx" -H "authorization: bearer xxxxx" https://api.development.push.apple.com/3/device/xxx
卷曲版本:
curl 7.46.0 (x86_64-pc-linux-gnu) libcurl/7.46.0 OpenSSL/1.0.1f zlib/1.2.8 libidn/1.28 nghttp2/1.25.0-DEV librtmp/2.3
Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtmp rtsp smb smbs smtp smtps telnet tftp
Features: IDN IPv6 Largefile NTLM NTLM_WB SSL libz TLS-SRP HTTP2 UnixSockets
发布:
POST /3/device/xxxxx HTTP/1.1
错误:
@@uUnexpected HTTP/1.x request: POST /3/device/xxx
如果我用 http2 运行简单的 curl 就可以了
curl --http2 -I https://nghttp2.org/
HTTP/2.0 200
【问题讨论】:
标签: linux curl apple-push-notifications http2