Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Bug in SOCKS5 connections - port written to wire incorrect #447

Copy link
Copy link
@chrismasters

Description

@chrismasters
Issue body actions

I was trying to connect to a host on port 10022 and this was consistently not working.

When I looked in our SOCKS logs, I saw the connection was being attempted on port 10061

I believe the code in question is
https://github.com/sshnet/SSH.NET/blob/develop/src/Renci.SshNet/Session.cs#L2150

10022 / 255 = 0x27
10022 % 255 = 0x4D

0x274D == 10061 != 10022

If I change the port to 9983, then I can trick it into working

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions

    Morty Proxy This is a proxified and sanitized view of the page, visit original site.