Added introduction to the documentation
This commit is contained in:
parent
647e704fed
commit
edfb1b1bb7
26
GetRuntimeAddresses/symbolyze/doc.go
Normal file
26
GetRuntimeAddresses/symbolyze/doc.go
Normal file
@ -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
|
Loading…
Reference in New Issue
Block a user