ptrace.c 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712
  1. /*
  2. * linux/kernel/ptrace.c
  3. *
  4. * (C) Copyright 1999 Linus Torvalds
  5. *
  6. * Common interfaces for "ptrace()" which we do not want
  7. * to continually duplicate across every architecture.
  8. */
  9. #include <linux/capability.h>
  10. #include <linux/module.h>
  11. #include <linux/sched.h>
  12. #include <linux/errno.h>
  13. #include <linux/mm.h>
  14. #include <linux/highmem.h>
  15. #include <linux/pagemap.h>
  16. #include <linux/smp_lock.h>
  17. #include <linux/ptrace.h>
  18. #include <linux/security.h>
  19. #include <linux/signal.h>
  20. #include <linux/audit.h>
  21. #include <linux/pid_namespace.h>
  22. #include <linux/syscalls.h>
  23. #include <asm/pgtable.h>
  24. #include <asm/uaccess.h>
  25. /*
  26. * ptrace a task: make the debugger its new parent and
  27. * move it to the ptrace list.
  28. *
  29. * Must be called with the tasklist lock write-held.
  30. */
  31. void __ptrace_link(struct task_struct *child, struct task_struct *new_parent)
  32. {
  33. BUG_ON(!list_empty(&child->ptrace_entry));
  34. list_add(&child->ptrace_entry, &new_parent->ptraced);
  35. child->parent = new_parent;
  36. }
  37. /*
  38. * Turn a tracing stop into a normal stop now, since with no tracer there
  39. * would be no way to wake it up with SIGCONT or SIGKILL. If there was a
  40. * signal sent that would resume the child, but didn't because it was in
  41. * TASK_TRACED, resume it now.
  42. * Requires that irqs be disabled.
  43. */
  44. static void ptrace_untrace(struct task_struct *child)
  45. {
  46. spin_lock(&child->sighand->siglock);
  47. if (task_is_traced(child)) {
  48. if (child->signal->flags & SIGNAL_STOP_STOPPED) {
  49. __set_task_state(child, TASK_STOPPED);
  50. } else {
  51. signal_wake_up(child, 1);
  52. }
  53. }
  54. spin_unlock(&child->sighand->siglock);
  55. }
  56. /*
  57. * unptrace a task: move it back to its original parent and
  58. * remove it from the ptrace list.
  59. *
  60. * Must be called with the tasklist lock write-held.
  61. */
  62. void __ptrace_unlink(struct task_struct *child)
  63. {
  64. BUG_ON(!child->ptrace);
  65. child->ptrace = 0;
  66. child->parent = child->real_parent;
  67. list_del_init(&child->ptrace_entry);
  68. if (task_is_traced(child))
  69. ptrace_untrace(child);
  70. }
  71. /*
  72. * Check that we have indeed attached to the thing..
  73. */
  74. int ptrace_check_attach(struct task_struct *child, int kill)
  75. {
  76. int ret = -ESRCH;
  77. /*
  78. * We take the read lock around doing both checks to close a
  79. * possible race where someone else was tracing our child and
  80. * detached between these two checks. After this locked check,
  81. * we are sure that this is our traced child and that can only
  82. * be changed by us so it's not changing right after this.
  83. */
  84. read_lock(&tasklist_lock);
  85. if ((child->ptrace & PT_PTRACED) && child->parent == current) {
  86. ret = 0;
  87. /*
  88. * child->sighand can't be NULL, release_task()
  89. * does ptrace_unlink() before __exit_signal().
  90. */
  91. spin_lock_irq(&child->sighand->siglock);
  92. if (task_is_stopped(child))
  93. child->state = TASK_TRACED;
  94. else if (!task_is_traced(child) && !kill)
  95. ret = -ESRCH;
  96. spin_unlock_irq(&child->sighand->siglock);
  97. }
  98. read_unlock(&tasklist_lock);
  99. if (!ret && !kill)
  100. ret = wait_task_inactive(child, TASK_TRACED) ? 0 : -ESRCH;
  101. /* All systems go.. */
  102. return ret;
  103. }
  104. int __ptrace_may_access(struct task_struct *task, unsigned int mode)
  105. {
  106. /* May we inspect the given task?
  107. * This check is used both for attaching with ptrace
  108. * and for allowing access to sensitive information in /proc.
  109. *
  110. * ptrace_attach denies several cases that /proc allows
  111. * because setting up the necessary parent/child relationship
  112. * or halting the specified task is impossible.
  113. */
  114. int dumpable = 0;
  115. /* Don't let security modules deny introspection */
  116. if (task == current)
  117. return 0;
  118. if (((current->uid != task->euid) ||
  119. (current->uid != task->suid) ||
  120. (current->uid != task->uid) ||
  121. (current->gid != task->egid) ||
  122. (current->gid != task->sgid) ||
  123. (current->gid != task->gid)) && !capable(CAP_SYS_PTRACE))
  124. return -EPERM;
  125. smp_rmb();
  126. if (task->mm)
  127. dumpable = get_dumpable(task->mm);
  128. if (!dumpable && !capable(CAP_SYS_PTRACE))
  129. return -EPERM;
  130. return security_ptrace_may_access(task, mode);
  131. }
  132. bool ptrace_may_access(struct task_struct *task, unsigned int mode)
  133. {
  134. int err;
  135. task_lock(task);
  136. err = __ptrace_may_access(task, mode);
  137. task_unlock(task);
  138. return (!err ? true : false);
  139. }
  140. int ptrace_attach(struct task_struct *task)
  141. {
  142. int retval;
  143. unsigned long flags;
  144. audit_ptrace(task);
  145. retval = -EPERM;
  146. if (same_thread_group(task, current))
  147. goto out;
  148. repeat:
  149. /*
  150. * Nasty, nasty.
  151. *
  152. * We want to hold both the task-lock and the
  153. * tasklist_lock for writing at the same time.
  154. * But that's against the rules (tasklist_lock
  155. * is taken for reading by interrupts on other
  156. * cpu's that may have task_lock).
  157. */
  158. task_lock(task);
  159. if (!write_trylock_irqsave(&tasklist_lock, flags)) {
  160. task_unlock(task);
  161. do {
  162. cpu_relax();
  163. } while (!write_can_lock(&tasklist_lock));
  164. goto repeat;
  165. }
  166. if (!task->mm)
  167. goto bad;
  168. /* the same process cannot be attached many times */
  169. if (task->ptrace & PT_PTRACED)
  170. goto bad;
  171. retval = __ptrace_may_access(task, PTRACE_MODE_ATTACH);
  172. if (retval)
  173. goto bad;
  174. /* Go */
  175. task->ptrace |= PT_PTRACED;
  176. if (capable(CAP_SYS_PTRACE))
  177. task->ptrace |= PT_PTRACE_CAP;
  178. __ptrace_link(task, current);
  179. send_sig_info(SIGSTOP, SEND_SIG_FORCED, task);
  180. bad:
  181. write_unlock_irqrestore(&tasklist_lock, flags);
  182. task_unlock(task);
  183. out:
  184. return retval;
  185. }
  186. static inline void __ptrace_detach(struct task_struct *child, unsigned int data)
  187. {
  188. child->exit_code = data;
  189. /* .. re-parent .. */
  190. __ptrace_unlink(child);
  191. /* .. and wake it up. */
  192. if (child->exit_state != EXIT_ZOMBIE)
  193. wake_up_process(child);
  194. }
  195. int ptrace_detach(struct task_struct *child, unsigned int data)
  196. {
  197. if (!valid_signal(data))
  198. return -EIO;
  199. /* Architecture-specific hardware disable .. */
  200. ptrace_disable(child);
  201. clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE);
  202. write_lock_irq(&tasklist_lock);
  203. /* protect against de_thread()->release_task() */
  204. if (child->ptrace)
  205. __ptrace_detach(child, data);
  206. write_unlock_irq(&tasklist_lock);
  207. return 0;
  208. }
  209. int ptrace_readdata(struct task_struct *tsk, unsigned long src, char __user *dst, int len)
  210. {
  211. int copied = 0;
  212. while (len > 0) {
  213. char buf[128];
  214. int this_len, retval;
  215. this_len = (len > sizeof(buf)) ? sizeof(buf) : len;
  216. retval = access_process_vm(tsk, src, buf, this_len, 0);
  217. if (!retval) {
  218. if (copied)
  219. break;
  220. return -EIO;
  221. }
  222. if (copy_to_user(dst, buf, retval))
  223. return -EFAULT;
  224. copied += retval;
  225. src += retval;
  226. dst += retval;
  227. len -= retval;
  228. }
  229. return copied;
  230. }
  231. int ptrace_writedata(struct task_struct *tsk, char __user *src, unsigned long dst, int len)
  232. {
  233. int copied = 0;
  234. while (len > 0) {
  235. char buf[128];
  236. int this_len, retval;
  237. this_len = (len > sizeof(buf)) ? sizeof(buf) : len;
  238. if (copy_from_user(buf, src, this_len))
  239. return -EFAULT;
  240. retval = access_process_vm(tsk, dst, buf, this_len, 1);
  241. if (!retval) {
  242. if (copied)
  243. break;
  244. return -EIO;
  245. }
  246. copied += retval;
  247. src += retval;
  248. dst += retval;
  249. len -= retval;
  250. }
  251. return copied;
  252. }
  253. static int ptrace_setoptions(struct task_struct *child, long data)
  254. {
  255. child->ptrace &= ~PT_TRACE_MASK;
  256. if (data & PTRACE_O_TRACESYSGOOD)
  257. child->ptrace |= PT_TRACESYSGOOD;
  258. if (data & PTRACE_O_TRACEFORK)
  259. child->ptrace |= PT_TRACE_FORK;
  260. if (data & PTRACE_O_TRACEVFORK)
  261. child->ptrace |= PT_TRACE_VFORK;
  262. if (data & PTRACE_O_TRACECLONE)
  263. child->ptrace |= PT_TRACE_CLONE;
  264. if (data & PTRACE_O_TRACEEXEC)
  265. child->ptrace |= PT_TRACE_EXEC;
  266. if (data & PTRACE_O_TRACEVFORKDONE)
  267. child->ptrace |= PT_TRACE_VFORK_DONE;
  268. if (data & PTRACE_O_TRACEEXIT)
  269. child->ptrace |= PT_TRACE_EXIT;
  270. return (data & ~PTRACE_O_MASK) ? -EINVAL : 0;
  271. }
  272. static int ptrace_getsiginfo(struct task_struct *child, siginfo_t *info)
  273. {
  274. int error = -ESRCH;
  275. read_lock(&tasklist_lock);
  276. if (likely(child->sighand != NULL)) {
  277. error = -EINVAL;
  278. spin_lock_irq(&child->sighand->siglock);
  279. if (likely(child->last_siginfo != NULL)) {
  280. *info = *child->last_siginfo;
  281. error = 0;
  282. }
  283. spin_unlock_irq(&child->sighand->siglock);
  284. }
  285. read_unlock(&tasklist_lock);
  286. return error;
  287. }
  288. static int ptrace_setsiginfo(struct task_struct *child, const siginfo_t *info)
  289. {
  290. int error = -ESRCH;
  291. read_lock(&tasklist_lock);
  292. if (likely(child->sighand != NULL)) {
  293. error = -EINVAL;
  294. spin_lock_irq(&child->sighand->siglock);
  295. if (likely(child->last_siginfo != NULL)) {
  296. *child->last_siginfo = *info;
  297. error = 0;
  298. }
  299. spin_unlock_irq(&child->sighand->siglock);
  300. }
  301. read_unlock(&tasklist_lock);
  302. return error;
  303. }
  304. #ifdef PTRACE_SINGLESTEP
  305. #define is_singlestep(request) ((request) == PTRACE_SINGLESTEP)
  306. #else
  307. #define is_singlestep(request) 0
  308. #endif
  309. #ifdef PTRACE_SINGLEBLOCK
  310. #define is_singleblock(request) ((request) == PTRACE_SINGLEBLOCK)
  311. #else
  312. #define is_singleblock(request) 0
  313. #endif
  314. #ifdef PTRACE_SYSEMU
  315. #define is_sysemu_singlestep(request) ((request) == PTRACE_SYSEMU_SINGLESTEP)
  316. #else
  317. #define is_sysemu_singlestep(request) 0
  318. #endif
  319. static int ptrace_resume(struct task_struct *child, long request, long data)
  320. {
  321. if (!valid_signal(data))
  322. return -EIO;
  323. if (request == PTRACE_SYSCALL)
  324. set_tsk_thread_flag(child, TIF_SYSCALL_TRACE);
  325. else
  326. clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE);
  327. #ifdef TIF_SYSCALL_EMU
  328. if (request == PTRACE_SYSEMU || request == PTRACE_SYSEMU_SINGLESTEP)
  329. set_tsk_thread_flag(child, TIF_SYSCALL_EMU);
  330. else
  331. clear_tsk_thread_flag(child, TIF_SYSCALL_EMU);
  332. #endif
  333. if (is_singleblock(request)) {
  334. if (unlikely(!arch_has_block_step()))
  335. return -EIO;
  336. user_enable_block_step(child);
  337. } else if (is_singlestep(request) || is_sysemu_singlestep(request)) {
  338. if (unlikely(!arch_has_single_step()))
  339. return -EIO;
  340. user_enable_single_step(child);
  341. }
  342. else
  343. user_disable_single_step(child);
  344. child->exit_code = data;
  345. wake_up_process(child);
  346. return 0;
  347. }
  348. int ptrace_request(struct task_struct *child, long request,
  349. long addr, long data)
  350. {
  351. int ret = -EIO;
  352. siginfo_t siginfo;
  353. switch (request) {
  354. case PTRACE_PEEKTEXT:
  355. case PTRACE_PEEKDATA:
  356. return generic_ptrace_peekdata(child, addr, data);
  357. case PTRACE_POKETEXT:
  358. case PTRACE_POKEDATA:
  359. return generic_ptrace_pokedata(child, addr, data);
  360. #ifdef PTRACE_OLDSETOPTIONS
  361. case PTRACE_OLDSETOPTIONS:
  362. #endif
  363. case PTRACE_SETOPTIONS:
  364. ret = ptrace_setoptions(child, data);
  365. break;
  366. case PTRACE_GETEVENTMSG:
  367. ret = put_user(child->ptrace_message, (unsigned long __user *) data);
  368. break;
  369. case PTRACE_GETSIGINFO:
  370. ret = ptrace_getsiginfo(child, &siginfo);
  371. if (!ret)
  372. ret = copy_siginfo_to_user((siginfo_t __user *) data,
  373. &siginfo);
  374. break;
  375. case PTRACE_SETSIGINFO:
  376. if (copy_from_user(&siginfo, (siginfo_t __user *) data,
  377. sizeof siginfo))
  378. ret = -EFAULT;
  379. else
  380. ret = ptrace_setsiginfo(child, &siginfo);
  381. break;
  382. case PTRACE_DETACH: /* detach a process that was attached. */
  383. ret = ptrace_detach(child, data);
  384. break;
  385. #ifdef PTRACE_SINGLESTEP
  386. case PTRACE_SINGLESTEP:
  387. #endif
  388. #ifdef PTRACE_SINGLEBLOCK
  389. case PTRACE_SINGLEBLOCK:
  390. #endif
  391. #ifdef PTRACE_SYSEMU
  392. case PTRACE_SYSEMU:
  393. case PTRACE_SYSEMU_SINGLESTEP:
  394. #endif
  395. case PTRACE_SYSCALL:
  396. case PTRACE_CONT:
  397. return ptrace_resume(child, request, data);
  398. case PTRACE_KILL:
  399. if (child->exit_state) /* already dead */
  400. return 0;
  401. return ptrace_resume(child, request, SIGKILL);
  402. default:
  403. break;
  404. }
  405. return ret;
  406. }
  407. /**
  408. * ptrace_traceme -- helper for PTRACE_TRACEME
  409. *
  410. * Performs checks and sets PT_PTRACED.
  411. * Should be used by all ptrace implementations for PTRACE_TRACEME.
  412. */
  413. int ptrace_traceme(void)
  414. {
  415. int ret = -EPERM;
  416. /*
  417. * Are we already being traced?
  418. */
  419. repeat:
  420. task_lock(current);
  421. if (!(current->ptrace & PT_PTRACED)) {
  422. /*
  423. * See ptrace_attach() comments about the locking here.
  424. */
  425. unsigned long flags;
  426. if (!write_trylock_irqsave(&tasklist_lock, flags)) {
  427. task_unlock(current);
  428. do {
  429. cpu_relax();
  430. } while (!write_can_lock(&tasklist_lock));
  431. goto repeat;
  432. }
  433. ret = security_ptrace_traceme(current->parent);
  434. /*
  435. * Set the ptrace bit in the process ptrace flags.
  436. * Then link us on our parent's ptraced list.
  437. */
  438. if (!ret) {
  439. current->ptrace |= PT_PTRACED;
  440. __ptrace_link(current, current->real_parent);
  441. }
  442. write_unlock_irqrestore(&tasklist_lock, flags);
  443. }
  444. task_unlock(current);
  445. return ret;
  446. }
  447. /**
  448. * ptrace_get_task_struct -- grab a task struct reference for ptrace
  449. * @pid: process id to grab a task_struct reference of
  450. *
  451. * This function is a helper for ptrace implementations. It checks
  452. * permissions and then grabs a task struct for use of the actual
  453. * ptrace implementation.
  454. *
  455. * Returns the task_struct for @pid or an ERR_PTR() on failure.
  456. */
  457. struct task_struct *ptrace_get_task_struct(pid_t pid)
  458. {
  459. struct task_struct *child;
  460. read_lock(&tasklist_lock);
  461. child = find_task_by_vpid(pid);
  462. if (child)
  463. get_task_struct(child);
  464. read_unlock(&tasklist_lock);
  465. if (!child)
  466. return ERR_PTR(-ESRCH);
  467. return child;
  468. }
  469. #ifndef arch_ptrace_attach
  470. #define arch_ptrace_attach(child) do { } while (0)
  471. #endif
  472. asmlinkage long sys_ptrace(long request, long pid, long addr, long data)
  473. {
  474. struct task_struct *child;
  475. long ret;
  476. /*
  477. * This lock_kernel fixes a subtle race with suid exec
  478. */
  479. lock_kernel();
  480. if (request == PTRACE_TRACEME) {
  481. ret = ptrace_traceme();
  482. if (!ret)
  483. arch_ptrace_attach(current);
  484. goto out;
  485. }
  486. child = ptrace_get_task_struct(pid);
  487. if (IS_ERR(child)) {
  488. ret = PTR_ERR(child);
  489. goto out;
  490. }
  491. if (request == PTRACE_ATTACH) {
  492. ret = ptrace_attach(child);
  493. /*
  494. * Some architectures need to do book-keeping after
  495. * a ptrace attach.
  496. */
  497. if (!ret)
  498. arch_ptrace_attach(child);
  499. goto out_put_task_struct;
  500. }
  501. ret = ptrace_check_attach(child, request == PTRACE_KILL);
  502. if (ret < 0)
  503. goto out_put_task_struct;
  504. ret = arch_ptrace(child, request, addr, data);
  505. if (ret < 0)
  506. goto out_put_task_struct;
  507. out_put_task_struct:
  508. put_task_struct(child);
  509. out:
  510. unlock_kernel();
  511. return ret;
  512. }
  513. int generic_ptrace_peekdata(struct task_struct *tsk, long addr, long data)
  514. {
  515. unsigned long tmp;
  516. int copied;
  517. copied = access_process_vm(tsk, addr, &tmp, sizeof(tmp), 0);
  518. if (copied != sizeof(tmp))
  519. return -EIO;
  520. return put_user(tmp, (unsigned long __user *)data);
  521. }
  522. int generic_ptrace_pokedata(struct task_struct *tsk, long addr, long data)
  523. {
  524. int copied;
  525. copied = access_process_vm(tsk, addr, &data, sizeof(data), 1);
  526. return (copied == sizeof(data)) ? 0 : -EIO;
  527. }
  528. #if defined CONFIG_COMPAT && defined __ARCH_WANT_COMPAT_SYS_PTRACE
  529. #include <linux/compat.h>
  530. int compat_ptrace_request(struct task_struct *child, compat_long_t request,
  531. compat_ulong_t addr, compat_ulong_t data)
  532. {
  533. compat_ulong_t __user *datap = compat_ptr(data);
  534. compat_ulong_t word;
  535. siginfo_t siginfo;
  536. int ret;
  537. switch (request) {
  538. case PTRACE_PEEKTEXT:
  539. case PTRACE_PEEKDATA:
  540. ret = access_process_vm(child, addr, &word, sizeof(word), 0);
  541. if (ret != sizeof(word))
  542. ret = -EIO;
  543. else
  544. ret = put_user(word, datap);
  545. break;
  546. case PTRACE_POKETEXT:
  547. case PTRACE_POKEDATA:
  548. ret = access_process_vm(child, addr, &data, sizeof(data), 1);
  549. ret = (ret != sizeof(data) ? -EIO : 0);
  550. break;
  551. case PTRACE_GETEVENTMSG:
  552. ret = put_user((compat_ulong_t) child->ptrace_message, datap);
  553. break;
  554. case PTRACE_GETSIGINFO:
  555. ret = ptrace_getsiginfo(child, &siginfo);
  556. if (!ret)
  557. ret = copy_siginfo_to_user32(
  558. (struct compat_siginfo __user *) datap,
  559. &siginfo);
  560. break;
  561. case PTRACE_SETSIGINFO:
  562. memset(&siginfo, 0, sizeof siginfo);
  563. if (copy_siginfo_from_user32(
  564. &siginfo, (struct compat_siginfo __user *) datap))
  565. ret = -EFAULT;
  566. else
  567. ret = ptrace_setsiginfo(child, &siginfo);
  568. break;
  569. default:
  570. ret = ptrace_request(child, request, addr, data);
  571. }
  572. return ret;
  573. }
  574. asmlinkage long compat_sys_ptrace(compat_long_t request, compat_long_t pid,
  575. compat_long_t addr, compat_long_t data)
  576. {
  577. struct task_struct *child;
  578. long ret;
  579. /*
  580. * This lock_kernel fixes a subtle race with suid exec
  581. */
  582. lock_kernel();
  583. if (request == PTRACE_TRACEME) {
  584. ret = ptrace_traceme();
  585. goto out;
  586. }
  587. child = ptrace_get_task_struct(pid);
  588. if (IS_ERR(child)) {
  589. ret = PTR_ERR(child);
  590. goto out;
  591. }
  592. if (request == PTRACE_ATTACH) {
  593. ret = ptrace_attach(child);
  594. /*
  595. * Some architectures need to do book-keeping after
  596. * a ptrace attach.
  597. */
  598. if (!ret)
  599. arch_ptrace_attach(child);
  600. goto out_put_task_struct;
  601. }
  602. ret = ptrace_check_attach(child, request == PTRACE_KILL);
  603. if (!ret)
  604. ret = compat_arch_ptrace(child, request, addr, data);
  605. out_put_task_struct:
  606. put_task_struct(child);
  607. out:
  608. unlock_kernel();
  609. return ret;
  610. }
  611. #endif /* CONFIG_COMPAT && __ARCH_WANT_COMPAT_SYS_PTRACE */