cURL / Mailing Lists / curl-library / Single Mail


Re: HTTP connection to unix socket

From: Nikolai Kondrashov <>
Date: Mon, 14 Apr 2008 12:59:13 +0400

Daniel Stenberg wrote:
> Thinking about it, we can even abuse the port number field if we just
> require the slashes to be encoded:
> It just means that we'd treat a non-numeric port number as a unix domain
> socket path.
Why do you insist on abusing HTTP URL scheme? Why not introduce another one?
We could take file URL scheme:


And extend it:

unix://<host>/<socket path>?<URL-encoded tunnelled URL>

This way we could use it for any protocol tunnelled through a UNIX socket.
I.e. an HTTP URL accessible via UNIX socket could look like that:


(Note: host part is omitted, as it is done with file URLs)

It looks not that good, but it is safe and quite flexible.

Received on 2008-04-14