Bug 239980 - Allowing maximum value to option "-l" in combination with option "-G", "-g", "-s" and "-f" makes system (host and guest) in freeze/hang condition by eating full CPU and RAM resources
Summary: Allowing maximum value to option "-l" in combination with option "-G", "-g", ...
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Many People
Assignee: freebsd-bugs mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-08-19 23:33 UTC by Neeraj
Modified: 2019-09-11 05:49 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Neeraj 2019-08-19 23:33:09 UTC
There is a issue after running the command given below on my FreeBSD virtual machine, it suddenly start eating my all CPU and RAM resources and I have observed the hangs/freezing behaviour on my guest machine which also impacts the host machine in 10-30 seconds.

After observing such behaviour I am sure that after leaving it for some minutes or hours. It could lead to DOS.

* ping -s 56 -G 4294967297 -g 4294967292 -l 429496729 -f localhost

or

* ping -s 56 -G maximum_allowed_value -g minimum_allowed_value -l 429496729 -f localhost


I think it should not allowed to preload (-l) this much value, especially with option "-f".

top(1) info given below (only in 13 seconds this much usage):

  PID USERNAME    THR PRI NICE   SIZE    RES STATE    C   TIME    WCPU COMMAND
 2456 root          1  93    0    11M  2604K CPU2     2   0:13  99.51% ping
  723 root          1  94    0    21M  9848K CPU3     3   1:21  91.98% sshd

I am connected via ssh and have observed that everytime when I run the above mentioned ping command then the usage of sshd daemon also increases suddenly (as given in the above top(1) info).