Bug 53708 - netstat seg faults when reading services
netstat seg faults when reading services
Status: CLOSED WONTFIX
Product: Red Hat Linux
Classification: Retired
Component: net-tools (Show other bugs)
6.1
All Linux
medium Severity low
: ---
: ---
Assigned To: Phil Knirsch
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2001-09-16 02:49 EDT by Need Real Name
Modified: 2015-03-04 20:09 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2003-05-22 10:45:16 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Need Real Name 2001-09-16 02:49:31 EDT
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 5.5; Windows 98)

Description of problem:
Netstat, and probably other programs that read the /etc/services map to 
display service names in output can segfault if for some reason there is 
an entry with a long service name. This is not really a problem, though it 
could be if for some reason netstat (or some other program) was running 
suid. Netstat (atleast the one included with net-tools 1.53) is vulnerable 
to this, and defaults to not use numeric output. It's just an annoyance.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. open /etc/services
2. add/modify an entry for a port your machine is listening on with a (> 
256 chars?)long service name
3. run netstat
	

Actual Results:  segmentation fault

Expected Results:  trimmed output

Additional info:
Comment 1 Phil Knirsch 2002-02-24 05:52:57 EST
I just verified that this still happens on 7.2. If time permits i'll look into
it, but as netstat is not suid (as you already mentioned) and services normally
aren't that long this is nothing very serious, but a bug nonetheless :-)

Read ya, Phil
Comment 2 Phil Knirsch 2003-05-22 10:45:16 EDT
Actually now that i thought about it some more it's probably not worth fixing as
this hardly ever happens.

Thanks for reporting though.

Read ya, Phil

Note You need to log in before you can comment on or make changes to this bug.