Bugzilla will be upgraded to version 5.0 on a still to be determined date in the near future. The original upgrade date has been delayed.
Bug 21373 - libpcap buffer overflow
libpcap buffer overflow
Product: Red Hat Linux
Classification: Retired
Component: tcpdump (Show other bugs)
i386 Linux
low Severity medium
: ---
: ---
Assigned To: Harald Hoyer
: Security
Depends On:
  Show dependency treegraph
Reported: 2000-11-27 07:54 EST by Jarno Huuskonen
Modified: 2008-05-01 11:37 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2000-11-27 11:07:39 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Patch to fix libpcap strcpy(ifr.ifr_name, device) overflow (1.62 KB, patch)
2000-11-27 07:55 EST, Jarno Huuskonen
no flags Details | Diff

  None (edit)
Description Jarno Huuskonen 2000-11-27 07:54:18 EST
Libpcap has a buffer overflow. Libpcap uses strcpy to copy a 
device (interface-name) to ifreq.ifr_name (16-byte buffer).
The buffer can be overflowed if the program using libpcap passes
userdefined 'device' to pcap_open_live.
Test: tcpdump -i `perl -e "print 'A'x1000"`

This is not big problem unless someone has made a setuid libpcap program.

I'm attaching a patch that seems to fix this.

(Also it looks like might pcap-dlpi.c suffers from similar problem).
Comment 1 Jarno Huuskonen 2000-11-27 07:55:50 EST
Created attachment 5731 [details]
Patch to fix libpcap strcpy(ifr.ifr_name, device) overflow

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