Page MenuHomeVyOS Platform

Ping incorrect ip host checks
Closed, ResolvedPublicBUG

Description

If you make a mistake (incorrect ip) while trying to ping.
For 1.3/1.4 you get such error:

vyos@r4-1.3:~$ ping 100.64..1
Traceback (most recent call last):
  File "/usr/lib/python3.7/encodings/idna.py", line 165, in encode
    raise UnicodeError("label empty or too long")
UnicodeError: label empty or too long

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/libexec/vyos/op_mode/ping.py", line 222, in <module>
    ip = socket.gethostbyname(host)
UnicodeError: encoding with 'idna' codec failed (UnicodeError: label empty or too long)
vyos@r4-1.3:~$

How it looks like in the crux:

vyos@r12-lts:~$ ping 100.64..1
ping: Unknown host: 100.64..1
vyos@r12-lts:~$

Details

Difficulty level
Easy (less than an hour)
Version
1.3.0-rc5/1.4-rolling-202107242017
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Unspecified (possibly destroys the router)
Issue type
Bug (incorrect behavior)

Event Timeline

Viacheslav renamed this task from Ping incorrect host checks to Ping incorrect ip host checks.Jul 28 2021, 10:40 AM
c-po claimed this task.
c-po moved this task from Need Triage to Finished on the VyOS 1.4 Sagitta board.
c-po moved this task from Need Triage to Finished on the VyOS 1.3 Equuleus board.
SrividyaA set Issue type to Bug (incorrect behavior).Wed, Sep 1, 10:39 AM