32 if (architecture ==
nullptr) {
36 this->architecture = architecture;
37 this->callbacks = callbacks;
49 astCtxt(other.astCtxt),
53 this->architecture = other.architecture;
54 this->callbacks = other.callbacks;
77 this->architecture = other.architecture;
78 this->astCtxt = other.astCtxt;
79 this->callbacks = other.callbacks;
81 this->modes = other.modes;
156 if (this->
alignedMemoryReference.find(std::make_pair(address, size)) != this->alignedMemoryReference.end()) {
165 this->removeAlignedMemory(address, size);
225 if (
auto node = it->second.lock()) {
243 if (
auto symVar = sv.second.lock()) {
244 if (symVar->getName() == name || symVar->getAlias() == name) {
256 std::map<triton::usize, SharedSymbolicVariable> ret;
257 std::vector<triton::usize> toRemove;
260 if (
auto sp = kv.second.lock()) {
263 toRemove.push_back(kv.first);
268 this->symbolicVariables.erase(
id);
326 return node->evaluate();
332 std::vector<triton::uint8> area;
374 auto n = node->getChildren()[1];
378 node->setChild(1, this->astCtxt->reference(e));
391 if (expr ==
nullptr) {
406 const auto& mem = expr->getOriginMemory();
412 const auto& reg = expr->getOriginRegister();
429 if (
auto sp = it->second.lock()) {
441 std::unordered_map<triton::usize, SharedSymbolicExpression> ret;
442 std::vector<triton::usize> toRemove;
445 if (
auto sp = kv.second.lock()) {
448 toRemove.push_back(kv.first);
452 for (
auto id : toRemove)
453 this->symbolicExpressions.erase(
id);
461 std::unordered_map<triton::usize, SharedSymbolicExpression> exprs;
463 if (expr ==
nullptr) {
467 exprs[expr->getId()] = expr;
470 for (
auto&& n : worklist) {
473 auto eid = expr->getId();
484 std::vector<SharedSymbolicExpression> taintedExprs;
485 std::vector<triton::usize> invalidSymExpr;
487 for (
auto it = this->
symbolicExpressions.begin(); it != this->symbolicExpressions.end(); it++) {
488 if (
auto sp = it->second.lock()) {
490 taintedExprs.push_back(sp);
493 invalidSymExpr.push_back(it->first);
497 for (
auto id : invalidSymExpr) {
507 std::unordered_map<triton::arch::register_e, SharedSymbolicExpression> ret;
537 if (expression->getAst()) {
541 expression->setAst(tmp);
573 se->setOriginMemory(mem);
574 this->addAlignedMemory(memAddr, symVarSize, se);
590 this->addMemoryReference(memAddr+index, se);
632 if (symVar ==
nullptr) {
671 return this->astCtxt->bvashr(node, this->astCtxt->bv(imm, node->getBitvectorSize()));
674 return this->astCtxt->bvshl(node, this->astCtxt->bv(imm, node->getBitvectorSize()));
677 return this->astCtxt->bvlshr(node, this->astCtxt->bv(imm, node->getBitvectorSize()));
680 return this->astCtxt->bvror(node, this->astCtxt->bv(imm, node->getBitvectorSize()));
683 return this->astCtxt->extract(
684 node->getBitvectorSize(),
686 this->astCtxt->bvror(
687 this->astCtxt->concat(
689 this->getRegisterAst(this->architecture->getRegister(triton::arch::ID_REG_ARM32_C))
696 return this->astCtxt->bvashr(
699 this->architecture->getRegister(reg).getBitSize() - 8,
700 this->astCtxt->extract(
703 this->getRegisterAst(this->architecture->getRegister(reg))
709 return this->astCtxt->bvshl(
712 this->architecture->getRegister(reg).getBitSize() - 8,
713 this->astCtxt->extract(
716 this->getRegisterAst(this->architecture->getRegister(reg))
722 return this->astCtxt->bvlshr(
725 this->architecture->getRegister(reg).getBitSize() - 8,
726 this->astCtxt->extract(
729 this->getRegisterAst(this->architecture->getRegister(reg))
735 return this->astCtxt->bvror(
738 this->architecture->getRegister(reg).getBitSize() - 8,
739 this->astCtxt->extract(
742 this->getRegisterAst(this->architecture->getRegister(reg))
764 return this->astCtxt->zx(size, this->astCtxt->bvshl(this->astCtxt->extract(7, 0, node), this->astCtxt->bv(extend.
getShiftImmediate(), 8)));
767 return this->astCtxt->zx(size, this->astCtxt->bvshl(this->astCtxt->extract(15, 0, node), this->astCtxt->bv(extend.
getShiftImmediate(), 16)));
770 return this->astCtxt->zx(size, this->astCtxt->bvshl(this->astCtxt->extract(31, 0, node), this->astCtxt->bv(extend.
getShiftImmediate(), 32)));
773 return this->astCtxt->zx(size, this->astCtxt->bvshl(this->astCtxt->extract(63, 0, node), this->astCtxt->bv(extend.
getShiftImmediate(), 64)));
776 return this->astCtxt->sx(size, this->astCtxt->bvshl(this->astCtxt->extract(7, 0, node), this->astCtxt->bv(extend.
getShiftImmediate(), 8)));
779 return this->astCtxt->sx(size, this->astCtxt->bvshl(this->astCtxt->extract(15, 0, node), this->astCtxt->bv(extend.
getShiftImmediate(), 16)));
782 return this->astCtxt->sx(size, this->astCtxt->bvshl(this->astCtxt->extract(31, 0, node), this->astCtxt->bv(extend.
getShiftImmediate(), 32)));
785 return this->astCtxt->sx(size, this->astCtxt->bvshl(this->astCtxt->extract(63, 0, node), this->astCtxt->bv(extend.
getShiftImmediate(), 64)));
816 std::vector<triton::ast::SharedAbstractNode> opVec;
831 return this->getAlignedMemory(address, size)->getAst();
837 if (symMem)
return this->astCtxt->reference(symMem);
838 else return this->astCtxt->bv(concreteValue[size - 1],
bitsize::byte);
845 if (symMem) opVec.push_back(this->astCtxt->reference(symMem));
846 else opVec.push_back(this->astCtxt->bv(concreteValue[size - 1],
bitsize::byte));
849 return this->astCtxt->concat(opVec);
861 this->setImplicitReadRegisterFromEffectiveAddress(inst, mem);
877 if (symReg) node = this->astCtxt->extract(high, low, this->astCtxt->reference(symReg));
878 else node = this->astCtxt->bv(value, bvSize);
915 std::vector<triton::ast::SharedAbstractNode> ret;
925 this->addAlignedMemory(address, writeSize, aligned);
937 tmp = this->astCtxt->extract(high, low, node);
945 this->addMemoryReference((address + writeSize) - 1, se);
951 this->setImplicitReadRegisterFromEffectiveAddress(inst, mem);
957 if (ret.size() == 1) {
960 return this->addSymbolicExpressions(inst,
id);
964 tmp = this->astCtxt->concat(ret);
972 return this->addSymbolicExpressions(inst,
id);
981 if (this->architecture->
isFlag(reg)) {
995 return this->astCtxt->concat(keep, node);
1003 return this->astCtxt->concat(keep, this->astCtxt->concat(node, this->astCtxt->extract((
bitsize::byte - 1), 0, origReg)));
1010 return this->astCtxt->concat(this->astCtxt->extract((parentReg.
getBitSize() - 1),
bitsize::word, origReg), node);
1020 if (zxForAssign ==
false) {
1023 return this->astCtxt->concat(this->astCtxt->extract((parentReg.
getBitSize() - 1), reg.
getHigh() + 1, origReg), node);
1031 return this->astCtxt->zx(parentReg.
getBitSize() - node->getBitvectorSize(), node);
1050 return this->addSymbolicExpressions(inst,
id);
1058 return this->addSymbolicExpressions(inst,
id);
1074 if (reg.
getId() !=
id) {
1079 if (node->getBitvectorSize() != reg.
getBitSize()) {
1080 throw triton::exceptions::SymbolicEngine(
"SymbolicEngine::assignSymbolicExpressionToRegister(): The size of the symbolic expression is not equal to the target register.");
1084 se->setOriginRegister(reg);
1102 if (node->getBitvectorSize() != mem.
getBitSize()) {
1103 throw triton::exceptions::SymbolicEngine(
"SymbolicEngine::assignSymbolicExpressionToMemory(): The size of the symbolic expression is not equal to the memory access.");
1108 this->addAlignedMemory(address, writeSize, se);
1125 this->addMemoryReference((address + writeSize) - 1, byteRef);
1140 return (it->second.use_count() > 0);
1160 if (expr && expr->isSymbolized()) {
1172 return expr->isSymbolized();
1197 this->astCtxt->bv(0, bitSize));
1199 auto indexMulScaleAst = this->astCtxt->bvmul(
1200 (this->architecture->
isRegisterValid(index) ? this->getRegisterAst(index) : this->astCtxt->bv(0, bitSize)),
1201 this->astCtxt->bv(scaleValue, bitSize)
1204 auto dispAst = this->astCtxt->bv(dispValue, bitSize);
1205 auto leaAst = this->astCtxt->bvadd(
1206 index.
isSubtracted() ? this->astCtxt->bvsub(pcPlusBaseAst, indexMulScaleAst) : this->astCtxt->bvadd(pcPlusBaseAst, indexMulScaleAst),
1212 leaAst = this->astCtxt->bvadd(
1214 this->astCtxt->sx((seg.
getBitSize() - bitSize), leaAst)
1229 return this->astCtxt->getVariableValue(symVar->getName());
1237 max = max >> (512 - symVar->getSize());
1243 this->astCtxt->updateVariable(symVar->getName(), value);
The abstract architecture class.
TRITON_EXPORT const triton::arch::Register & getRegister(triton::arch::register_e id) const
Returns register from id.
TRITON_EXPORT triton::uint32 numberOfRegisters(void) const
Returns the number of registers according to the CPU architecture.
TRITON_EXPORT triton::uint32 gprBitSize(void) const
Returns the bit in bit of the General Purpose Registers.
TRITON_EXPORT void setConcreteRegisterValue(const triton::arch::Register ®, const triton::uint512 &value, bool execCallbacks=true)
[architecture api] - Sets the concrete value of a register.
TRITON_EXPORT void setConcreteMemoryValue(triton::uint64 addr, triton::uint8 value, bool execCallbacks=true)
[architecture api] - Sets the concrete value of a memory cell.
TRITON_EXPORT bool isFlag(triton::arch::register_e regId) const
Returns true if the register ID is a flag.
TRITON_EXPORT triton::uint8 getConcreteMemoryValue(triton::uint64 addr, bool execCallbacks=true) const
Returns the concrete value of a memory cell.
TRITON_EXPORT triton::uint512 getConcreteRegisterValue(const triton::arch::Register ®, bool execCallbacks=true) const
Returns the concrete value of a register.
TRITON_EXPORT bool isRegisterValid(triton::arch::register_e regId) const
Returns true if the register ID is a register or a flag.
TRITON_EXPORT const triton::arch::Register & getParentRegister(triton::arch::register_e id) const
Returns parent register from id.
TRITON_EXPORT triton::uint32 getHigh(void) const
Returns the highest bit.
TRITON_EXPORT triton::uint32 getLow(void) const
Returns the lower bit.
This class is used to represent an instruction.
TRITON_EXPORT void setLoadAccess(const triton::arch::MemoryAccess &mem, const triton::ast::SharedAbstractNode &node)
Sets a load access.
TRITON_EXPORT void setWrittenRegister(const triton::arch::Register ®, const triton::ast::SharedAbstractNode &node)
Sets a written register.
TRITON_EXPORT void setStoreAccess(const triton::arch::MemoryAccess &mem, const triton::ast::SharedAbstractNode &node)
Sets a store access.
TRITON_EXPORT void addSymbolicExpression(const triton::engines::symbolic::SharedSymbolicExpression &expr)
Adds a symbolic expression.
TRITON_EXPORT void setReadImmediate(const triton::arch::Immediate &imm, const triton::ast::SharedAbstractNode &node)
Sets a read immediate.
std::vector< triton::engines::symbolic::SharedSymbolicExpression > symbolicExpressions
The semantics set of the instruction.
TRITON_EXPORT void setReadRegister(const triton::arch::Register ®, const triton::ast::SharedAbstractNode &node)
Sets a read register.
This class is used to represent a memory access.
TRITON_EXPORT triton::uint64 getPcRelative(void) const
LEA - Gets pc relative.
TRITON_EXPORT const triton::arch::Register & getConstBaseRegister(void) const
LEA - Returns the base register operand.
TRITON_EXPORT void setLeaAst(const triton::ast::SharedAbstractNode &ast)
Sets the AST of the memory access (LEA).
TRITON_EXPORT const triton::arch::Register & getConstSegmentRegister(void) const
LEA - Returns the segment register operand.
TRITON_EXPORT triton::uint32 getBitSize(void) const
Returns the size (in bits) of the memory vector.
TRITON_EXPORT const triton::arch::Immediate & getConstDisplacement(void) const
LEA - Returns the displacement operand.
TRITON_EXPORT triton::uint64 getAddress(void) const
Returns the address of the memory.
TRITON_EXPORT triton::uint32 getSize(void) const
Returns the size (in bytes) of the memory vector.
TRITON_EXPORT void setAddress(triton::uint64 addr)
Sets the address of the memory access.
TRITON_EXPORT const triton::arch::Register & getConstIndexRegister(void) const
LEA - Returns the index register operand.
TRITON_EXPORT const triton::arch::Immediate & getConstScale(void) const
LEA - Returns the scale operand.
This class is used as operand wrapper.
TRITON_EXPORT triton::arch::operand_e getType(void) const
Returns the abstract type of the operand.
TRITON_EXPORT const triton::arch::MemoryAccess & getConstMemory(void) const
Returns the memory operand as const.
TRITON_EXPORT const triton::arch::Register & getConstRegister(void) const
Returns the register operand.
TRITON_EXPORT const triton::arch::Immediate & getConstImmediate(void) const
Returns the immediate operand.
This class is used when an instruction has a register operand.
TRITON_EXPORT triton::uint32 getBitSize(void) const
Returns the size (in bits) of the register.
TRITON_EXPORT triton::arch::register_e getParent(void) const
Returns the parent id of the register.
TRITON_EXPORT triton::arch::register_e getId(void) const
Returns the id of the register.
TRITON_EXPORT bool isMutable(void) const
Returns true if this register is mutable. Mainly used in AArch64 to define that some registers like X...
TRITON_EXPORT triton::uint32 getSize(void) const
Returns the size (in bytes) of the register.
This class is used to represent specific properties of an Arm operand.
TRITON_EXPORT triton::arch::arm::shift_e getShiftType(void) const
Returns the type of the shift.
TRITON_EXPORT triton::arch::register_e getShiftRegister(void) const
Returns the value of the shift register.
TRITON_EXPORT triton::arch::arm::extend_e getExtendType(void) const
Returns the type of the extend.
TRITON_EXPORT triton::uint32 getExtendSize(void) const
Returns the size (in bits) of the extend.
TRITON_EXPORT triton::uint32 getShiftImmediate(void) const
Returns the value of the shift immediate.
TRITON_EXPORT bool isSubtracted(void) const
Returns true if the operand has to be subtracted when computing a memory access.
TRITON_EXPORT PathManager & operator=(const PathManager &other)
Copies a PathManager.
The symbolic engine class.
std::unordered_map< triton::usize, WeakSymbolicExpression > symbolicExpressions
The map of symbolic expressions.
TRITON_EXPORT const SharedSymbolicExpression & createSymbolicMemoryExpression(triton::arch::Instruction &inst, const triton::ast::SharedAbstractNode &node, const triton::arch::MemoryAccess &mem, const std::string &comment="")
Returns the new shared symbolic memory expression expression and links this expression to the instruc...
triton::usize uniqueSymExprId
Symbolic expressions id.
std::unordered_map< triton::uint64, SharedSymbolicExpression > memoryReference
map of address -> symbolic expression
TRITON_EXPORT const SharedSymbolicExpression & createSymbolicRegisterExpression(triton::arch::Instruction &inst, const triton::ast::SharedAbstractNode &node, const triton::arch::Register ®, const std::string &comment="")
Returns the new shared symbolic register expression expression and links this expression to the instr...
TRITON_EXPORT SharedSymbolicVariable symbolizeExpression(triton::usize exprId, triton::uint32 symVarSize, const std::string &symVarAlias="")
Converts a symbolic expression to a symbolic variable. symVarSize must be in bits.
triton::usize uniqueSymVarId
Symbolic variables id.
TRITON_EXPORT bool isMemorySymbolized(const triton::arch::MemoryAccess &mem) const
Returns true if memory cell expressions contain symbolic variables.
TRITON_EXPORT std::unordered_map< triton::usize, SharedSymbolicExpression > getSymbolicExpressions(void) const
Returns all symbolic expressions.
TRITON_EXPORT bool isSymbolicExpressionExists(triton::usize symExprId) const
Returns true if the symbolic expression ID exists.
TRITON_EXPORT SymbolicEngine & operator=(const SymbolicEngine &other)
Copies a SymbolicEngine.
TRITON_EXPORT SharedSymbolicVariable symbolizeRegister(const triton::arch::Register ®, const std::string &symVarAlias="")
Converts a symbolic register expression to a symbolic variable.
triton::ast::SharedAbstractNode getShiftAst(const triton::arch::arm::ArmOperandProperties &shift, const triton::ast::SharedAbstractNode &node)
Returns the AST corresponding to the shift operation. Mainly used for Arm32 operands.
TRITON_EXPORT SharedSymbolicExpression getSymbolicExpression(triton::usize symExprId) const
Returns the symbolic expression corresponding to an id.
TRITON_EXPORT SharedSymbolicVariable getSymbolicVariable(triton::usize symVarId) const
Returns the symbolic variable corresponding to the symbolic variable id.
TRITON_EXPORT const SharedSymbolicExpression & createSymbolicVolatileExpression(triton::arch::Instruction &inst, const triton::ast::SharedAbstractNode &node, const std::string &comment="")
Returns the new shared symbolic volatile expression expression and links this expression to the instr...
TRITON_EXPORT void assignSymbolicExpressionToMemory(const SharedSymbolicExpression &se, const triton::arch::MemoryAccess &mem)
Assigns a symbolic expression to a memory.
TRITON_EXPORT void setConcreteVariableValue(const SharedSymbolicVariable &symVar, const triton::uint512 &value)
Sets the concrete value of a symbolic variable.
TRITON_EXPORT const std::unordered_map< triton::uint64, SharedSymbolicExpression > & getSymbolicMemory(void) const
Returns the map (addr:expr) of all symbolic memory defined.
TRITON_EXPORT void assignSymbolicExpressionToRegister(const SharedSymbolicExpression &se, const triton::arch::Register ®)
Assigns a symbolic expression to a register.
TRITON_EXPORT void initLeaAst(triton::arch::MemoryAccess &mem, bool force=true)
Initializes the memory access AST (LOAD and STORE).
TRITON_EXPORT std::vector< triton::uint8 > getSymbolicMemoryAreaValue(triton::uint64 baseAddr, triton::usize size)
Returns the symbolic values of a memory area.
TRITON_EXPORT std::unordered_map< triton::arch::register_e, SharedSymbolicExpression > getSymbolicRegisters(void) const
Returns the map of symbolic registers defined.
std::map< std::pair< triton::uint64, triton::uint32 >, SharedSymbolicExpression > alignedMemoryReference
map of <address:size> -> symbolic expression.
TRITON_EXPORT SymbolicEngine(triton::arch::Architecture *architecture, const triton::modes::SharedModes &modes, const triton::ast::SharedAstContext &astCtxt, triton::callbacks::Callbacks *callbacks=nullptr)
Constructor.
TRITON_EXPORT triton::ast::SharedAbstractNode getMemoryAst(const triton::arch::MemoryAccess &mem)
Returns the AST corresponding to the memory.
TRITON_EXPORT SharedSymbolicVariable symbolizeMemory(const triton::arch::MemoryAccess &mem, const std::string &symVarAlias="")
Converts a symbolic memory expression to a symbolic variable.
TRITON_EXPORT triton::uint512 getSymbolicRegisterValue(const triton::arch::Register ®)
Returns the symbolic register value.
TRITON_EXPORT std::vector< SharedSymbolicExpression > getTaintedSymbolicExpressions(void) const
Returns the vector of the tainted symbolic expressions.
TRITON_EXPORT triton::ast::SharedAbstractNode getRegisterAst(const triton::arch::Register ®)
Returns the AST corresponding to the register.
TRITON_EXPORT triton::uint512 getConcreteVariableValue(const SharedSymbolicVariable &symVar) const
Gets the concrete value of a symbolic variable.
TRITON_EXPORT SharedSymbolicVariable newSymbolicVariable(triton::engines::symbolic::variable_e type, triton::uint64 source, triton::uint32 size, const std::string &alias="")
Adds a symbolic variable.
TRITON_EXPORT const SharedSymbolicExpression & createSymbolicExpression(triton::arch::Instruction &inst, const triton::ast::SharedAbstractNode &node, const triton::arch::OperandWrapper &dst, const std::string &comment="")
Returns the new shared symbolic abstract expression and links this expression to the instruction.
TRITON_EXPORT SharedSymbolicExpression newSymbolicExpression(const triton::ast::SharedAbstractNode &node, triton::engines::symbolic::expression_e type, const std::string &comment="")
Creates a new shared symbolic expression.
TRITON_EXPORT const SharedSymbolicExpression & getSymbolicRegister(const triton::arch::Register ®) const
Returns the shared symbolic expression corresponding to the parent register.
TRITON_EXPORT void removeSymbolicExpression(const SharedSymbolicExpression &expr)
Removes the symbolic expression corresponding to the id.
TRITON_EXPORT std::unordered_map< triton::usize, SharedSymbolicExpression > sliceExpressions(const SharedSymbolicExpression &expr)
Slices all expressions from a given one.
triton::uint32 numberOfRegisters
Number of registers.
TRITON_EXPORT triton::uint8 getSymbolicMemoryValue(triton::uint64 address)
Returns the symbolic memory value.
TRITON_EXPORT void concretizeAllMemory(void)
Concretizes all symbolic memory references.
std::unordered_map< triton::usize, WeakSymbolicVariable > symbolicVariables
The map of symbolic variables.
TRITON_EXPORT ~SymbolicEngine()
Destructor.
TRITON_EXPORT triton::ast::SharedAbstractNode getImmediateAst(const triton::arch::Immediate &imm)
Returns the AST corresponding to the immediate.
std::vector< SharedSymbolicExpression > symbolicReg
Symbolic register state.
TRITON_EXPORT void concretizeAllRegister(void)
Concretizes all symbolic register references.
TRITON_EXPORT std::map< triton::usize, SharedSymbolicVariable > getSymbolicVariables(void) const
Returns all symbolic variables.
TRITON_EXPORT void concretizeRegister(const triton::arch::Register ®)
Concretizes a specific symbolic register reference.
TRITON_EXPORT triton::ast::SharedAbstractNode getOperandAst(const triton::arch::OperandWrapper &op)
Returns the AST corresponding to the operand.
TRITON_EXPORT bool isRegisterSymbolized(const triton::arch::Register ®) const
Returns true if the register expression contains a symbolic variable.
TRITON_EXPORT void concretizeMemory(const triton::arch::MemoryAccess &mem)
Concretizes a specific symbolic memory reference.
The symbolic simplification class.
TRITON_EXPORT triton::ast::SharedAbstractNode simplify(const triton::ast::SharedAbstractNode &node) const
Processes all recorded simplifications. Returns the simplified node.
TRITON_EXPORT SymbolicSimplification & operator=(const SymbolicSimplification &other)
Copies a SymbolicSimplification.
The exception class used by the symbolic engine.
register_e
Types of register.
@ ID_SHIFT_LSR
Logical Shift Right (immediate)
@ ID_SHIFT_LSR_REG
Logical Shift Right (register)
@ ID_SHIFT_ASR
Arithmetic Shift Right (immediate)
@ ID_SHIFT_ROR_REG
Rotate Right (register)
@ ID_SHIFT_ROR
Rotate Right (immediate)
@ ID_SHIFT_ASR_REG
Arithmetic Shift Right (register)
@ ID_SHIFT_RRX
Rotate Right with Extend (immediate)
@ ID_SHIFT_RRX_REG
Rotate Right with Extend (register)
@ ID_SHIFT_LSL_REG
Logical Shift Left (register)
@ ID_SHIFT_INVALID
invalid
@ ID_SHIFT_LSL
Logical Shift Left (immediate)
@ ID_EXTEND_SXTW
Extracts a word (32-bit) value from a register and zero extends it to the size of the register.
@ ID_EXTEND_UXTX
Use the whole 64-bit register.
@ ID_EXTEND_SXTX
Use the whole 64-bit register.
@ ID_EXTEND_SXTH
Extracts a halfword (16-bit) value from a register and zero extends it to the size of the register.
@ ID_EXTEND_UXTB
Extracts a byte (8-bit) value from a register and zero extends it to the size of the register.
@ ID_EXTEND_INVALID
invalid
@ ID_EXTEND_UXTW
Extracts a word (32-bit) value from a register and zero extends it to the size of the register.
@ ID_EXTEND_SXTB
Extracts a byte (8-bit) value from a register and zero extends it to the size of the register.
@ ID_EXTEND_UXTH
Extracts a halfword (16-bit) value from a register and zero extends it to the size of the register.
std::shared_ptr< triton::ast::AbstractNode > SharedAbstractNode
Shared Abstract Node.
std::vector< SharedAbstractNode > childrenExtraction(const SharedAbstractNode &node, bool unroll, bool revert)
Returns node and all its children of an AST sorted topologically. If unroll is true,...
std::shared_ptr< triton::ast::AstContext > SharedAstContext
Shared AST context.
constexpr triton::uint32 byte
byte size in bit
constexpr triton::uint32 word
word size in bit
std::shared_ptr< triton::modes::Modes > SharedModes
Shared Modes.
@ ALIGNED_MEMORY
[symbolic] Keep a map of aligned memory.
@ ONLY_ON_SYMBOLIZED
[symbolic] Perform symbolic execution only on symbolized expressions.
@ AST_OPTIMIZATIONS
[AST] Classical arithmetic optimisations to reduce the depth of the trees.
constexpr triton::uint32 fword
fword size in byte
constexpr triton::uint32 dword
dword size in byte
constexpr triton::uint32 dqqword
dqqword size in byte
constexpr triton::uint32 word
word size in byte
constexpr triton::uint32 dqword
dqword size in byte
constexpr triton::uint32 byte
byte size in byte
constexpr triton::uint32 qword
qword size in byte
constexpr triton::uint32 qqword
qqword size in byte
std::shared_ptr< triton::engines::symbolic::SymbolicVariable > SharedSymbolicVariable
Shared Symbolic variable.
expression_e
Type of symbolic expressions.
std::shared_ptr< triton::engines::symbolic::SymbolicExpression > SharedSymbolicExpression
Shared Symbolic Expression.
variable_e
Type of symbolic variable.
@ REGISTER_EXPRESSION
Assigned to a register expression.
@ MEMORY_EXPRESSION
Assigned to a memory expression.
@ VOLATILE_EXPRESSION
Assigned to a volatile expression.
@ REGISTER_VARIABLE
Variable assigned to a register.
@ MEMORY_VARIABLE
Variable assigned to a memory.
@ UNDEFINED_VARIABLE
Undefined assignment.
std::int32_t sint32
signed 32-bits
std::size_t usize
unsigned MAX_INT 32 or 64 bits according to the CPU.
std::uint64_t uint64
unisgned 64-bits
std::uint32_t uint32
unisgned 32-bits
std::uint8_t uint8
unisgned 8-bits
TRITON_EXPORT void fromUintToBuffer(triton::uint80 value, triton::uint8 *buffer)
Inject the value into the buffer. Make sure that the buffer contains at least 10 allocated bytes.