This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug testsuite/11721] New: the usymbols.exp testcase shouldn't touch '__user' memory directly


systemtap.context/usymbols does this:

    probe syscall.rt_sigaction {                                                
      if (pid() == target() && execname() == "%s") {                            
          handler = $act->sa_handler;                                           
          printf("handler: %%s (%%s)\n", usymname(handler), umodname(handler)); 
      }                                                                         
    }                                                                           

The 'handler = $act->sa_handler' line is wrong, since '$act' is defined as
'const struct sigaction __user *act'.  The '__user' qualifier means that this is
user memory, not kernel memory and cannot be accessed directly.  Instead, we
must user _stp_copy_from_user() to access the data pointed to by $act.

-- 
           Summary: the usymbols.exp testcase shouldn't touch '__user'
                    memory directly
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: testsuite
        AssignedTo: systemtap at sources dot redhat dot com
        ReportedBy: dsmith at redhat dot com


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

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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]