-
Notifications
You must be signed in to change notification settings - Fork 1.1k
[BUG] Proxy connection not working #2719
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
Comments
I have applied the following patch, but get:
Command:
|
An ugly workaround is to query a public DNS server:
I need to figure out with the DNS master why there are no A records internally, but my understanding is that with a proxy there is no need to resolve the hostname at all, that is what the proxy is for. |
Thanks for filing the issue. What do you expect when providing z-n none`? There's no DNS resolution of the proxy IP at least. But when providing the proxy IP and the FQDN of the target IIRC that should work automatically. That does not using 3.2 though. It works though (for 3.2) when one uses There was a change wrt to Likely this won't be addressed in 3.0 anymore. Please use 3.2 |
Let me double check tomorrow for 3.2 |
Latest RC looks a bit better, but still not good:
I still don't understand why testssl.sh needs to resolve the proxy IP eventhough In contrast:
Yet another tricky you. For several hosts we have split DNS, thus internally they have one address and maybe different TLS and form the internet another IP address. If you use a proxy for scanning your report the internal IP address, but are actually scanning the public one. Here is an example:
|
One answer is on the code above. IPv6 proxy doesn't work with the openssl version you were using. Even the IPv4 proxy code was backported in your openssl. Moreover we don't use openssl everywhere but bash sockets . Or how did you think your ./bin/openssl.FreeBSD.amd64 does a check for TLS 1.3? |
That makes sense, but to add an important detail is that there is no IPv6 here at all. I don't know whether this makes a difference. |
No / not yet. See code. Other than that I do not understand what's inconsistent here? The behavior is also documented, see ~/doc/ dir. What we could think of is changing the default so that DNS_VIA_PROXY's default is true. |
This is reasonable especially when we assume that hosts behind a proxy oare on a purpose not available directly. |
Hi @drwetter . I really don't remember why we switched it to false. There had to be some use case that needed it, but I should retest it since that was a long time ago. However, reading the comments in #2328, I saw that I wrote another version of the code, but never created the PR. I have reviewed the code, and DNS_VIA_PROXY has been set back to true in a cleaner, more straightforward approach: I have created the PR in case you want to have a look: #2728 |
@drwetter just thinking again about the change, I think it was related to this comment: #2328 (comment) Since there are some DNS records that might not work through proxies, we decided to keep DNS_VIA_PROXY as false by default, and let the user choose if the resolution takes place exclusively at the proxy by adding My new PR sets DNS_VIA_PROXY to true again and follows this approach:
However, if there are some checks that make use of other DNS records apart from A, AAAA and CNAME, this approach may not work. |
Thanks. --> next week I can look at it. Still don't know yet whether I'd like to merge it now as said, it's a breaking change. Apart from that: Looks like your PR needs to be rebased. |
Hi @drwetter , thank you for your comment. I have rebased my PR and it should look fine right now. Let me know if you take a look at it. |
@michael-o : could you try with 3.2.0:
|
That should be handled either
|
and
|
Thanks, the latter looks as expected. The first may be just consistent but it's confusing for the user. I guess the best would be (in 3.2) to change |
I am running version
testssl.sh version 3.0.9 from https://testssl.sh/
Before you open an issue please whether this is a known problem by searching the issues
I couldn't find anything
Command line / docker command to reproduce
Consider the following:
It is not really clear why you have to resolve the IP address of the proxy yourself since both curl and openssl-s_client will happily accept hostnames and will invoke
getaddrinfo()
for you.Expected behavior
Use the proxy as-is, ideally.
Your system (please complete the following information):
FreeBSD 13.5-STABLE
FreeBSD 13.5-STABLE amd64
Using bash 5.2.37. OpenSSL 1.0.2-chacha (1.0.2k-dev) [~183 ciphers]
The text was updated successfully, but these errors were encountered: