215 this->architecture = architecture;
217 this->symbolicEngine = symbolicEngine;
218 this->taintEngine = taintEngine;
220 if (architecture ==
nullptr)
223 if (this->symbolicEngine ==
nullptr)
226 if (this->taintEngine ==
nullptr)
240 case ID_INS_B: this->b_s(inst);
break;
375 return this->exception;
383 auto node = this->astCtxt->bv(inst.
getNextAddress(), pc.getBitSize());
406 auto node = this->astCtxt->ite(
407 this->astCtxt->equal(z, this->astCtxt->bvtrue()),
417 auto node = this->astCtxt->ite(
418 this->astCtxt->equal(n, v),
429 auto node = this->astCtxt->ite(
431 this->astCtxt->equal(z, this->astCtxt->bvfalse()),
432 this->astCtxt->equal(n, v)
443 auto node = this->astCtxt->ite(
445 this->astCtxt->equal(c, this->astCtxt->bvtrue()),
446 this->astCtxt->equal(z, this->astCtxt->bvfalse())
456 auto node = this->astCtxt->ite(
457 this->astCtxt->equal(c, this->astCtxt->bvtrue()),
468 auto node = this->astCtxt->ite(
470 this->astCtxt->equal(z, this->astCtxt->bvtrue()),
471 this->astCtxt->lnot(this->astCtxt->equal(n, v))
481 auto node = this->astCtxt->ite(
482 this->astCtxt->equal(c, this->astCtxt->bvfalse()),
492 auto node = this->astCtxt->ite(
494 this->astCtxt->equal(c, this->astCtxt->bvfalse()),
495 this->astCtxt->equal(z, this->astCtxt->bvtrue())
506 auto node = this->astCtxt->ite(
507 this->astCtxt->lnot(this->astCtxt->equal(n, v)),
516 auto node = this->astCtxt->ite(
517 this->astCtxt->equal(n, this->astCtxt->bvtrue()),
526 auto node = this->astCtxt->ite(
527 this->astCtxt->equal(z, this->astCtxt->bvfalse()),
536 auto node = this->astCtxt->ite(
537 this->astCtxt->equal(n, this->astCtxt->bvfalse()),
546 auto node = this->astCtxt->ite(
547 this->astCtxt->equal(v, this->astCtxt->bvfalse()),
556 auto node = this->astCtxt->ite(
557 this->astCtxt->equal(v, this->astCtxt->bvtrue()),
645 auto node = this->astCtxt->bv(0, 1);
657 auto node = this->astCtxt->bv(1, 1);
671 auto nf = this->architecture->
getRegister(ID_REG_AARCH64_N);
678 auto node = this->astCtxt->extract(high, high, this->astCtxt->reference(parent));
684 expr->isTainted = this->taintEngine->
setTaintRegister(nf, parent->isTainted);
693 auto nf = this->architecture->
getRegister(ID_REG_AARCH64_N);
700 auto node1 = this->astCtxt->extract(high, high, this->astCtxt->reference(parent));
701 auto node2 = this->astCtxt->extract(3, 3, nzcv);
702 auto node3 = this->getCodeConditionAst(inst, node1, node2);
708 expr->isTainted = this->taintEngine->
setTaintRegister(nf, parent->isTainted);
716 auto zf = this->architecture->
getRegister(ID_REG_AARCH64_Z);
725 auto node = this->astCtxt->ite(
726 this->astCtxt->equal(
727 this->astCtxt->extract(high, low, this->astCtxt->reference(parent)),
728 this->astCtxt->bv(0, bvSize)
730 this->astCtxt->bv(1, 1),
731 this->astCtxt->bv(0, 1)
738 expr->isTainted = this->taintEngine->
setTaintRegister(zf, parent->isTainted);
747 auto zf = this->architecture->
getRegister(ID_REG_AARCH64_Z);
756 auto node1 = this->astCtxt->ite(
757 this->astCtxt->equal(
758 this->astCtxt->extract(high, low, this->astCtxt->reference(parent)),
759 this->astCtxt->bv(0, bvSize)
761 this->astCtxt->bv(1, 1),
762 this->astCtxt->bv(0, 1)
764 auto node2 = this->astCtxt->extract(2, 2, nzcv);
765 auto node3 = this->getCodeConditionAst(inst, node1, node2);
771 expr->isTainted = this->taintEngine->
setTaintRegister(zf, parent->isTainted);
781 auto cf = this->architecture->
getRegister(ID_REG_AARCH64_C);
790 auto node = this->astCtxt->extract(bvSize-1, bvSize-1,
791 this->astCtxt->bvxor(
792 this->astCtxt->bvand(op1, op2),
793 this->astCtxt->bvand(
794 this->astCtxt->bvxor(
795 this->astCtxt->bvxor(op1, op2),
796 this->astCtxt->extract(high, low, this->astCtxt->reference(parent))
798 this->astCtxt->bvxor(op1, op2))
806 expr->isTainted = this->taintEngine->
setTaintRegister(cf, parent->isTainted);
816 auto cf = this->architecture->
getRegister(ID_REG_AARCH64_C);
825 auto node = this->astCtxt->bvxor(
826 this->astCtxt->extract(bvSize-1, bvSize-1,
827 this->astCtxt->bvxor(
828 this->astCtxt->bvxor(op1, this->astCtxt->bvxor(op2, this->astCtxt->extract(high, low, this->astCtxt->reference(parent)))),
829 this->astCtxt->bvand(
830 this->astCtxt->bvxor(op1, this->astCtxt->extract(high, low, this->astCtxt->reference(parent))),
831 this->astCtxt->bvxor(op1, op2)
835 this->astCtxt->bvtrue()
842 expr->isTainted = this->taintEngine->
setTaintRegister(cf, parent->isTainted);
853 auto cf = this->architecture->
getRegister(ID_REG_AARCH64_C);
865 auto node1 = this->astCtxt->bvxor(
866 this->astCtxt->extract(bvSize-1, bvSize-1,
867 this->astCtxt->bvxor(
868 this->astCtxt->bvxor(op1, this->astCtxt->bvxor(op2, this->astCtxt->extract(high, low, this->astCtxt->reference(parent)))),
869 this->astCtxt->bvand(
870 this->astCtxt->bvxor(op1, this->astCtxt->extract(high, low, this->astCtxt->reference(parent))),
871 this->astCtxt->bvxor(op1, op2)
875 this->astCtxt->bvtrue()
877 auto node2 = this->astCtxt->extract(1, 1, nzcv);
878 auto node3 = this->getCodeConditionAst(inst, node1, node2);
884 expr->isTainted = this->taintEngine->
setTaintRegister(cf, parent->isTainted);
894 auto vf = this->architecture->
getRegister(ID_REG_AARCH64_V);
903 auto node = this->astCtxt->extract(bvSize-1, bvSize-1,
904 this->astCtxt->bvand(
905 this->astCtxt->bvxor(op1, this->astCtxt->bvnot(op2)),
906 this->astCtxt->bvxor(op1, this->astCtxt->extract(high, low, this->astCtxt->reference(parent)))
914 expr->isTainted = this->taintEngine->
setTaintRegister(vf, parent->isTainted);
924 auto vf = this->architecture->
getRegister(ID_REG_AARCH64_V);
933 auto node = this->astCtxt->extract(bvSize-1, bvSize-1,
934 this->astCtxt->bvand(
935 this->astCtxt->bvxor(op1, op2),
936 this->astCtxt->bvxor(op1, this->astCtxt->extract(high, low, this->astCtxt->reference(parent)))
944 expr->isTainted = this->taintEngine->
setTaintRegister(vf, parent->isTainted);
955 auto vf = this->architecture->
getRegister(ID_REG_AARCH64_V);
967 auto node1 = this->astCtxt->extract(bvSize-1, bvSize-1,
968 this->astCtxt->bvand(
969 this->astCtxt->bvxor(op1, op2),
970 this->astCtxt->bvxor(op1, this->astCtxt->extract(high, low, this->astCtxt->reference(parent)))
973 auto node2 = this->astCtxt->extract(0, 0, nzcv);
974 auto node3 = this->getCodeConditionAst(inst, node1, node2);
980 expr->isTainted = this->taintEngine->
setTaintRegister(vf, parent->isTainted);
996 auto node = this->astCtxt->bvadd(this->astCtxt->bvadd(op1, op2), this->astCtxt->zx(dst.
getBitSize()-1, op3));
1002 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2) | this->taintEngine->isTainted(cf));
1006 this->cfAdd_s(inst, expr, dst, op1, op2);
1007 this->nf_s(inst, expr, dst);
1008 this->vfAdd_s(inst, expr, dst, op1, op2);
1009 this->zf_s(inst, expr, dst);
1013 this->controlFlow_s(inst);
1027 auto node = this->astCtxt->bvadd(op1, op2);
1033 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
1037 this->cfAdd_s(inst, expr, dst, op1, op2);
1038 this->nf_s(inst, expr, dst);
1039 this->vfAdd_s(inst, expr, dst, op1, op2);
1040 this->zf_s(inst, expr, dst);
1044 this->controlFlow_s(inst);
1064 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src) | this->taintEngine->isTainted(pc));
1067 this->controlFlow_s(inst);
1087 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src) | this->taintEngine->isTainted(pc));
1090 this->controlFlow_s(inst);
1104 auto node = this->astCtxt->bvand(op1, op2);
1108 node = this->astCtxt->extract(63, 0, node);
1115 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
1119 this->clearFlag_s(inst, this->architecture->
getRegister(ID_REG_AARCH64_C),
"Clears carry flag");
1120 this->nf_s(inst, expr, dst);
1121 this->clearFlag_s(inst, this->architecture->
getRegister(ID_REG_AARCH64_V),
"Clears overflow flag");
1122 this->zf_s(inst, expr, dst);
1126 this->controlFlow_s(inst);
1134 auto size = src2.getBitSize();
1138 auto op2 = this->astCtxt->bvand(
1140 this->astCtxt->bv(size - 1, size)
1144 auto node = this->astCtxt->bvashr(op1, op2);
1150 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
1153 this->controlFlow_s(inst);
1166 auto node = this->getCodeConditionAst(inst, op1, op2);
1172 expr->isTainted = this->taintEngine->
setTaint(dst, this->getCodeConditionTainteSate(inst));
1176 if (!(node->getChildren()[0]->evaluate().is_zero())) {
1191 auto lsb =
static_cast<uint32>(src2.getImmediate().getValue());
1192 auto width =
static_cast<uint32>(src3.getImmediate().getValue());
1199 auto opDst = this->symbolicEngine->
getOperandAst(inst, dst);
1202 std::vector<triton::ast::SharedAbstractNode> chunks;
1206 chunks.push_back(this->astCtxt->extract(dst.
getBitSize() - 1, lsb + width, opDst));
1208 chunks.push_back(this->astCtxt->extract(width - 1, 0, op));
1209 chunks.push_back(this->astCtxt->extract(lsb - 1, 0, opDst));
1211 auto node = this->astCtxt->concat(chunks);
1217 expr->isTainted = this->taintEngine->
taintUnion(dst, src1);
1220 this->controlFlow_s(inst);
1229 auto lsb =
static_cast<uint32>(src2.getImmediate().getValue());
1230 auto width =
static_cast<uint32>(src3.getImmediate().getValue());
1236 auto opSrc = this->symbolicEngine->
getOperandAst(inst, src1);
1237 auto opDst = this->symbolicEngine->
getOperandAst(inst, dst);
1239 auto node = this->astCtxt->concat(
1240 this->astCtxt->extract(dst.
getBitSize() - 1, width, opDst),
1241 this->astCtxt->extract(lsb + width - 1, lsb, opSrc)
1248 expr->isTainted = this->taintEngine->
taintUnion(dst, src1);
1251 this->controlFlow_s(inst);
1265 auto node = this->astCtxt->bvand(op1, this->astCtxt->bvnot(op2));
1271 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
1275 this->clearFlag_s(inst, this->architecture->
getRegister(ID_REG_AARCH64_C),
"Clears carry flag");
1276 this->nf_s(inst, expr, src1);
1277 this->clearFlag_s(inst, this->architecture->
getRegister(ID_REG_AARCH64_V),
"Clears overflow flag");
1278 this->zf_s(inst, expr, src1);
1282 this->controlFlow_s(inst);
1293 auto node1 = this->astCtxt->bv(inst.
getNextAddress(), dst1.getBitSize());
1294 auto node2 = this->symbolicEngine->
getOperandAst(inst, src);
1318 auto node1 = this->astCtxt->bv(inst.
getNextAddress(), dst1.getBitSize());
1319 auto node2 = this->symbolicEngine->
getOperandAst(inst, src);
1363 this->controlFlow_s(inst);
1373 auto op1 = this->astCtxt->zx(dst.
getBitSize() - src1.getBitSize(), this->symbolicEngine->getOperandAst(inst, src1));
1374 auto op2 = this->astCtxt->zx(dst.
getBitSize() - src2.getBitSize(), this->symbolicEngine->getOperandAst(inst, src2));
1377 auto node = this->astCtxt->ite(
1378 this->astCtxt->lnot(this->astCtxt->equal(op1, this->astCtxt->bv(0, op1->getBitvectorSize()))),
1387 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
1390 if (op1->evaluate() != 0)
1404 auto op1 = this->astCtxt->zx(dst.
getBitSize() - src1.getBitSize(), this->symbolicEngine->getOperandAst(inst, src1));
1405 auto op2 = this->astCtxt->zx(dst.
getBitSize() - src2.getBitSize(), this->symbolicEngine->getOperandAst(inst, src2));
1408 auto node = this->astCtxt->ite(
1409 this->astCtxt->equal(op1, this->astCtxt->bv(0, op1->getBitvectorSize())),
1418 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
1421 if (op1->evaluate() == 0)
1440 auto node = this->astCtxt->bvsub(op1, op2);
1446 expr->isTainted = this->taintEngine->
isTainted(src1) | this->taintEngine->
isTainted(src2);
1449 this->cfCcmp_s(inst, expr, src1, op1, op2, op3);
1450 this->nfCcmp_s(inst, expr, src1, op3);
1451 this->vfCcmp_s(inst, expr, src1, op1, op2, op3);
1452 this->zfCcmp_s(inst, expr, src1, op3);
1455 this->controlFlow_s(inst);
1465 auto op2 = this->astCtxt->bvadd(op1, this->astCtxt->bv(1, src.getBitSize()));
1468 auto node = this->getCodeConditionAst(inst, op2, op1);
1474 expr->isTainted = this->taintEngine->
setTaint(dst, this->getCodeConditionTainteSate(inst));
1477 this->controlFlow_s(inst);
1491 switch (src.getSize()) {
1493 node = this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(31, 31, op), this->astCtxt->bvtrue()), this->astCtxt->bv(0, bvSize),
1494 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(30, 30, op), this->astCtxt->bvtrue()), this->astCtxt->bv(1, bvSize),
1495 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(29, 29, op), this->astCtxt->bvtrue()), this->astCtxt->bv(2, bvSize),
1496 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(28, 28, op), this->astCtxt->bvtrue()), this->astCtxt->bv(3, bvSize),
1497 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(27, 27, op), this->astCtxt->bvtrue()), this->astCtxt->bv(4, bvSize),
1498 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(26, 26, op), this->astCtxt->bvtrue()), this->astCtxt->bv(5, bvSize),
1499 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(25, 25, op), this->astCtxt->bvtrue()), this->astCtxt->bv(6, bvSize),
1500 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(24, 24, op), this->astCtxt->bvtrue()), this->astCtxt->bv(7, bvSize),
1501 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(23, 23, op), this->astCtxt->bvtrue()), this->astCtxt->bv(8, bvSize),
1502 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(22, 22, op), this->astCtxt->bvtrue()), this->astCtxt->bv(9, bvSize),
1503 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(21, 21, op), this->astCtxt->bvtrue()), this->astCtxt->bv(10, bvSize),
1504 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(20, 20, op), this->astCtxt->bvtrue()), this->astCtxt->bv(11, bvSize),
1505 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(19, 19, op), this->astCtxt->bvtrue()), this->astCtxt->bv(12, bvSize),
1506 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(18, 18, op), this->astCtxt->bvtrue()), this->astCtxt->bv(13, bvSize),
1507 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(17, 17, op), this->astCtxt->bvtrue()), this->astCtxt->bv(14, bvSize),
1508 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(16, 16, op), this->astCtxt->bvtrue()), this->astCtxt->bv(15, bvSize),
1509 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(15, 15, op), this->astCtxt->bvtrue()), this->astCtxt->bv(16, bvSize),
1510 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(14, 14, op), this->astCtxt->bvtrue()), this->astCtxt->bv(17, bvSize),
1511 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(13, 13, op), this->astCtxt->bvtrue()), this->astCtxt->bv(18, bvSize),
1512 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(12, 12, op), this->astCtxt->bvtrue()), this->astCtxt->bv(19, bvSize),
1513 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(11, 11, op), this->astCtxt->bvtrue()), this->astCtxt->bv(20, bvSize),
1514 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(10, 10, op), this->astCtxt->bvtrue()), this->astCtxt->bv(21, bvSize),
1515 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(9, 9, op), this->astCtxt->bvtrue()), this->astCtxt->bv(22, bvSize),
1516 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(8, 8, op), this->astCtxt->bvtrue()), this->astCtxt->bv(23, bvSize),
1517 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(7, 7, op), this->astCtxt->bvtrue()), this->astCtxt->bv(24, bvSize),
1518 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(6, 6, op), this->astCtxt->bvtrue()), this->astCtxt->bv(25, bvSize),
1519 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(5, 5, op), this->astCtxt->bvtrue()), this->astCtxt->bv(26, bvSize),
1520 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(4, 4, op), this->astCtxt->bvtrue()), this->astCtxt->bv(27, bvSize),
1521 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(3, 3, op), this->astCtxt->bvtrue()), this->astCtxt->bv(28, bvSize),
1522 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(2, 2, op), this->astCtxt->bvtrue()), this->astCtxt->bv(29, bvSize),
1523 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(1, 1, op), this->astCtxt->bvtrue()), this->astCtxt->bv(30, bvSize),
1524 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(0, 0, op), this->astCtxt->bvtrue()), this->astCtxt->bv(31, bvSize),
1525 this->astCtxt->bv(32, bvSize)
1526 ))))))))))))))))))))))))))))))));
1530 node = this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(63, 63, op), this->astCtxt->bvtrue()), this->astCtxt->bv(0, bvSize),
1531 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(62, 62, op), this->astCtxt->bvtrue()), this->astCtxt->bv(1, bvSize),
1532 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(61, 61, op), this->astCtxt->bvtrue()), this->astCtxt->bv(2, bvSize),
1533 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(60, 60, op), this->astCtxt->bvtrue()), this->astCtxt->bv(3, bvSize),
1534 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(59, 59, op), this->astCtxt->bvtrue()), this->astCtxt->bv(4, bvSize),
1535 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(58, 58, op), this->astCtxt->bvtrue()), this->astCtxt->bv(5, bvSize),
1536 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(57, 57, op), this->astCtxt->bvtrue()), this->astCtxt->bv(6, bvSize),
1537 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(56, 56, op), this->astCtxt->bvtrue()), this->astCtxt->bv(7, bvSize),
1538 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(55, 55, op), this->astCtxt->bvtrue()), this->astCtxt->bv(8, bvSize),
1539 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(54, 54, op), this->astCtxt->bvtrue()), this->astCtxt->bv(9, bvSize),
1540 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(53, 53, op), this->astCtxt->bvtrue()), this->astCtxt->bv(10, bvSize),
1541 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(52, 52, op), this->astCtxt->bvtrue()), this->astCtxt->bv(11, bvSize),
1542 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(51, 51, op), this->astCtxt->bvtrue()), this->astCtxt->bv(12, bvSize),
1543 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(50, 50, op), this->astCtxt->bvtrue()), this->astCtxt->bv(13, bvSize),
1544 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(49, 49, op), this->astCtxt->bvtrue()), this->astCtxt->bv(14, bvSize),
1545 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(48, 48, op), this->astCtxt->bvtrue()), this->astCtxt->bv(15, bvSize),
1546 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(47, 47, op), this->astCtxt->bvtrue()), this->astCtxt->bv(16, bvSize),
1547 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(46, 46, op), this->astCtxt->bvtrue()), this->astCtxt->bv(17, bvSize),
1548 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(45, 45, op), this->astCtxt->bvtrue()), this->astCtxt->bv(18, bvSize),
1549 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(44, 44, op), this->astCtxt->bvtrue()), this->astCtxt->bv(19, bvSize),
1550 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(43, 43, op), this->astCtxt->bvtrue()), this->astCtxt->bv(20, bvSize),
1551 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(42, 42, op), this->astCtxt->bvtrue()), this->astCtxt->bv(21, bvSize),
1552 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(41, 41, op), this->astCtxt->bvtrue()), this->astCtxt->bv(22, bvSize),
1553 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(40, 40, op), this->astCtxt->bvtrue()), this->astCtxt->bv(23, bvSize),
1554 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(39, 39, op), this->astCtxt->bvtrue()), this->astCtxt->bv(24, bvSize),
1555 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(38, 38, op), this->astCtxt->bvtrue()), this->astCtxt->bv(25, bvSize),
1556 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(37, 37, op), this->astCtxt->bvtrue()), this->astCtxt->bv(26, bvSize),
1557 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(36, 36, op), this->astCtxt->bvtrue()), this->astCtxt->bv(27, bvSize),
1558 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(35, 35, op), this->astCtxt->bvtrue()), this->astCtxt->bv(28, bvSize),
1559 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(34, 34, op), this->astCtxt->bvtrue()), this->astCtxt->bv(29, bvSize),
1560 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(33, 33, op), this->astCtxt->bvtrue()), this->astCtxt->bv(30, bvSize),
1561 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(32, 32, op), this->astCtxt->bvtrue()), this->astCtxt->bv(31, bvSize),
1562 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(31, 31, op), this->astCtxt->bvtrue()), this->astCtxt->bv(32, bvSize),
1563 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(30, 30, op), this->astCtxt->bvtrue()), this->astCtxt->bv(33, bvSize),
1564 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(29, 29, op), this->astCtxt->bvtrue()), this->astCtxt->bv(34, bvSize),
1565 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(28, 28, op), this->astCtxt->bvtrue()), this->astCtxt->bv(35, bvSize),
1566 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(27, 27, op), this->astCtxt->bvtrue()), this->astCtxt->bv(36, bvSize),
1567 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(26, 26, op), this->astCtxt->bvtrue()), this->astCtxt->bv(37, bvSize),
1568 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(25, 25, op), this->astCtxt->bvtrue()), this->astCtxt->bv(38, bvSize),
1569 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(24, 24, op), this->astCtxt->bvtrue()), this->astCtxt->bv(39, bvSize),
1570 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(23, 23, op), this->astCtxt->bvtrue()), this->astCtxt->bv(40, bvSize),
1571 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(22, 22, op), this->astCtxt->bvtrue()), this->astCtxt->bv(41, bvSize),
1572 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(21, 21, op), this->astCtxt->bvtrue()), this->astCtxt->bv(42, bvSize),
1573 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(20, 20, op), this->astCtxt->bvtrue()), this->astCtxt->bv(43, bvSize),
1574 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(19, 19, op), this->astCtxt->bvtrue()), this->astCtxt->bv(44, bvSize),
1575 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(18, 18, op), this->astCtxt->bvtrue()), this->astCtxt->bv(45, bvSize),
1576 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(17, 17, op), this->astCtxt->bvtrue()), this->astCtxt->bv(46, bvSize),
1577 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(16, 16, op), this->astCtxt->bvtrue()), this->astCtxt->bv(47, bvSize),
1578 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(15, 15, op), this->astCtxt->bvtrue()), this->astCtxt->bv(48, bvSize),
1579 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(14, 14, op), this->astCtxt->bvtrue()), this->astCtxt->bv(49, bvSize),
1580 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(13, 13, op), this->astCtxt->bvtrue()), this->astCtxt->bv(50, bvSize),
1581 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(12, 12, op), this->astCtxt->bvtrue()), this->astCtxt->bv(51, bvSize),
1582 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(11, 11, op), this->astCtxt->bvtrue()), this->astCtxt->bv(52, bvSize),
1583 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(10, 10, op), this->astCtxt->bvtrue()), this->astCtxt->bv(53, bvSize),
1584 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(9, 9, op), this->astCtxt->bvtrue()), this->astCtxt->bv(54, bvSize),
1585 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(8, 8, op), this->astCtxt->bvtrue()), this->astCtxt->bv(55, bvSize),
1586 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(7, 7, op), this->astCtxt->bvtrue()), this->astCtxt->bv(56, bvSize),
1587 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(6, 6, op), this->astCtxt->bvtrue()), this->astCtxt->bv(57, bvSize),
1588 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(5, 5, op), this->astCtxt->bvtrue()), this->astCtxt->bv(58, bvSize),
1589 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(4, 4, op), this->astCtxt->bvtrue()), this->astCtxt->bv(59, bvSize),
1590 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(3, 3, op), this->astCtxt->bvtrue()), this->astCtxt->bv(60, bvSize),
1591 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(2, 2, op), this->astCtxt->bvtrue()), this->astCtxt->bv(61, bvSize),
1592 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(1, 1, op), this->astCtxt->bvtrue()), this->astCtxt->bv(62, bvSize),
1593 this->astCtxt->ite(this->astCtxt->equal(this->astCtxt->extract(0, 0, op), this->astCtxt->bvtrue()), this->astCtxt->bv(63, bvSize),
1594 this->astCtxt->bv(64, bvSize)
1595 ))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))));
1609 this->controlFlow_s(inst);
1622 auto node = this->astCtxt->bvadd(op1, op2);
1628 expr->isTainted = this->taintEngine->
isTainted(src1) | this->taintEngine->
isTainted(src2);
1631 this->cfAdd_s(inst, expr, src1, op1, op2);
1632 this->nf_s(inst, expr, src1);
1633 this->vfAdd_s(inst, expr, src1, op1, op2);
1634 this->zf_s(inst, expr, src1);
1637 this->controlFlow_s(inst);
1650 auto node = this->astCtxt->bvsub(op1, op2);
1656 expr->isTainted = this->taintEngine->
isTainted(src1) | this->taintEngine->
isTainted(src2);
1659 this->cfSub_s(inst, expr, src1, op1, op2);
1660 this->nf_s(inst, expr, src1);
1661 this->vfSub_s(inst, expr, src1, op1, op2);
1662 this->zf_s(inst, expr, src1);
1665 this->controlFlow_s(inst);
1674 auto op1 = this->astCtxt->bvneg(this->symbolicEngine->
getOperandAst(inst, src));
1678 auto node = this->getCodeConditionAst(inst, op1, op2);
1684 expr->isTainted = this->taintEngine->
taintUnion(dst, src);
1687 this->controlFlow_s(inst);
1701 auto node = this->getCodeConditionAst(inst, op1, op2);
1707 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
1710 this->controlFlow_s(inst);
1718 auto op1 = this->astCtxt->bv(1, dst.
getBitSize());
1719 auto op2 = this->astCtxt->bv(0, dst.
getBitSize());
1722 auto node = this->getCodeConditionAst(inst, op1, op2);
1728 expr->isTainted = this->taintEngine->
setTaint(dst, this->getCodeConditionTainteSate(inst));
1731 this->controlFlow_s(inst);
1742 auto op2 = this->astCtxt->bvadd(
1744 this->astCtxt->bv(1, src2.getBitSize())
1748 auto node = this->getCodeConditionAst(inst, op1, op2);
1754 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
1757 this->controlFlow_s(inst);
1768 auto op2 = this->astCtxt->bvneg(this->symbolicEngine->
getOperandAst(inst, src2));
1771 auto node = this->getCodeConditionAst(inst, op1, op2);
1777 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
1780 this->controlFlow_s(inst);
1794 auto node = this->astCtxt->bvxnor(op1, op2);
1800 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
1803 this->controlFlow_s(inst);
1817 auto node = this->astCtxt->bvxor(op1, op2);
1821 node = this->astCtxt->extract(63, 0, node);
1828 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
1831 this->controlFlow_s(inst);
1840 auto lsb =
static_cast<uint32>(src3.getImmediate().getValue());
1847 auto node = this->astCtxt->extract(lsb + dst.
getBitSize() - 1, lsb, this->astCtxt->concat(op1, op2));
1856 this->controlFlow_s(inst);
1873 this->controlFlow_s(inst);
1877 std::list<triton::ast::SharedAbstractNode> vec0;
1878 std::list<triton::ast::SharedAbstractNode> vec1;
1879 std::list<triton::ast::SharedAbstractNode> vec2;
1908 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
1909 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
1910 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
1927 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
1928 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
1929 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
1946 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
1947 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
1948 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
1965 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
1966 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
1967 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
1984 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
1985 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
1986 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2003 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2004 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2005 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2022 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2023 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2024 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2039 auto node0 = this->astCtxt->concat(vec0);
2040 auto node1 = this->astCtxt->concat(vec1);
2041 auto node2 = this->astCtxt->concat(vec2);
2049 expr0->isTainted = vt0_t;
2050 expr1->isTainted = vt1_t;
2051 expr2->isTainted = vt2_t;
2058 auto base = mem.getBaseRegister();
2059 auto offset = inst.
operands[4].getRegister();
2062 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
2063 auto offsetNode = this->symbolicEngine->
getOperandAst(inst, offset);
2066 auto node3 = this->astCtxt->bvadd(baseNode, offsetNode);
2072 expr3->isTainted = this->taintEngine->
isTainted(base) | this->taintEngine->
isTainted(offset);
2081 auto base = mem.getBaseRegister();
2082 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
2085 auto node3 = this->astCtxt->bvadd(baseNode, this->astCtxt->bv(postIndex, base.getBitSize()));
2091 expr3->isTainted = this->taintEngine->
isTainted(base);
2095 this->controlFlow_s(inst);
2100 std::list<triton::ast::SharedAbstractNode> vec0;
2101 std::list<triton::ast::SharedAbstractNode> vec1;
2102 std::list<triton::ast::SharedAbstractNode> vec2;
2132 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2133 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2134 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2151 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2152 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2153 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2170 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2171 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2172 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2189 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2190 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2191 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2208 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2209 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2210 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2227 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2228 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2229 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2246 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2247 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2248 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2265 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2266 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2267 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2283 auto node0 = this->astCtxt->concat(vec0);
2284 auto node1 = this->astCtxt->concat(vec1);
2285 auto node2 = this->astCtxt->concat(vec2);
2293 expr0->isTainted = vt0_t;
2294 expr1->isTainted = vt1_t;
2295 expr2->isTainted = vt2_t;
2302 auto base = mem.getBaseRegister();
2303 auto offset = inst.
operands[4].getRegister();
2306 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
2307 auto offsetNode = this->symbolicEngine->
getOperandAst(inst, offset);
2310 auto node3 = this->astCtxt->bvadd(baseNode, offsetNode);
2316 expr3->isTainted = this->taintEngine->
isTainted(base) | this->taintEngine->
isTainted(offset);
2325 auto base = mem.getBaseRegister();
2326 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
2329 auto node3 = this->astCtxt->bvadd(baseNode, this->astCtxt->bv(postIndex, base.getBitSize()));
2335 expr3->isTainted = this->taintEngine->
isTainted(base);
2339 this->controlFlow_s(inst);
2344 std::list<triton::ast::SharedAbstractNode> vec0;
2345 std::list<triton::ast::SharedAbstractNode> vec1;
2346 std::list<triton::ast::SharedAbstractNode> vec2;
2347 std::list<triton::ast::SharedAbstractNode> vec3;
2379 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2380 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2381 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2382 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2401 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2402 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2403 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2404 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2423 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2424 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2425 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2426 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2445 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2446 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2447 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2448 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2467 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2468 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2469 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2470 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2489 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2490 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2491 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2492 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2511 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2512 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2513 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2514 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2530 auto node0 = this->astCtxt->concat(vec0);
2531 auto node1 = this->astCtxt->concat(vec1);
2532 auto node2 = this->astCtxt->concat(vec2);
2533 auto node3 = this->astCtxt->concat(vec3);
2542 expr0->isTainted = vt0_t;
2543 expr1->isTainted = vt1_t;
2544 expr2->isTainted = vt2_t;
2545 expr3->isTainted = vt3_t;
2552 auto base = mem.getBaseRegister();
2553 auto offset = inst.
operands[5].getRegister();
2556 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
2557 auto offsetNode = this->symbolicEngine->
getOperandAst(inst, offset);
2560 auto node4 = this->astCtxt->bvadd(baseNode, offsetNode);
2566 expr4->isTainted = this->taintEngine->
isTainted(base) | this->taintEngine->
isTainted(offset);
2575 auto base = mem.getBaseRegister();
2576 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
2579 auto node4 = this->astCtxt->bvadd(baseNode, this->astCtxt->bv(postIndex, base.getBitSize()));
2585 expr4->isTainted = this->taintEngine->
isTainted(base);
2589 this->controlFlow_s(inst);
2594 std::list<triton::ast::SharedAbstractNode> vec0;
2595 std::list<triton::ast::SharedAbstractNode> vec1;
2596 std::list<triton::ast::SharedAbstractNode> vec2;
2597 std::list<triton::ast::SharedAbstractNode> vec3;
2630 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2631 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2632 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2633 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2652 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2653 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2654 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2655 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2674 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2675 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2676 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2677 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2696 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2697 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2698 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2699 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2718 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2719 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2720 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2721 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2740 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2741 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2742 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2743 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2762 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2763 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2764 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2765 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2784 vec0.push_front(this->symbolicEngine->
getMemoryAst(inst, vt0_m));
2785 vec1.push_front(this->symbolicEngine->
getMemoryAst(inst, vt1_m));
2786 vec2.push_front(this->symbolicEngine->
getMemoryAst(inst, vt2_m));
2787 vec3.push_front(this->symbolicEngine->
getMemoryAst(inst, vt3_m));
2804 auto node0 = this->astCtxt->concat(vec0);
2805 auto node1 = this->astCtxt->concat(vec1);
2806 auto node2 = this->astCtxt->concat(vec2);
2807 auto node3 = this->astCtxt->concat(vec3);
2816 expr0->isTainted = vt0_t;
2817 expr1->isTainted = vt1_t;
2818 expr2->isTainted = vt2_t;
2819 expr3->isTainted = vt3_t;
2826 auto base = mem.getBaseRegister();
2827 auto offset = inst.
operands[5].getRegister();
2830 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
2831 auto offsetNode = this->symbolicEngine->
getOperandAst(inst, offset);
2834 auto node4 = this->astCtxt->bvadd(baseNode, offsetNode);
2840 expr4->isTainted = this->taintEngine->
isTainted(base) | this->taintEngine->
isTainted(offset);
2849 auto base = mem.getBaseRegister();
2850 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
2853 auto node4 = this->astCtxt->bvadd(baseNode, this->astCtxt->bv(postIndex, base.getBitSize()));
2859 expr4->isTainted = this->taintEngine->
isTainted(base);
2863 this->controlFlow_s(inst);
2881 this->controlFlow_s(inst);
2899 this->controlFlow_s(inst);
2917 this->controlFlow_s(inst);
2938 this->controlFlow_s(inst);
2959 this->controlFlow_s(inst);
2980 this->controlFlow_s(inst);
2996 auto node1 = this->astCtxt->extract((dst1.
getBitSize() - 1), 0, op);
3008 this->controlFlow_s(inst);
3024 auto node1 = this->astCtxt->extract((dst1.
getBitSize() - 1), 0, op);
3042 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
3043 auto immNode = this->symbolicEngine->
getOperandAst(inst, imm);
3046 auto node2 = this->astCtxt->bvadd(baseNode, this->astCtxt->sx(base.
getBitSize() - imm.
getBitSize(), immNode));
3049 auto expr2 = this->symbolicEngine->
createSymbolicExpression(inst, node2, base,
"LDP operation - Base register computation");
3052 expr2->isTainted = this->taintEngine->
isTainted(base);
3063 auto expr3 = this->symbolicEngine->
createSymbolicExpression(inst, node3, base,
"LDP operation - Base register computation");
3066 expr3->isTainted = this->taintEngine->
isTainted(base);
3070 this->controlFlow_s(inst);
3083 auto node1 = this->astCtxt->sx(32, this->astCtxt->extract(31, 0, op));
3084 auto node2 = this->astCtxt->sx(32, this->astCtxt->extract(63, 32, op));
3101 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
3102 auto immNode = this->symbolicEngine->
getOperandAst(inst, imm);
3105 auto node2 = this->astCtxt->bvadd(baseNode, this->astCtxt->sx(base.
getBitSize() - imm.
getBitSize(), immNode));
3108 auto expr2 = this->symbolicEngine->
createSymbolicExpression(inst, node2, base,
"LDPSW operation - Base register computation");
3111 expr2->isTainted = this->taintEngine->
isTainted(base);
3122 auto expr3 = this->symbolicEngine->
createSymbolicExpression(inst, node3, base,
"LDPSW operation - Base register computation");
3125 expr3->isTainted = this->taintEngine->
isTainted(base);
3129 this->controlFlow_s(inst);
3143 auto node1 = this->symbolicEngine->
getOperandAst(inst, src);
3158 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
3159 auto immNode = this->symbolicEngine->
getOperandAst(inst, imm);
3162 auto node2 = this->astCtxt->bvadd(baseNode, this->astCtxt->sx(base.
getBitSize() - imm.
getBitSize(), immNode));
3165 auto expr2 = this->symbolicEngine->
createSymbolicExpression(inst, node2, base,
"LDR operation - Base register computation");
3168 expr2->isTainted = this->taintEngine->
isTainted(base);
3178 auto expr3 = this->symbolicEngine->
createSymbolicExpression(inst, node3, base,
"LDR operation - Base register computation");
3181 expr3->isTainted = this->taintEngine->
isTainted(base);
3185 this->controlFlow_s(inst);
3194 auto node1 = this->symbolicEngine->
getOperandAst(inst, src);
3209 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
3210 auto immNode = this->symbolicEngine->
getOperandAst(inst, imm);
3213 auto node2 = this->astCtxt->bvadd(baseNode, this->astCtxt->sx(base.
getBitSize() - imm.
getBitSize(), immNode));
3216 auto expr2 = this->symbolicEngine->
createSymbolicExpression(inst, node2, base,
"LDRB operation - Base register computation");
3219 expr2->isTainted = this->taintEngine->
isTainted(base);
3230 auto expr3 = this->symbolicEngine->
createSymbolicExpression(inst, node3, base,
"LDRB operation - Base register computation");
3233 expr3->isTainted = this->taintEngine->
isTainted(base);
3237 this->controlFlow_s(inst);
3246 auto node1 = this->symbolicEngine->
getOperandAst(inst, src);
3261 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
3262 auto immNode = this->symbolicEngine->
getOperandAst(inst, imm);
3265 auto node2 = this->astCtxt->bvadd(baseNode, this->astCtxt->sx(base.
getBitSize() - imm.
getBitSize(), immNode));
3268 auto expr2 = this->symbolicEngine->
createSymbolicExpression(inst, node2, base,
"LDRH operation - Base register computation");
3271 expr2->isTainted = this->taintEngine->
isTainted(base);
3282 auto expr3 = this->symbolicEngine->
createSymbolicExpression(inst, node3, base,
"LDRH operation - Base register computation");
3285 expr3->isTainted = this->taintEngine->
isTainted(base);
3289 this->controlFlow_s(inst);
3301 auto node1 = this->astCtxt->sx(dst.
getBitSize() - 8, op);
3316 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
3317 auto immNode = this->symbolicEngine->
getOperandAst(inst, imm);
3320 auto node2 = this->astCtxt->bvadd(baseNode, this->astCtxt->sx(base.
getBitSize() - imm.
getBitSize(), immNode));
3323 auto expr2 = this->symbolicEngine->
createSymbolicExpression(inst, node2, base,
"LDRSB operation - Base register computation");
3326 expr2->isTainted = this->taintEngine->
isTainted(base);
3337 auto expr3 = this->symbolicEngine->
createSymbolicExpression(inst, node3, base,
"LDRSB operation - Base register computation");
3340 expr3->isTainted = this->taintEngine->
isTainted(base);
3344 this->controlFlow_s(inst);
3356 auto node1 = this->astCtxt->sx(dst.
getBitSize() - 16, op);
3371 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
3372 auto immNode = this->symbolicEngine->
getOperandAst(inst, imm);
3375 auto node2 = this->astCtxt->bvadd(baseNode, this->astCtxt->sx(base.
getBitSize() - imm.
getBitSize(), immNode));
3378 auto expr2 = this->symbolicEngine->
createSymbolicExpression(inst, node2, base,
"LDRSH operation - Base register computation");
3381 expr2->isTainted = this->taintEngine->
isTainted(base);
3392 auto expr3 = this->symbolicEngine->
createSymbolicExpression(inst, node3, base,
"LDRSH operation - Base register computation");
3395 expr3->isTainted = this->taintEngine->
isTainted(base);
3399 this->controlFlow_s(inst);
3416 auto node1 = this->astCtxt->sx(dst.
getBitSize() - 32, op);
3431 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
3432 auto immNode = this->symbolicEngine->
getOperandAst(inst, imm);
3435 auto node2 = this->astCtxt->bvadd(baseNode, this->astCtxt->sx(base.
getBitSize() - imm.
getBitSize(), immNode));
3438 auto expr2 = this->symbolicEngine->
createSymbolicExpression(inst, node2, base,
"LDRSW operation - Base register computation");
3441 expr2->isTainted = this->taintEngine->
isTainted(base);
3452 auto expr3 = this->symbolicEngine->
createSymbolicExpression(inst, node3, base,
"LDRSW operation - Base register computation");
3455 expr3->isTainted = this->taintEngine->
isTainted(base);
3459 this->controlFlow_s(inst);
3477 this->controlFlow_s(inst);
3489 auto node = this->astCtxt->zx(dst.
getBitSize() - 8, op);
3498 this->controlFlow_s(inst);
3510 auto node = this->astCtxt->zx(dst.
getBitSize() - 16, op);
3519 this->controlFlow_s(inst);
3531 auto node = this->astCtxt->sx(dst.
getBitSize() - 8, op);
3540 this->controlFlow_s(inst);
3552 auto node = this->astCtxt->sx(dst.
getBitSize() - 16, op);
3561 this->controlFlow_s(inst);
3573 auto node = this->astCtxt->sx(dst.
getBitSize() - 32, op);
3582 this->controlFlow_s(inst);
3600 this->controlFlow_s(inst);
3612 auto node = this->astCtxt->zx(dst.
getBitSize() - 8, op);
3621 this->controlFlow_s(inst);
3633 auto node = this->astCtxt->zx(dst.
getBitSize() - 16, op);
3642 this->controlFlow_s(inst);
3654 auto node = this->astCtxt->sx(dst.
getBitSize() - 8, op);
3663 this->controlFlow_s(inst);
3675 auto node = this->astCtxt->sx(dst.
getBitSize() - 16, op);
3684 this->controlFlow_s(inst);
3696 auto node = this->astCtxt->sx(dst.
getBitSize() - 32, op);
3705 this->controlFlow_s(inst);
3721 auto node1 = this->astCtxt->extract((dst1.
getBitSize() - 1), 0, op);
3736 this->controlFlow_s(inst);
3757 this->controlFlow_s(inst);
3769 auto node = this->astCtxt->zx(dst.
getBitSize() - 8, op);
3781 this->controlFlow_s(inst);
3793 auto node = this->astCtxt->zx(dst.
getBitSize() - 16, op);
3805 this->controlFlow_s(inst);
3813 auto size = src2.getBitSize();
3817 auto op2 = this->astCtxt->bvand(
3819 this->astCtxt->bv(size - 1, size)
3823 auto node = this->astCtxt->bvshl(op1, op2);
3829 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
3832 this->controlFlow_s(inst);
3840 auto size = src2.getBitSize();
3844 auto op2 = this->astCtxt->bvand(
3846 this->astCtxt->bv(size - 1, size)
3850 auto node = this->astCtxt->bvlshr(op1, op2);
3856 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
3859 this->controlFlow_s(inst);
3875 auto node = this->astCtxt->bvadd(op3, this->astCtxt->bvmul(op1, op2));
3881 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2) | this->taintEngine->isTainted(src3));
3884 this->controlFlow_s(inst);
3898 auto node = this->astCtxt->bvneg(this->astCtxt->bvmul(op1, op2));
3904 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
3907 this->controlFlow_s(inst);
3925 this->controlFlow_s(inst);
3930 std::list<triton::ast::SharedAbstractNode> vec;
3942 vec.push_front(this->astCtxt->extract(7, 0, imm));
3949 vec.push_front(this->astCtxt->extract(7, 0, imm));
3956 vec.push_front(this->astCtxt->extract(15, 0, imm));
3963 vec.push_front(this->astCtxt->extract(15, 0, imm));
3970 vec.push_front(this->astCtxt->extract(31, 0, imm));
3977 vec.push_front(this->astCtxt->extract(31, 0, imm));
3984 vec.push_front(this->astCtxt->extract(63, 0, imm));
3991 vec.push_front(this->astCtxt->extract(63, 0, imm));
4001 auto node = this->astCtxt->concat(vec);
4010 this->controlFlow_s(inst);
4024 std::vector<triton::ast::SharedAbstractNode> bits;
4030 bits.push_back(this->astCtxt->extract(dst.
getHigh(), 16, op1));
4031 bits.push_back(this->astCtxt->extract(15, 0, op2));
4042 bits.push_back(this->astCtxt->extract(dst.
getHigh(), 32, op1));
4044 bits.push_back(this->astCtxt->extract(31, 16, op2));
4045 bits.push_back(this->astCtxt->extract(15, 0, op1));
4050 bits.push_back(this->astCtxt->extract(dst.
getHigh(), 48, op1));
4051 bits.push_back(this->astCtxt->extract(47, 32, op2));
4052 bits.push_back(this->astCtxt->extract(31, 0, op1));
4057 bits.push_back(this->astCtxt->extract(63, 48, op2));
4058 bits.push_back(this->astCtxt->extract(47, 0, op1));
4065 auto node = this->astCtxt->concat(bits);
4071 expr->isTainted = this->taintEngine->
taintUnion(dst, src);
4074 this->controlFlow_s(inst);
4086 auto node = this->astCtxt->bvnot(op);
4095 this->controlFlow_s(inst);
4113 this->controlFlow_s(inst);
4131 this->controlFlow_s(inst);
4149 this->controlFlow_s(inst);
4165 auto node = this->astCtxt->bvsub(op3, this->astCtxt->bvmul(op1, op2));
4171 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2) | this->taintEngine->isTainted(src3));
4174 this->controlFlow_s(inst);
4188 auto node = this->astCtxt->bvmul(op1, op2);
4194 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
4197 this->controlFlow_s(inst);
4209 auto node = this->astCtxt->bvnot(op);
4218 this->controlFlow_s(inst);
4230 auto node = this->astCtxt->bvneg(op);
4239 this->controlFlow_s(inst);
4245 this->controlFlow_s(inst);
4259 auto node = this->astCtxt->bvor(op1, this->astCtxt->bvnot(op2));
4265 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
4268 this->controlFlow_s(inst);
4282 auto node = this->astCtxt->bvor(op1, op2);
4286 node = this->astCtxt->extract(63, 0, node);
4293 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
4296 this->controlFlow_s(inst);
4308 std::vector<triton::ast::SharedAbstractNode> bits;
4312 bits.push_back(this->astCtxt->extract(index, index, op));
4315 auto node = this->astCtxt->concat(bits);
4324 this->controlFlow_s(inst);
4330 auto src = ((inst.
operands.size() == 1) ? inst.
operands[0] :
triton::arch::OperandWrapper(this->architecture->getRegister(ID_REG_AARCH64_X30)));
4351 std::list<triton::ast::SharedAbstractNode> bits;
4355 bits.push_front(this->astCtxt->extract(63, 56, op));
4356 bits.push_front(this->astCtxt->extract(55, 48, op));
4357 bits.push_front(this->astCtxt->extract(47, 40, op));
4358 bits.push_front(this->astCtxt->extract(39, 32, op));
4360 bits.push_front(this->astCtxt->extract(31, 24, op));
4361 bits.push_front(this->astCtxt->extract(23, 16, op));
4362 bits.push_front(this->astCtxt->extract(15, 8, op));
4363 bits.push_front(this->astCtxt->extract(7, 0, op));
4370 auto node = this->astCtxt->concat(bits);
4379 this->controlFlow_s(inst);
4391 std::vector<triton::ast::SharedAbstractNode> bits;
4396 bits.push_back(this->astCtxt->extract(55, 48, op));
4397 bits.push_back(this->astCtxt->extract(63, 56, op));
4398 bits.push_back(this->astCtxt->extract(39, 32, op));
4399 bits.push_back(this->astCtxt->extract(47, 40, op));
4401 bits.push_back(this->astCtxt->extract(23, 16, op));
4402 bits.push_back(this->astCtxt->extract(31, 24, op));
4403 bits.push_back(this->astCtxt->extract(7, 0, op));
4404 bits.push_back(this->astCtxt->extract(15, 8, op));
4411 auto node = this->astCtxt->concat(bits);
4420 this->controlFlow_s(inst);
4432 std::vector<triton::ast::SharedAbstractNode> bits;
4435 bits.push_back(this->astCtxt->extract(39, 32, op));
4436 bits.push_back(this->astCtxt->extract(47, 40, op));
4437 bits.push_back(this->astCtxt->extract(55, 48, op));
4438 bits.push_back(this->astCtxt->extract(63, 56, op));
4439 bits.push_back(this->astCtxt->extract(7, 0, op));
4440 bits.push_back(this->astCtxt->extract(15, 8, op));
4441 bits.push_back(this->astCtxt->extract(23, 16, op));
4442 bits.push_back(this->astCtxt->extract(31, 24, op));
4444 auto node = this->astCtxt->concat(bits);
4453 this->controlFlow_s(inst);
4467 auto node = this->astCtxt->bvror(op1, op2);
4473 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
4476 this->controlFlow_s(inst);
4492 auto node = this->astCtxt->bvadd(this->astCtxt->bvadd(op1, this->astCtxt->bvnot(op2)), this->astCtxt->zx(dst.
getBitSize()-1, op3));
4498 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2) | this->taintEngine->isTainted(cf));
4502 this->cfSub_s(inst, expr, src1, op1, op2);
4503 this->nf_s(inst, expr, src1);
4504 this->vfSub_s(inst, expr, src1, op1, op2);
4505 this->zf_s(inst, expr, src1);
4509 this->controlFlow_s(inst);
4518 auto lsb =
static_cast<uint32>(src2.getImmediate().getValue());
4519 auto width =
static_cast<uint32>(src3.getImmediate().getValue());
4528 auto node = this->astCtxt->sx(dst.
getBitSize() - width, this->astCtxt->extract(lsb+width-1, lsb, op));
4537 this->controlFlow_s(inst);
4551 auto node = this->astCtxt->ite(
4552 this->astCtxt->equal(op2, this->astCtxt->bv(0, op2->getBitvectorSize())),
4554 this->astCtxt->bvsdiv(op1, op2)
4561 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
4564 this->controlFlow_s(inst);
4580 auto node = this->astCtxt->bvadd(
4582 this->astCtxt->bvmul(
4592 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2) | this->taintEngine->isTainted(src3));
4595 this->controlFlow_s(inst);
4611 auto node = this->astCtxt->bvsub(
4613 this->astCtxt->bvmul(
4623 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2) | this->taintEngine->isTainted(src3));
4626 this->controlFlow_s(inst);
4640 auto node = this->astCtxt->extract(
4643 this->astCtxt->bvmul(
4653 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
4656 this->controlFlow_s(inst);
4670 auto node = this->astCtxt->bvmul(
4679 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
4682 this->controlFlow_s(inst);
4700 this->controlFlow_s(inst);
4712 auto node = this->astCtxt->extract(7, 0, op);
4721 this->controlFlow_s(inst);
4733 auto node = this->astCtxt->extract(15, 0, op);
4742 this->controlFlow_s(inst);
4755 auto node1 = this->astCtxt->bv(exclusive ? 0 : 1, dst1.getBitSize());
4756 auto node2 = this->symbolicEngine->
getOperandAst(inst, src);
4762 expr1->isTainted = this->taintEngine->
setTaint(dst1,
false);
4774 this->controlFlow_s(inst);
4790 auto node1 = this->astCtxt->bv(exclusive ? 0 : 1, dst1.getBitSize());
4791 auto node2 = this->astCtxt->extract(7, 0, op);
4797 expr1->isTainted = this->taintEngine->
setTaint(dst1,
false);
4809 this->controlFlow_s(inst);
4825 auto node1 = this->astCtxt->bv(exclusive ? 0 : 1, dst1.getBitSize());
4826 auto node2 = this->astCtxt->extract(15, 0, op);
4832 expr1->isTainted = this->taintEngine->
setTaint(dst1,
false);
4844 this->controlFlow_s(inst);
4858 auto node = this->astCtxt->concat(op2, op1);
4867 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
4870 this->controlFlow_s(inst);
4884 auto node = this->astCtxt->concat(op2, op1);
4893 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
4902 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
4903 auto immNode = this->symbolicEngine->
getOperandAst(inst, imm);
4906 auto node2 = this->astCtxt->bvadd(baseNode, this->astCtxt->sx(base.
getBitSize() - imm.
getBitSize(), immNode));
4909 auto expr2 = this->symbolicEngine->
createSymbolicExpression(inst, node2, base,
"STP operation - Base register computation");
4912 expr2->isTainted = this->taintEngine->
isTainted(base);
4923 auto expr3 = this->symbolicEngine->
createSymbolicExpression(inst, node3, base,
"STP operation - Base register computation");
4926 expr3->isTainted = this->taintEngine->
isTainted(base);
4930 this->controlFlow_s(inst);
4939 auto node1 = this->symbolicEngine->
getOperandAst(inst, src);
4954 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
4955 auto immNode = this->symbolicEngine->
getOperandAst(inst, imm);
4958 auto node2 = this->astCtxt->bvadd(baseNode, this->astCtxt->sx(base.
getBitSize() - imm.
getBitSize(), immNode));
4961 auto expr2 = this->symbolicEngine->
createSymbolicExpression(inst, node2, base,
"STR operation - Base register computation");
4964 expr2->isTainted = this->taintEngine->
isTainted(base);
4975 auto expr3 = this->symbolicEngine->
createSymbolicExpression(inst, node3, base,
"STR operation - Base register computation");
4978 expr3->isTainted = this->taintEngine->
isTainted(base);
4982 this->controlFlow_s(inst);
4994 auto node1 = this->astCtxt->extract(7, 0, op);
5009 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
5010 auto immNode = this->symbolicEngine->
getOperandAst(inst, imm);
5013 auto node2 = this->astCtxt->bvadd(baseNode, this->astCtxt->sx(base.
getBitSize() - imm.
getBitSize(), immNode));
5016 auto expr2 = this->symbolicEngine->
createSymbolicExpression(inst, node2, base,
"STRB operation - Base register computation");
5019 expr2->isTainted = this->taintEngine->
isTainted(base);
5030 auto expr3 = this->symbolicEngine->
createSymbolicExpression(inst, node3, base,
"STRB operation - Base register computation");
5033 expr3->isTainted = this->taintEngine->
isTainted(base);
5037 this->controlFlow_s(inst);
5049 auto node1 = this->astCtxt->extract(15, 0, op);
5064 auto baseNode = this->symbolicEngine->
getOperandAst(inst, base);
5065 auto immNode = this->symbolicEngine->
getOperandAst(inst, imm);
5068 auto node2 = this->astCtxt->bvadd(baseNode, this->astCtxt->sx(base.
getBitSize() - imm.
getBitSize(), immNode));
5071 auto expr2 = this->symbolicEngine->
createSymbolicExpression(inst, node2, base,
"STRH operation - Base register computation");
5074 expr2->isTainted = this->taintEngine->
isTainted(base);
5085 auto expr3 = this->symbolicEngine->
createSymbolicExpression(inst, node3, base,
"STRH operation - Base register computation");
5088 expr3->isTainted = this->taintEngine->
isTainted(base);
5092 this->controlFlow_s(inst);
5110 this->controlFlow_s(inst);
5122 auto node = this->astCtxt->extract(7, 0, op);
5131 this->controlFlow_s(inst);
5143 auto node = this->astCtxt->extract(15, 0, op);
5152 this->controlFlow_s(inst);
5170 this->controlFlow_s(inst);
5182 auto node = this->astCtxt->extract(7, 0, op);
5191 this->controlFlow_s(inst);
5203 auto node = this->astCtxt->extract(15, 0, op);
5212 this->controlFlow_s(inst);
5233 auto node1 = this->astCtxt->bv(exclusive ? 0 : 1, dst1.getBitSize());
5234 auto node2 = this->astCtxt->concat(op2, op1);
5240 expr1->isTainted = this->taintEngine->
setTaint(dst1,
false);
5245 expr2->isTainted = this->taintEngine->
setTaint(dst2, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
5252 this->controlFlow_s(inst);
5265 auto node1 = this->astCtxt->bv(exclusive ? 0 : 1, dst1.getBitSize());
5266 auto node2 = this->symbolicEngine->
getOperandAst(inst, src);
5272 expr1->isTainted = this->taintEngine->
setTaint(dst1,
false);
5284 this->controlFlow_s(inst);
5300 auto node1 = this->astCtxt->bv(exclusive ? 0 : 1, dst1.getBitSize());
5301 auto node2 = this->astCtxt->extract(7, 0, op);
5307 expr1->isTainted = this->taintEngine->
setTaint(dst1,
false);
5319 this->controlFlow_s(inst);
5335 auto node1 = this->astCtxt->bv(exclusive ? 0 : 1, dst1.getBitSize());
5336 auto node2 = this->astCtxt->extract(15, 0, op);
5342 expr1->isTainted = this->taintEngine->
setTaint(dst1,
false);
5354 this->controlFlow_s(inst);
5368 auto node = this->astCtxt->bvsub(op1, op2);
5374 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
5378 this->cfSub_s(inst, expr, dst, op1, op2);
5379 this->nf_s(inst, expr, dst);
5380 this->vfSub_s(inst, expr, dst, op1, op2);
5381 this->zf_s(inst, expr, dst);
5385 this->controlFlow_s(inst);
5396 this->controlFlow_s(inst);
5408 auto node = this->astCtxt->sx(dst.
getBitSize() - 8, this->astCtxt->extract(7, 0, op));
5417 this->controlFlow_s(inst);
5429 auto node = this->astCtxt->sx(dst.
getBitSize() - 16, this->astCtxt->extract(15, 0, op));
5438 this->controlFlow_s(inst);
5450 auto node = this->astCtxt->sx(dst.
getBitSize() - 32, this->astCtxt->extract(31, 0, op));
5459 this->controlFlow_s(inst);
5475 auto node = this->astCtxt->ite(
5476 this->astCtxt->equal(
5477 this->astCtxt->extract(0, 0, this->astCtxt->bvlshr(op1, op2)),
5478 this->astCtxt->bvtrue()
5480 this->astCtxt->zx(dst.
getBitSize() - op3->getBitvectorSize(), op3),
5488 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
5491 if (this->astCtxt->extract(0, 0, this->astCtxt->bvlshr(op1, op2))->evaluate() != 0)
5506 auto op1 = this->astCtxt->zx(dst.
getBitSize() - src1.
getBitSize(), this->symbolicEngine->getOperandAst(inst, src1));
5507 auto op2 = this->astCtxt->zx(dst.
getBitSize() - src2.
getBitSize(), this->symbolicEngine->getOperandAst(inst, src2));
5508 auto op3 = this->astCtxt->zx(dst.
getBitSize() - src3.getBitSize(), this->symbolicEngine->getOperandAst(inst, src3));
5511 auto node = this->astCtxt->ite(
5512 this->astCtxt->equal(
5513 this->astCtxt->extract(0, 0, this->astCtxt->bvlshr(op1, op2)),
5514 this->astCtxt->bvfalse()
5516 this->astCtxt->zx(dst.
getBitSize() - op3->getBitvectorSize(), op3),
5524 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
5527 if (this->astCtxt->extract(0, 0, this->astCtxt->bvlshr(op1, op2))->evaluate() == 0)
5544 auto node = this->astCtxt->bvand(op1, op2);
5550 expr->isTainted = this->taintEngine->
isTainted(src1) | this->taintEngine->
isTainted(src2);
5554 this->clearFlag_s(inst, this->architecture->
getRegister(ID_REG_AARCH64_C),
"Clears carry flag");
5555 this->nf_s(inst, expr, src1);
5556 this->clearFlag_s(inst, this->architecture->
getRegister(ID_REG_AARCH64_V),
"Clears overflow flag");
5557 this->zf_s(inst, expr, src1);
5561 this->controlFlow_s(inst);
5571 auto width =
static_cast<uint32>(src3.getImmediate().getValue());
5580 std::vector<triton::ast::SharedAbstractNode> bits;
5584 bits.push_back(this->astCtxt->bv(0, dst.
getBitSize() - (lsb + width)));
5587 bits.push_back(this->astCtxt->extract(width - 1, 0, op));
5590 bits.push_back(this->astCtxt->bv(0, lsb));
5593 auto node = this->astCtxt->concat(bits);
5602 this->controlFlow_s(inst);
5612 auto width =
static_cast<uint32>(src3.getImmediate().getValue());
5621 auto node = this->astCtxt->zx(dst.
getBitSize() - width, this->astCtxt->extract(lsb+width-1, lsb, op));
5630 this->controlFlow_s(inst);
5644 auto node = this->astCtxt->ite(
5645 this->astCtxt->equal(op2, this->astCtxt->bv(0, op2->getBitvectorSize())),
5647 this->astCtxt->bvudiv(op1, op2)
5654 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
5657 this->controlFlow_s(inst);
5673 auto node = this->astCtxt->bvadd(
5675 this->astCtxt->bvmul(
5685 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2) | this->taintEngine->isTainted(src3));
5688 this->controlFlow_s(inst);
5701 this->symbolicEngine->getOperandAst(src)
5710 this->controlFlow_s(inst);
5723 auto node = this->astCtxt->bvneg(
5724 this->astCtxt->bvmul(
5734 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
5737 this->controlFlow_s(inst);
5753 auto node = this->astCtxt->bvsub(
5755 this->astCtxt->bvmul(
5765 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2) | this->taintEngine->isTainted(src3));
5768 this->controlFlow_s(inst);
5782 auto node = this->astCtxt->extract(
5785 this->astCtxt->bvmul(
5795 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
5798 this->controlFlow_s(inst);
5812 auto node = this->astCtxt->bvmul(
5821 expr->isTainted = this->taintEngine->
setTaint(dst, this->taintEngine->
isTainted(src1) | this->taintEngine->isTainted(src2));
5824 this->controlFlow_s(inst);
5836 auto node = this->astCtxt->zx(dst.
getBitSize() - 8, this->astCtxt->extract(7, 0, op));
5845 this->controlFlow_s(inst);
5857 auto node = this->astCtxt->zx(dst.
getBitSize() - 16, this->astCtxt->extract(15, 0, op));
5866 this->controlFlow_s(inst);
The abstract architecture class.
TRITON_EXPORT const triton::arch::Register & getRegister(triton::arch::register_e id) const
Returns register from id.
TRITON_EXPORT bool isMemoryExclusive(const triton::arch::MemoryAccess &mem) const
Returns true if the memory access is tagged as exclusive. Only valid for Arm32 and AArch64.
TRITON_EXPORT void setMemoryExclusiveTag(const triton::arch::MemoryAccess &mem, bool tag)
Sets exclusive memory access tag. Only valid for Arm32 and AArch64.
TRITON_EXPORT const triton::arch::Register & getParentRegister(triton::arch::register_e id) const
Returns parent register from id.
TRITON_EXPORT void setBits(triton::uint32 high, triton::uint32 low)
Sets the bits (high, low) position.
This class is used to represent an instruction.
TRITON_EXPORT bool isWriteBack(void) const
Returns true if the instruction performs a write back. Mainly used for AArch64 instructions like LDR.
TRITON_EXPORT void setConditionTaken(bool flag)
Sets flag to define if the condition is taken or not.
TRITON_EXPORT triton::uint32 getType(void) const
Returns the type of the instruction.
std::vector< triton::arch::OperandWrapper > operands
A list of operands.
TRITON_EXPORT bool isUpdateFlag(void) const
Returns true if the instruction updates flags. Mainly used for AArch64 instructions like ADDS.
TRITON_EXPORT triton::arch::arm::condition_e getCodeCondition(void) const
Returns the code codition of the instruction (mainly for AArch64).
TRITON_EXPORT triton::uint64 getNextAddress(void) const
Returns the next address of the instruction.
This class is used to represent a memory access.
TRITON_EXPORT triton::ast::SharedAbstractNode getLeaAst(void) const
Returns the AST of the memory access (LEA).
TRITON_EXPORT triton::arch::Register & getBaseRegister(void)
LEA - Returns the base register operand.
This class is used as operand wrapper.
TRITON_EXPORT triton::uint32 getLow(void) const
Returns the lower bit position of the abstract operand.
TRITON_EXPORT triton::arch::operand_e getType(void) const
Returns the abstract type of the operand.
TRITON_EXPORT triton::uint32 getSize(void) const
Returns the abstract size (in bytes) of the operand.
TRITON_EXPORT const triton::arch::MemoryAccess & getConstMemory(void) const
Returns the memory operand as const.
TRITON_EXPORT triton::arch::MemoryAccess & getMemory(void)
Returns the memory operand.
TRITON_EXPORT const triton::arch::Register & getConstRegister(void) const
Returns the register operand.
TRITON_EXPORT triton::uint32 getHigh(void) const
Returns the highest bit position of the abstract operand.
TRITON_EXPORT const triton::arch::Immediate & getConstImmediate(void) const
Returns the immediate operand.
TRITON_EXPORT triton::uint32 getBitSize(void) const
Returns the abstract size (in bits) of the operand.
TRITON_EXPORT triton::arch::Immediate & getImmediate(void)
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::uint32 getShiftImmediate(void) const
Returns the value of the shift immediate.
TRITON_EXPORT triton::arch::arm::vas_e getVASType(void) const
Returns the vector arrangement specifier.
TRITON_EXPORT triton::uint32 getVASSize(void) const
Returns the vector arrangement specifier size (64 or 128 bits).
TRITON_EXPORT triton::arch::exception_e buildSemantics(triton::arch::Instruction &inst)
Builds the semantics of the instruction. Returns triton::arch::NO_FAULT if succeed.
TRITON_EXPORT AArch64Semantics(triton::arch::Architecture *architecture, triton::engines::symbolic::SymbolicEngine *symbolicEngine, triton::engines::taint::TaintEngine *taintEngine, const triton::ast::SharedAstContext &astCtxt)
Constructor.
TRITON_EXPORT void pushPathConstraint(const triton::arch::Instruction &inst, const triton::engines::symbolic::SharedSymbolicExpression &expr)
Pushs constraints of a branch instruction to the path predicate.
The symbolic engine class.
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 symbolic register expression expression and links this expression to the instruction.
TRITON_EXPORT const SharedSymbolicExpression & createSymbolicVolatileExpression(triton::arch::Instruction &inst, const triton::ast::SharedAbstractNode &node, const std::string &comment="")
Returns the new symbolic volatile expression expression and links this expression to the instruction.
TRITON_EXPORT triton::ast::SharedAbstractNode getMemoryAst(const triton::arch::MemoryAccess &mem)
Returns the AST corresponding to the memory.
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 symbolic expression and links this expression to the instruction.
TRITON_EXPORT triton::ast::SharedAbstractNode getOperandAst(const triton::arch::OperandWrapper &op)
Returns the AST corresponding to the operand.
TRITON_EXPORT bool setTaint(const triton::arch::OperandWrapper &op, bool flag)
Sets the flag (taint or untaint) to an abstract operand (Register or Memory).
TRITON_EXPORT bool isTainted(const triton::arch::OperandWrapper &op) const
Abstract taint verification. Returns true if the operand is tainted.
TRITON_EXPORT bool isMemoryTainted(triton::uint64 addr, triton::uint32 size=1) const
Returns true if the addr is tainted.
TRITON_EXPORT bool taintUnion(const triton::arch::OperandWrapper &op1, const triton::arch::OperandWrapper &op2)
Abstract union tainting.
TRITON_EXPORT bool setTaintRegister(const triton::arch::Register ®, bool flag)
Sets the flag (taint or untaint) to a register.
TRITON_EXPORT bool taintAssignment(const triton::arch::OperandWrapper &op1, const triton::arch::OperandWrapper &op2)
Abstract assignment tainting.
The exception class used by all semantics.
vas_e
Vector arrangement specifier.
@ ID_VAS_4S
4 lanes, each containing a 32-bit element.
@ ID_VAS_2D
2 lanes, each containing a 64-bit element.
@ ID_VAS_1D
1 lane containing a 64-bit element.
@ ID_VAS_16B
16 lanes, each containing an 8-bit element.
@ ID_VAS_8B
8 lanes, each containing an 8-bit element.
@ ID_VAS_8H
8 lanes, each containing a 16-bit element.
@ ID_VAS_4H
4 lanes, each containing a 16-bit element.
@ ID_VAS_2S
2 lanes, each containing a 32-bit element.
@ ID_CONDITION_HS
Higher or same (unsigned >=). C set.
@ ID_CONDITION_PL
Positive or zero. N clear.
@ ID_CONDITION_VC
No overflow. V clear.
@ ID_CONDITION_LE
Signed <=. Z set, N and V differ.
@ ID_CONDITION_VS
Overflow. V set.
@ ID_CONDITION_MI
Negative. N set.
@ ID_CONDITION_GE
Signed >=. N and V the same.
@ ID_CONDITION_GT
Signed >. Z clear, N and V the same.
@ ID_CONDITION_HI
Higher (unsigned >). C set and Z clear.
@ ID_CONDITION_NE
Not equal. Z clear.
@ ID_CONDITION_AL
Always. Any flags. This suffix is normally omitted.
@ ID_CONDITION_LO
Lower (unsigned <). C clear.
@ ID_CONDITION_LT
Signed <. N and V differ.
@ ID_CONDITION_LS
Lower or same (unsigned <=). C clear or Z set.
@ ID_CONDITION_EQ
Equal. Z set.
std::shared_ptr< triton::ast::AbstractNode > SharedAbstractNode
Shared Abstract Node.
std::shared_ptr< triton::ast::AstContext > SharedAstContext
Shared AST context.
constexpr triton::uint32 byte
byte size in bit
constexpr triton::uint32 dword
dword size in bit
constexpr triton::uint32 qword
qword size in bit
constexpr triton::uint32 dqword
dqword size in bit
constexpr triton::uint32 dword
dword size in byte
constexpr triton::uint32 word
word size in byte
constexpr triton::uint32 byte
byte size in byte
constexpr triton::uint32 qword
qword size in byte
std::shared_ptr< triton::engines::symbolic::SymbolicExpression > SharedSymbolicExpression
Shared Symbolic Expression.
const bool UNTAINTED
Defines an untainted item.
std::uint32_t uint32
unisgned 32-bits