Skip to content

cmd/tailcat: allow socks mode without cmd - #20

Open
tw4452852 wants to merge 2 commits into
tailscale:mainfrom
tw4452852:push-qktuykvnssrz
Open

cmd/tailcat: allow socks mode without cmd#20
tw4452852 wants to merge 2 commits into
tailscale:mainfrom
tw4452852:push-qktuykvnssrz

Conversation

@tw4452852

Copy link
Copy Markdown

This is useful when user only wants to start a general socks proxy server which can accept connections from other applications in the system. Currently, we could still achieve this with this ugly way: tailcat socks adrblob bash -c 'env | grep all_proxy; read'.

Change-Id: I9f651f4c7780155c0c0bd4f48fa233d16a6a6964

This is useful when user only wants to start a general socks proxy server
which can accept connections from other applications in the system.
Currently, we could still achieve this with this ugly way:
`tailcat socks adrblob bash -c 'env | grep all_proxy; read'`.

Signed-off-by: Tw <tw19881113@gmail.com>
Change-Id: I9f651f4c7780155c0c0bd4f48fa233d16a6a6964

@bradfitz bradfitz left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like the idea of this, thanks! But in this mode, shouldn't you have control over the localhost port number, or maybe even whether the SOCKS5 proxy binds to the unspecified address instead of localhost?

Maybe we need a --listen=string flag for the socks subcommand, and if the string is an integer, it's a localhost port, else it can be ":12345" for 0.0.0.0/:: (i.e. a net.Listen string)

@tw4452852

tw4452852 commented Aug 29, 2026

Copy link
Copy Markdown
Author

Yes, --listen is definitely my next step. And I think address customization could also be applied with cmd.

Add ability to specify the binding address for the socks proxy server.

Signed-off-by: Tw <tw19881113@gmail.com>
Change-Id: I1a8298d005f96a9b1db5c2d3fd7628946a6a6964
@tw4452852

Copy link
Copy Markdown
Author

Hi @bradfitz, I've appended a commit to support the --listen, please take a look, thanks!

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

Successfully merging this pull request may close these issues.

2 participants