Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

src: svr-tcpfwd: Fix noremotetcp behavior #254

Merged
merged 1 commit into from
Dec 6, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/svr-tcpfwd.c
Original file line number Diff line number Diff line change
Expand Up @@ -79,14 +79,14 @@ void recv_msg_global_request_remotetcp() {

TRACE(("enter recv_msg_global_request_remotetcp"))

reqname = buf_getstring(ses.payload, &namelen);
wantreply = buf_getbool(ses.payload);

if (svr_opts.noremotetcp || !svr_pubkey_allows_tcpfwd()) {
TRACE(("leave recv_msg_global_request_remotetcp: remote tcp forwarding disabled"))
goto out;
}

reqname = buf_getstring(ses.payload, &namelen);
wantreply = buf_getbool(ses.payload);

if (namelen > MAX_NAME_LEN) {
TRACE(("name len is wrong: %d", namelen))
goto out;
Expand Down