ebpf-challenge/GetRuntimeAddresses/symbolyze/doc.go

27 lines
779 B
Go

// Copyright note...
/*
Package symbolyze provides a mechanism to search for all occurences of a
certain symbol in certain mmap'ed ELF binaries of all running processes.
NewScanner(symbol string, glob string) will setup a Scanner, which will search
for the given symbol name in all mmap'ed ELF-files that match the given
glob-pattern. The glob-pattern is a shell file name pattern, see
filepath.Match.
The scanner should be populated with callback functions via calls to OnFound(),
before starting the scan by calling Run().
For example:
scanner := symbolyze.NewScanner("_PyRuntime", "*python3*")
scanner.OnFound(func(pid int, offset uint64) error {
fmt.Println("found symbol in", pid, "in offset", offset")
return nil
})
err := scanner.Run()
*/
package symbolyze