> If the hostname is detected to be longer than 255 bytes, curl switches to local name resolving and instead passes on the resolved address only to the proxy.
This sounds like an issue in itself, even if it is intended. Is that max length of the hostname a limitation of SOCKS5?
Let's assume you're using TOR through a SOCKS5 proxy, then any tool which uses libcurl will perform a local host lookup upon a https call (or redirect) to a long hostname, like one with a dynamically assigned UUID in a subdomain.