CORKSCREW(1)
π« CORKSCREW(1) β General Commands Manual π«
okay bestie, gather round, because this little icon of a tool is about to become your new fave. it's called corkscrew, it lives in the General Commands Manual section (that's section 1, the "commands you actually type" section, iykyk), and it's literally the key that pops your TCP connections through an HTTP proxy like a little bottle opener. hence the name. obsessed. πΎβ¨
β¨ NAME β¨
corkscrew β tunnel TCP connections through HTTP proxies π
πΈ SYNOPSIS πΈ
corkscrew proxy proxyport targethost targetport [ authfile ]
that's it. that's the whole vibe. four required little friends and one optional one. π
π¦ DESCRIPTION π¦
so this manual page documents briefly the corkscrew command. and here's the tea: this man page was written for the Debian distribution because the original program does not have a manual page. so bestie, we wrote one. you're welcome. π
corkscrew is a simple tool to tunnel TCP connections through an HTTP proxy supporting the CONNECT method. it reads stdin and writes to stdout during the connection, just like netcat. no cap. π₯
and what's it for? for instance, you can use it to connect to an SSH server running on a remote 443 port through a strict HTTPS proxy. yes, that 443. the port that makes firewalls say "oh, that's fine, that's just HTTPS." genius behaviour. main character energy fr fr. π
π PARAMETERS π
proxyβ the name of the host that's running the HTTP proxy. like, who's holding the door for you. πͺproxyportβ the port you connect to on the proxy.targetβ the host you actually wanna reach, through the proxy.targetportβ the port you connect to on the target host.
ngl the SYNOPSIS calls the third onetargethostand this section calls ittargetβ that's just how it is, they're the same thing, don't stress. π«Ά
π COMMON USAGE π
the common usage of corkscrew (and honestly the iconic usage) is to drop this line into your ssh_config:
ProxyCommand corkscrew proxy proxyport %h %p
and that's it. that will let your ssh connection go through the proxy with the help of corkscrew. set it and forget it, bestie. ssh just β¨worksβ¨ now. π
π AUTH FILE π
the auth file is made of one single line containing your username and password in the form:
username:password
one line. that's the whole file. don't get fancy with it. π
and you should add the path to your auth file in the proxy command described above:
ProxyCommand corkscrew proxy proxyport %h %p auth-file
so corkscrew can hand over your creds when the proxy asks, no manual typing required. slay. π
π SEE ALSO π
π AUTHOR π
corkscrew was written by Pat Padgett <agroman@agroman.net>. Thomas Seyrat <tomasera@debian.org> is the debian maintainer for this package. and this manual page was written by Laurent Fousse <laurent@komite.net>, for the Debian GNU/Linux system (but may be used by others). give them their flowers, they earned them. π
okay that's the whole page, and the cute sign-off is: this one comes from the General Commands Manual source, version vibes dated November 22, 2003 β vintage but still serving. periodt. π β¨π
π¦ where this page comes from
- alpine 3.24: corkscrew-doc 2.0_git20190118-r1 Β· GPL-2.0-or-later
- fedora 43: corkscrew 2.0-40.fc43 Β· GPL-2.0-only
- fedora 44: corkscrew 2.0-42.fc44 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms