angr.state_plugins.cgc¶
- class angr.state_plugins.cgc.SimStateCGC¶
Bases:
SimStatePluginThis state plugin keeps track of CGC state.
- EBADF = 1¶
- EFAULT = 2¶
- EINVAL = 3¶
- ENOMEM = 4¶
- ENOSYS = 5¶
- EPIPE = 6¶
- FD_SETSIZE = 1024¶
- max_allocation = 268435456¶
- __init__()¶
- peek_input()¶
- discard_input(num_bytes)¶
- peek_output()¶
- discard_output(num_bytes)¶
- addr_invalid(a)¶
- get_max_sinkhole(length)¶
Find a sinkhole which is large enough to support length bytes.
This uses first-fit. The first sinkhole (ordered in descending order by their address) which can hold length bytes is chosen. If there are more than length bytes in the sinkhole, a new sinkhole is created representing the remaining bytes while the old sinkhole is removed.
- add_sinkhole(address, length)¶
Add a sinkhole.
Allow the possibility for the program to reuse the memory represented by the address length pair.