public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [Bug translator/2639] New: Probes on "__kprobes" functions should not be allowed
@ 2006-05-04  0:16 joshua dot i dot stone at intel dot com
  2006-05-04  0:23 ` [Bug translator/2639] " joshua dot i dot stone at intel dot com
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: joshua dot i dot stone at intel dot com @ 2006-05-04  0:16 UTC (permalink / raw)
  To: systemtap

Similar to bug #2506, probes should be disallowed at compile time for addresses
within __kprobes functions.

On the surface it seems like we could just examine the section-name of the probe
address and make sure it's not .kprobes.text.  It's not that straightforward
though, because the kernel folds .kprobes.text into the main .text section in
"arch/*/kernel/vmlinux.lds.S".

-- 
           Summary: Probes on "__kprobes" functions should not be allowed
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: translator
        AssignedTo: systemtap at sources dot redhat dot com
        ReportedBy: joshua dot i dot stone at intel dot com


http://sourceware.org/bugzilla/show_bug.cgi?id=2639

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug translator/2639] Probes on "__kprobes" functions should not be allowed
  2006-05-04  0:16 [Bug translator/2639] New: Probes on "__kprobes" functions should not be allowed joshua dot i dot stone at intel dot com
@ 2006-05-04  0:23 ` joshua dot i dot stone at intel dot com
  2006-05-27  0:33 ` joshua dot i dot stone at intel dot com
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: joshua dot i dot stone at intel dot com @ 2006-05-04  0:23 UTC (permalink / raw)
  To: systemtap


------- Additional Comments From joshua dot i dot stone at intel dot com  2006-05-04 00:23 -------
Just to clarify - the kprobes runtime correctly blocks probes within the
.kprobes.text section, so this isn't a stability issue.  The user will see this
get all the way to pass-5, and then it will fail to register the probe.  It
would be nicer if we could catch this earlier, probably in the blacklist check
like we do with __init and __exit.

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=2639

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug translator/2639] Probes on "__kprobes" functions should not be allowed
  2006-05-04  0:16 [Bug translator/2639] New: Probes on "__kprobes" functions should not be allowed joshua dot i dot stone at intel dot com
  2006-05-04  0:23 ` [Bug translator/2639] " joshua dot i dot stone at intel dot com
@ 2006-05-27  0:33 ` joshua dot i dot stone at intel dot com
  2006-10-09 17:08 ` dsmith at redhat dot com
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: joshua dot i dot stone at intel dot com @ 2006-05-27  0:33 UTC (permalink / raw)
  To: systemtap


------- Additional Comments From joshua dot i dot stone at intel dot com  2006-05-27 00:33 -------
For now, I've manually added all __kprobes functions to the translator
blacklist.  This won't prevent statement() probes from being requested within
these functions, but it's better than nothing.  The kprobes infrastructure will
still reject such probes at runtime if any slip through.

(tapsets.cxx r1.131)

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=2639

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug translator/2639] Probes on "__kprobes" functions should not be allowed
  2006-05-04  0:16 [Bug translator/2639] New: Probes on "__kprobes" functions should not be allowed joshua dot i dot stone at intel dot com
  2006-05-04  0:23 ` [Bug translator/2639] " joshua dot i dot stone at intel dot com
  2006-05-27  0:33 ` joshua dot i dot stone at intel dot com
@ 2006-10-09 17:08 ` dsmith at redhat dot com
  2006-10-09 22:56 ` dsmith at redhat dot com
  2006-10-11 14:58 ` dsmith at redhat dot com
  4 siblings, 0 replies; 6+ messages in thread
From: dsmith at redhat dot com @ 2006-10-09 17:08 UTC (permalink / raw)
  To: systemtap


------- Additional Comments From dsmith at redhat dot com  2006-10-09 17:08 -------
Created an attachment (id=1361)
 --> (http://sourceware.org/bugzilla/attachment.cgi?id=1361&action=view)
Proposed patch

This proposed patches mimics the kernel function "in_kprobes_functions" by
looking up the value of the symbols "__kprobes_text_start" and
"__kprobes_text_end" and makes sure a probe point address isn't between those
two values.

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=2639

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug translator/2639] Probes on "__kprobes" functions should not be allowed
  2006-05-04  0:16 [Bug translator/2639] New: Probes on "__kprobes" functions should not be allowed joshua dot i dot stone at intel dot com
                   ` (2 preceding siblings ...)
  2006-10-09 17:08 ` dsmith at redhat dot com
@ 2006-10-09 22:56 ` dsmith at redhat dot com
  2006-10-11 14:58 ` dsmith at redhat dot com
  4 siblings, 0 replies; 6+ messages in thread
From: dsmith at redhat dot com @ 2006-10-09 22:56 UTC (permalink / raw)
  To: systemtap


------- Additional Comments From dsmith at redhat dot com  2006-10-09 22:56 -------
Created an attachment (id=1364)
 --> (http://sourceware.org/bugzilla/attachment.cgi?id=1364&action=view)
Improved patch

This improved patch moves the static '__kprobes_text_start' and
'__kprobes_text_end' variables into the session object.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
Attachment #1361 is|0                           |1
           obsolete|                            |


http://sourceware.org/bugzilla/show_bug.cgi?id=2639

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug translator/2639] Probes on "__kprobes" functions should not be allowed
  2006-05-04  0:16 [Bug translator/2639] New: Probes on "__kprobes" functions should not be allowed joshua dot i dot stone at intel dot com
                   ` (3 preceding siblings ...)
  2006-10-09 22:56 ` dsmith at redhat dot com
@ 2006-10-11 14:58 ` dsmith at redhat dot com
  4 siblings, 0 replies; 6+ messages in thread
From: dsmith at redhat dot com @ 2006-10-11 14:58 UTC (permalink / raw)
  To: systemtap


------- Additional Comments From dsmith at redhat dot com  2006-10-11 14:58 -------
Patch should allow us to reject all addresses within functions marked as
'__kprobes'.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED


http://sourceware.org/bugzilla/show_bug.cgi?id=2639

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2006-10-11 14:58 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-05-04  0:16 [Bug translator/2639] New: Probes on "__kprobes" functions should not be allowed joshua dot i dot stone at intel dot com
2006-05-04  0:23 ` [Bug translator/2639] " joshua dot i dot stone at intel dot com
2006-05-27  0:33 ` joshua dot i dot stone at intel dot com
2006-10-09 17:08 ` dsmith at redhat dot com
2006-10-09 22:56 ` dsmith at redhat dot com
2006-10-11 14:58 ` dsmith at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).