Date: Mon, 6 Jun 2011 15:46:30 GMT From: jason wright <jason@thought.net> To: freebsd-gnats-submit@FreeBSD.org Subject: bin/157663: kdump gets ptrace args wrong Message-ID: <201106061546.p56FkUvU004145@red.freebsd.org> Resent-Message-ID: <201106061550.p56Fo8nZ000650@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 157663 >Category: bin >Synopsis: kdump gets ptrace args wrong >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Jun 06 15:50:08 UTC 2011 >Closed-Date: >Last-Modified: >Originator: jason wright >Release: 8.2 >Organization: as if. >Environment: FreeBSD fbsd82-32.localdomain 8.2-RELEASE FreeBSD 8.2-RELEASE #0: Fri Feb 18 02:24:46 UTC 2011 root@almeida.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC i386 >Description: Regex for grabbing ptrace flags for kdump is not inclusive enough. Before fix: CALL ptrace(<invalid=5>, ...) After fix: CALL ptrace(PT_WRITE_D, ...) >How-To-Repeat: ktrace something that uses ptrace(PT_WRITE_D,...) then use kdump to view results. >Fix: apply patch below. It appears that no extraneous garbage is picked up by the modified regex (which just adds '_' is an additional character). Patch attached with submission follows: --- mksubr.old 2011-06-05 13:54:57.000000000 -0600 +++ mksubr 2011-06-05 13:57:21.000000000 -0600 @@ -343,7 +343,7 @@ auto_if_type "sockipprotoname" "IPPROTO_[[:alnum:]]+[[:space:]]+" "netinet/in.h" auto_switch_type "sockoptname" "SO_[A-Z]+[[:space:]]+0x[0-9]+" "sys/socket.h" auto_switch_type "socktypename" "SOCK_[A-Z]+[[:space:]]+[1-9]+[0-9]*" "sys/socket.h" -auto_switch_type "ptraceopname" "PT_[[:alnum:]]+[[:space:]]+[0-9]+" "sys/ptrace.h" +auto_switch_type "ptraceopname" "PT_[[:alnum:]_]+[[:space:]]+[0-9]+" "sys/ptrace.h" cat <<_EOF_ /* >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201106061546.p56FkUvU004145>