bugzilla-daemon at mindrot.org
2021-Apr-16 03:50 UTC
[Bug 3300] New: ssh reports the error when use ssh -o "ConnectTimeout=2147483649"
https://bugzilla.mindrot.org/show_bug.cgi?id=3300
Bug ID: 3300
Summary: ssh reports the error when use ssh -o
"ConnectTimeout=2147483649"
Product: Portable OpenSSH
Version: 8.2p1
Hardware: ARM64
OS: Linux
Status: NEW
Severity: major
Priority: P5
Component: ssh
Assignee: unassigned-bugs at mindrot.org
Reporter: kircherlike at outlook.com
After rectification: The ssh -o "ConnectTimeout=2147483649"
root at 3.82.3.249 reports the error " ssh: connect to host 3.82.3.249
port 22: Connection timed out".
If ConnectTimeout is greater than or equal to 2147484 in the command,
set the maximum value INT_MAX to the variable connection_timeout in the
code according to the patch.
However, when the value of ConnectTimeout > 2147484 is 2147483649, the
value of connection_timeout overflow in the code is 1000 ms instead of
INT_MAX.
Method of reproducing the problem:
1. Integrate
https://github.com/openssh/openssh-portable/commit/819b44e8b9af6ce18d3ec7505b9f461bf7991a1f.
2. ssh -o "ConnectTimeout=2147483647" root at 3.82.3.249
//connection_timeout=INT_MAX
ssh -o "ConnectTimeout=2147483648" root at 3.82.3.249 //:
connection_timeout = INT_MAX. The actual test variable
connection_timeout is 0, and the command ConnectTimeout is 0.
ssh -o "ConnectTimeout=2147483649" root at 3.82.3.249 //:
connection_timeout = INT_MAX, the actual test variable
connection_timeout = 1000, and the command ConnectTimeout = 1.
#define INT_MAX 2147483647
#define INT_MIN (-INT_MAX - 1)
--
You are receiving this mail because:
You are watching the assignee of the bug.
bugzilla-daemon at mindrot.org
2021-Apr-30 04:27 UTC
[Bug 3300] ssh reports the error when use ssh -o "ConnectTimeout=2147483649"
https://bugzilla.mindrot.org/show_bug.cgi?id=3300
Darren Tucker <dtucker at dtucker.net> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |WORKSFORME
CC| |dtucker at dtucker.net
--- Comment #1 from Darren Tucker <dtucker at dtucker.net> ---
You are reporting a bug against a locally modified 8.2p1? If so, you
probably also want
https://github.com/openbsd/src/commit/ca5450d695d8f9e6bd3120068d652f29e732ef3e
which changed convtime() to return an int. With this, current versions
will flag your test cases as an error:
$ ssh -o ConnectTimeout=2147483648 localhost
command-line line 0: invalid time value.
$ ssh -o ConnectTimeout=2147483649 localhost
command-line line 0: invalid time value.
Please reopen if you can reproduce the error with an unmodified OpenSSH
release.
--
You are receiving this mail because:
You are watching someone on the CC list of the bug.
You are watching the assignee of the bug.
bugzilla-daemon at mindrot.org
2022-Feb-25 02:58 UTC
[Bug 3300] ssh reports the error when use ssh -o "ConnectTimeout=2147483649"
https://bugzilla.mindrot.org/show_bug.cgi?id=3300
Damien Miller <djm at mindrot.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |CLOSED
--- Comment #2 from Damien Miller <djm at mindrot.org> ---
closing bugs resolved before openssh-8.9
--
You are receiving this mail because:
You are watching someone on the CC list of the bug.
You are watching the assignee of the bug.