frida-core icon indicating copy to clipboard operation
frida-core copied to clipboard

Frida fails to attach to go/golang programs

Open brandon15811 opened this issue 8 years ago • 0 comments

IRC logs: 1:15 PM <Brandon15811__> oleavr: I can't seem to attach to a golang program: I used "frida-trace -i "open" hello-world" and got the error: "Failed to attach: unexpected error while attaching to process with pid 14075 (PTRACE_ATTACH wait returned 'Success')" Program used:

package main
import "fmt"
import "time"
func main() {
    time.Sleep(time.Second * 10);
    fmt.Println("hello world")
}

1:15 PM  Brandon15811__: that's a known issue (I think we have an issue filed in frida-core IIRC) 1:16 PM  Brandon15811__: because we rely on the system libc already being loaded 1:16 PM  Brandon15811__: it's fixable, though 1:17 PM <s1341__> oleavr: how is that fixable? 1:17 PM <s1341__> oleavr: we strongly rely on libc already being loaded 1:19 PM  s1341__: it's not a trivial thing to fix. it's a long-term goal to have a minimal private libc that covers our needs 1:20 PM <s1341__> oleavr: that's an interesting goal. 1:20 PM <s1341__> as in. hard. 1:20 PM  yep, definitely hard 1:21 PM  s1341__: but once achieved we will need to worry less about reentrancy when hooking low-level libc wrappers

brandon15811 avatar Sep 05 '16 18:09 brandon15811