单个 SSH SOCKS 5 代理中的多个连接

发布于 2024-08-30 01:09:47 字数 748 浏览 4 评论 0原文

我在 Stackoverflow 上的第一个问题:我需要做什么才能使 SSH SOCKS 5 代理 (SSH2) 允许多个连接?

我注意到,当我在 Firefox 中加载页面时(已经配置为使用 SOCKS 5 代理),它会一一加载所有内容。它可以通过肉眼感知,并且我还通过使用 Firebug 的 NET 选项卡来确认这一点,该选项卡记录了已建立的连接。

我已经在 about:config 页面中配置了一些指令,例如管道、持久代理连接和其他一些内容。但我仍然得到这种资源的顺序加载,这明显非常慢。

network.http.pipelining;true
network.http.pipelining.maxrequests;8
network.http.pipelining.ssl;true
network.http.proxy.pipelining;true
network.http.max-persistent-connections-per-proxy;100
network.proxy.socks_remote_dns;true

我的 ISP 很糟糕,因为它在白天故意随机断开连接。因此,如果不需要大量刷新浏览器或按 F5 键,就不可能真正完成有意义的工作。所以,这就是为什么我开始寻找解决方案。

SSH 的动态端口转发是我迄今为止找到的最好的解决方案,因为它有一些相当好的压缩,可以节省大量无用的流量,而且也很安全。剩下的唯一一件事就是让它运行多个连接。

感谢您的所有投入。

My fist question here on Stackoverflow: What should I need to do so that the SSH SOCKS 5 Proxy (SSH2) will allow multiple connections?

What I have noticed, is that when I load a page in Firefox (already configured to use the SOCKS 5 proxy), it loads everything one by one. It can be perceived by bare eyes, and I also confirm that through the use of Firebug's NET tab, which logs the connections that have been made.

I have already configure some of the directives in the about:config page, like pipeline, persistent proxy connections, and a few other things. But I still get this kind of sequential load of resources, which is noticeably very slow.

network.http.pipelining;true
network.http.pipelining.maxrequests;8
network.http.pipelining.ssl;true
network.http.proxy.pipelining;true
network.http.max-persistent-connections-per-proxy;100
network.proxy.socks_remote_dns;true

My ISP sucks because during the day, it intentionally breaks connections on a random basis. And so, it is impossible to actually accomplish meaningful works without the need of a lot of browser refresh or hitting F5 key. So, that is why I started to find solutions to this.

The SSH's dynamic port forwarding is the best solution I find to date, because it has some pretty good compression which saves a lot of useless traffic, and is also secure. The only thing remaining is to get it to have multiple connections running in it.

Thanks for all the inputs.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

碍人泪离人颜 2024-09-06 01:09:47

我有同样的想法,我的结论是它应该已经有多个连接通过袜子代理。这是因为,如果您使用 -vvv 标志查看 ssh 连接,您会注意到它为不同的请求打开不同的端口。

I have had the same thoughts and my conclusion is that it should already have multiple connections going through the socks proxy. This is because if you view the ssh connection with -vvv flag, you'll notice it opening up different ports for the different requests.

徒留西风 2024-09-06 01:09:47

我认为这可能与 SSH-over-TCP 本身有关;另外,也许还有一些额外的低效率和/或实现中的错误。您仅在 Mac OS X / *BSD / Linux 上使用 OpenSSH,还是在 Windows 上使用 PuTTY?

您的情况实际上几乎正是开发 SCTP(作为 TCP 替代品)的原因,它具有来自单个连接内的多个流的概念。

希望有一天我们能够通过 SCTP 轻松使用 SSH。 SCTP 最好的部分是它仍然可以在 IPv4 上工作,即,据说主要是只有终端主机支持它,因此,与 IPv6 不同,您不必等待懒惰的 ISP(至少,理论上)。

I think it may have something to do with SSH-over-TCP itself; plus, perhaps, some extra inefficiencies and/or bugs in the implementations. Are you using only OpenSSH on Mac OS X / *BSD / Linux, or is this PuTTY on Windows?

Your situation is actually pretty much exactly why SCTP was developed (as a TCP replacement), which has a notion of multiple streams from within a single connection.

Hopefully, we'll have SSH over SCTP readily available one day. The best part about SCTP is that it'd still work over IPv4, i.e. it is supposedly mostly a matter of only the endhosts having support for it, so, unlike IPv6, you wouldn't have to wait for your lazy ISP (at leasts, theoretically).

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文