You can also disable ptrace() completely.
(Grep for "ptrace_scope" in the ptrace(2) man page for details.)