Project

General

Profile

Bug #2724

snoop contains few problems with accessing uninitialized data

Added by Milan Jurik over 8 years ago. Updated over 8 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
cmd - userland programs
Start date:
2012-05-12
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:

Description

Code analysis from Studio 12.3 shows several problems in snoop code:

cap_open_read() does not initialized device_mac_type

compare_value_zone() was mismerged during previous putback

ipaddr_match() and pf_ipaddr_match() could continue even if hp is not assigned

print_ripso() checks if ripso_class is detected but the test is incorrect.

print_rpc_gss_init_arg() and print_rpc_gss_init_res() should print from pos = 0


Files

snoop-analysis.patch (8.59 KB) snoop-analysis.patch suggested fix Milan Jurik, 2012-06-05 04:42 PM
#1

Updated by Milan Jurik over 8 years ago

#2

Updated by Gordon Ross over 8 years ago

  • Status changed from Pending RTI to Resolved
changeset:   13740:836bfdf31fc4
tag:         tip
user:        Milan Jurik <milan.jurik@xylab.cz>
date:        Tue Jun 05 18:33:58 2012 +0200

description:
    2724 snoop contains few problems with accessing uninitialized data
    Reviewed by: Darren Reed <darrenr@fastmail.net>
    Reviewed by: Garrett D'Amore <garrett@damore.org>
    Approved by: Gordon Ross <gwr@nexenta.com>

modified:
   usr/src/cmd/cmd-inet/usr.sbin/snoop/snoop_capture.c
   usr/src/cmd/cmd-inet/usr.sbin/snoop/snoop_filter.c
   usr/src/cmd/cmd-inet/usr.sbin/snoop/snoop_ip.c
   usr/src/cmd/cmd-inet/usr.sbin/snoop/snoop_pf.c
   usr/src/cmd/cmd-inet/usr.sbin/snoop/snoop_rpcsec.c

Also available in: Atom PDF