You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a simple Go Program Which calls syscall.RawSyscall(syscall.SYS_PTRACE, uintptr(syscall.PTRACE_TRACEME), 0, 0)
to check if a debugger is being used or not. But after a bit, I found a very strange behavior with it.
when calling using sudo.
whenever I am trying to run an external program by calling
exec.Command()
the whole code just hanging up without any error or output. I have prepared a simple Programm to recreate the problem
Well, I have compiled a c++ code to check if this behavior is also present in c++.
And yes, the same exact thing is happening with c++ as well.
It doesn't seem like a go specific issue.
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
I have a simple Go Program Which calls
syscall.RawSyscall(syscall.SYS_PTRACE, uintptr(syscall.PTRACE_TRACEME), 0, 0)
to check if a debugger is being used or not. But after a bit, I found a very strange behavior with it.
when calling using sudo.
whenever I am trying to run an external program by calling
exec.Command()
the whole code just hanging up without any error or output. I have prepared a simple Programm to recreate the problem
Download it:
example.zip
example.zip:
| run.sh
| strace.sh
| test.go
just run run.sh it will ask for sudo. Just enter the password and see the result.
What did you expect to see?
What did you see instead?
The text was updated successfully, but these errors were encountered: