diff --git a/GetRuntimeAddresses/symbolyze/doc.go b/GetRuntimeAddresses/symbolyze/doc.go new file mode 100644 index 0000000..5f2e7b3 --- /dev/null +++ b/GetRuntimeAddresses/symbolyze/doc.go @@ -0,0 +1,26 @@ +// Copyright note... +/* +Package symbolyze provides a mechanism to search for all occurences of a +certain symbol in a selection 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