Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Intercept traffic #13

Open
max-frai opened this issue Oct 10, 2023 · 1 comment
Open

Intercept traffic #13

max-frai opened this issue Oct 10, 2023 · 1 comment

Comments

@max-frai
Copy link

max-frai commented Oct 10, 2023

Hello, thank you for this great example. I have one use-case, when I should know the exact status code returned by requested server. Now we can't do it, because we just setup tunnel between requester and remote server. I need to make some manipulations if remote server returns some error codes.
I tried to intercept received bytes and extract http headers from it, but it's encrypted bytes as I think, because I request data by https. Are there any easy way to switch to plain http and not encrypt it in tunnel?

With plain_text feature and http site I can dump bytes and see the headers like:

HTTP/1.1 200 OK\r\nContent-Encoding: gzip\r\nAge: 394582\r\nCache-Control: max-age=604800\r\nContent-Type: text/html; charset=UTF-8\r\nDate: Tue, 10 Oct 2023 16:05:49 GMT\r\nEtag: \"3147526947+gzip\"\r\nExpires: Tue, 17 Oct 2023 16:05:49 GMT\r\nLast-Modified: Thu, 17 Oct 2019 07:18:26 GMT\r\nServer: ECS (laa/7B7B)\r\nVary: Accept-Encoding\r\nX-Cache: HIT\r\nContent-Length: 648\r\n\r\n\u{1f}�\u{8}\.....

@xnuter
Copy link
Owner

xnuter commented Oct 23, 2023

Yes, you can build the HTTP tunnel with the plaintext feature and establish HTTP connections.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants