HTTP/2 protocol error: Received header value surrounded by whitespace
See original GitHub issueProblem Description
Youtube iOS app unable to connect through mitmproxy. The event log is as below
Web server listening at http://127.0.0.1:8081/
Proxy server listening at http://*:8080
192.168.1.106:50388: client connect
192.168.1.106:51246: client connect
192.168.1.106:51247: client connect
192.168.1.106:50388: server connect r1---sn-u2bpouxgoxu-hxay.googlevideo.com:443 (202.7.223.140:443)
192.168.1.106:51248: client connect
192.168.1.106:51246: server connect notifications-pa.googleapis.com:443 (142.250.70.138:443)
192.168.1.106:51247: server connect youtubei.googleapis.com:443 (142.250.70.170:443)
192.168.1.106:51248: server connect inappcheck.itunes.apple.com:443 (23.199.68.241:443)
192.168.1.106:50389: client connect
192.168.1.106:51249: client connect
192.168.1.106:50388: client disconnect
192.168.1.106:51247: 192.168.1.106:51247: HTTP/2 protocol error: Received header value surrounded by whitespace b'com.google.ios.youtube/16.38.2 (iPhone9,4; U; CPU iOS 14_7_1 like Mac OS X; en_AU) '
192.168.1.106:51248: Client TLS handshake failed. The client disconnected during the handshake. If this happens consistently for inappcheck.itunes.apple.com, this may indicate that the client does not trust the proxy's certificate.
192.168.1.106:51248: client disconnect
192.168.1.106:51247: client disconnect
Steps to reproduce the behavior:
- Launch mitmweb on macbook
- Connect iPhone 7 to the proxy
- Open Youtube iOS app
System Information
Mitmproxy: 7.0.3 Python: 3.9.7 OpenSSL: OpenSSL 1.1.1l 24 Aug 2021 Platform: macOS-11.6-x86_64-i386-64bit
Issue Analytics
- State:
- Created 2 years ago
- Comments:8 (6 by maintainers)
Top Results From Across the Web
ProtocolError: Received header value surrounded by ...
ProtocolError : Received header value surrounded by whitespace in requests_async ... I tried to find at least some information on this error, but ......
Read more >Fix Error ERR HTTP2 PROTOCOL ERROR on Chrome
In this Tutorial I will show you, Fix Error ERR HTTP2 PROTOCOL ERROR on Chrome.
Read more >RFC 2616: Hypertext Transfer Protocol -- HTTP/1.1
1. If the Request-URI is encoded using the "% HEX HEX" encoding [42], the origin server MUST decode the Request-URI in order to...
Read more >What is HTTP/2 – The Ultimate Guide - Kinsta
This in-depth guide explains HTTP/2 for end-users and developers. From basic information to more advanced topics.
Read more >core - Apache HTTP Server Version 2.4
To specify that another protocol is being used with a listening port, add the protocol argument to the Listen directive. The default values...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
This check can be disabled in mitmproxy 8 using the
validate_inbound_headersoption. 😃The problem is YouTube’s user agent, which incorrectly has a space at the end. We turned on some additional HTTP header validation in 7.0.3 to prevent request smuggling. Looks like we should only turn on what we need for that.
On Sat, 2 Oct 2021, 17:12 trungtly, @.***> wrote: