Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Arch ¶
type Arch struct { Name string Bits int Cpu CpuBuilder PC int SP int OS map[string]*OS Regs regMap DefaultRegs []string // contains filtered or unexported fields }
func (*Arch) RegDumpFast ¶
FIXME: abstraction hack
func (*Arch) RegisterOS ¶
type ChangeMask ¶
type CpuBuilder ¶
type OS ¶
type StatusDiff ¶
type StatusDiff struct { U Usercorn // contains filtered or unexported fields }
func (*StatusDiff) Changes ¶
func (s *StatusDiff) Changes(onlyChanged bool) *Changes
type StrucStream ¶
type StrucStream struct { Stream io.ReadWriter Options *struc.Options Error error }
func NewStrucStream ¶
func NewStrucStream(f io.ReadWriter, opts *struc.Options) *StrucStream
func (*StrucStream) Pack ¶
func (s *StrucStream) Pack(vals ...interface{}) error
func (*StrucStream) Sizeof ¶
func (s *StrucStream) Sizeof(vals ...interface{}) (int, error)
func (*StrucStream) Unpack ¶
func (s *StrucStream) Unpack(vals ...interface{}) error
type SysGetArgs ¶
type Usercorn ¶
type Usercorn interface { // CPU GetCPU() *cpu.Cpu Backend() interface{} Mem() io.ReadWriteSeeker RegRead(reg int) (uint64, error) RegWrite(reg int, val uint64) error MemMap(addr, size uint64, prot int) error MemProt(addr, size uint64, prot int) error MemUnmap(addr, size uint64) error MemRegions() ([]*uc.MemRegion, error) // end CPU // Task Arch() *Arch ByteOrder() binary.ByteOrder RegDump() ([]RegVal, error) Bits() uint PackAddr(buf []byte, n uint64) ([]byte, error) UnpackAddr(buf []byte) uint64 PopBytes(p []byte) error PushBytes(p []byte) (uint64, error) Pop() (uint64, error) Push(n uint64) (uint64, error) OS() string MemReserve(addr, size uint64, force bool) (*cpu.Page, error) Mmap(addr, size uint64, prot int, fixed bool, desc string, file *cpu.FileDesc) (uint64, error) Malloc(size uint64, desc string) (uint64, error) Run() error Brk(addr uint64) (uint64, error) MapStack(base uint64, size uint64, guard bool) error StrucAt(addr uint64) *StrucStream Exe() string Loader() loader.Loader Base() uint64 Entry() uint64 BinEntry() uint64 SetEntry(entry uint64) SetExit(exit uint64) HookMapAdd(mapCb MapCb, unmapCb UnmapCb, protCb ProtCb) *MapHook HookMapDel(cb *MapHook) Syscall(num int, name string, getArgs SysGetArgs) (uint64, error) Exit(err error) Fs() *ramfs.Filesystem }
Click to show internal directories.
Click to hide internal directories.