Security analysis tool for EVM bytecode. Supports smart contracts built for Ethereum, Hedera, Quorum, Vechain, Roostock, Tron and other EVM-compatible blockchains.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
mythril/tests/testdata/outputs_expected/underflow.sol.o.graph.html

56 lines
21 KiB

<html>
<head>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/vis/4.21.0/vis.min.css" integrity="sha256-iq5ygGJ7021Pi7H5S+QAUXCPUfaBzfqeplbg/KlEssg=" crossorigin="anonymous" />
<script src="https://cdnjs.cloudflare.com/ajax/libs/vis/4.21.0/vis.min.js" integrity="sha256-JuQeAGbk9rG/EoRMixuy5X8syzICcvB0dj3KindZkY0=" crossorigin="anonymous"></script>
<style type="text/css">
#mynetwork {
background-color: #232625;
}
body {
background-color: #232625;
color: #ffffff;
font-size: 10px;
}
</style>
<script>
var options = {"autoResize": true, "edges": {"font": {"align": "horizontal", "background": "none", "color": "#FFFFFF", "face": "arial", "multi": false, "strokeColor": "#ffffff", "strokeWidth": 0, "vadjust": 0}}, "height": "100%", "layout": {"hierarchical": {"blockShifting": true, "direction": "LR", "edgeMinimization": true, "enabled": true, "levelSeparation": 450, "nodeSpacing": 200, "parentCentralization": false, "sortMethod": "directed", "treeSpacing": 100}, "improvedLayout": true}, "manipulation": false, "nodes": {"borderWidth": 1, "borderWidthSelected": 2, "chosen": true, "color": "#000000", "font": {"align": "left", "color": "#FFFFFF"}, "shape": "box"}, "physics": {"enabled": false}, "width": "100%"};
var nodes = [{"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "98 JUMPDEST fallback\n99 PUSH1 0x00\n101 DUP1\n102 REVERT", "id": "1097", "isExpanded": false, "label": "98 JUMPDEST fallback\n99 PUSH1 0x00\n101 DUP1\n102 REVERT", "size": 150, "truncLabel": "98 JUMPDEST fallback\n99 PUSH1 0x00\n101 DUP1\n102 REVERT"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "122 JUMPDEST _function_0x18160ddd\n123 PUSH1 0x40\n125 MLOAD\n126 DUP1\n127 DUP3\n128 DUP2\n129 MSTORE\n130 PUSH1 0x20\n132 ADD\n133 SWAP2\n134 POP\n135 POP\n136 PUSH1 0x40\n138 MLOAD\n139 DUP1\n140 SWAP2\n141 SUB\n142 SWAP1\n143 RETURN", "id": "1102", "isExpanded": false, "label": "122 JUMPDEST _function_0x18160ddd\n123 PUSH1 0x40\n125 MLOAD\n126 DUP1\n127 DUP3\n128 DUP2\n(click to expand +)", "size": 150, "truncLabel": "122 JUMPDEST _function_0x18160ddd\n123 PUSH1 0x40\n125 MLOAD\n126 DUP1\n127 DUP3\n128 DUP2\n(click to expand +)"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "346 JUMPDEST _function_0x18160ddd\n347 PUSH1 0x01\n349 SLOAD\n350 DUP2\n351 JUMP", "id": "1101", "isExpanded": false, "label": "346 JUMPDEST _function_0x18160ddd\n347 PUSH1 0x01\n349 SLOAD\n350 DUP2\n351 JUMP", "size": 150, "truncLabel": "346 JUMPDEST _function_0x18160ddd\n347 PUSH1 0x01\n349 SLOAD\n350 DUP2\n351 JUMP"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "114 JUMPDEST _function_0x18160ddd\n115 PUSH2 0x007a\n118 PUSH2 0x015a\n121 JUMP", "id": "1100", "isExpanded": false, "label": "114 JUMPDEST _function_0x18160ddd\n115 PUSH2 0x007a\n118 PUSH2 0x015a\n121 JUMP", "size": 150, "truncLabel": "114 JUMPDEST _function_0x18160ddd\n115 PUSH2 0x007a\n118 PUSH2 0x015a\n121 JUMP"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "110 PUSH1 0x00\n112 DUP1\n113 REVERT", "id": "1103", "isExpanded": false, "label": "110 PUSH1 0x00\n112 DUP1\n113 REVERT", "size": 150, "truncLabel": "110 PUSH1 0x00\n112 DUP1\n113 REVERT"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "103 JUMPDEST _function_0x18160ddd\n104 CALLVALUE\n105 ISZERO\n106 PUSH2 0x0072\n109 JUMPI", "id": "1099", "isExpanded": false, "label": "103 JUMPDEST _function_0x18160ddd\n104 CALLVALUE\n105 ISZERO\n106 PUSH2 0x0072\n109 JUMPI", "size": 150, "truncLabel": "103 JUMPDEST _function_0x18160ddd\n104 CALLVALUE\n105 ISZERO\n106 PUSH2 0x0072\n109 JUMPI"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "177 JUMPDEST Token(uint256)\n178 STOP", "id": "1108", "isExpanded": false, "label": "177 JUMPDEST Token(uint256)\n178 STOP", "size": 150, "truncLabel": "177 JUMPDEST Token(uint256)\n178 STOP"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "352 JUMPDEST Token(uint256)\n353 DUP1\n354 PUSH1 0x01\n356 DUP2\n357 SWAP1\n358 SSTORE\n359 PUSH1 0x00\n361 DUP1\n362 CALLER\n363 PUSH20 0xffffffffffffffffffffffffffffffffffffffff\n384 AND\n385 PUSH20 0xffffffffffffffffffffffffffffffffffffffff\n406 AND\n407 DUP2\n408 MSTORE\n409 PUSH1 0x20\n411 ADD\n412 SWAP1\n413 DUP2\n414 MSTORE\n415 PUSH1 0x20\n417 ADD\n418 PUSH1 0x00\n420 SHA3\n421 DUP2\n422 SWAP1\n423 SSTORE\n424 POP\n425 POP\n426 JUMP", "id": "1107", "isExpanded": false, "label": "352 JUMPDEST Token(uint256)\n353 DUP1\n354 PUSH1 0x01\n356 DUP2\n357 SWAP1\n358 SSTORE\n(click to expand +)", "size": 150, "truncLabel": "352 JUMPDEST Token(uint256)\n353 DUP1\n354 PUSH1 0x01\n356 DUP2\n357 SWAP1\n358 SSTORE\n(click to expand +)"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f",
var edges = [{"arrows": "to", "from": "1096", "label": "Not(ULE(4, calldatasize_Unknown))", "smooth": {"type": "cubicBezier"}, "to": "1097"}, {"arrows": "to", "from": "1101", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1102"}, {"arrows": "to", "from": "1100", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1101"}, {"arrows": "to", "from": "1099", "label": "callvalue == 0", "smooth": {"type": "cubicBezier"}, "to": "1100"}, {"arrows": "to", "from": "1099", "label": "Not(callvalue == 0)", "smooth": {"type": "cubicBezier"}, "to": "1103"}, {"arrows": "to", "from": "1098", "label": "Extract(0xff, 0xe0, calldata_Unknown_0) == 0x18160ddd", "smooth": {"type": "cubicBezier"}, "to": "1099"}, {"arrows": "to", "from": "1107", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1108"}, {"arrows": "to", "from": "1106", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1107"}, {"arrows": "to", "from": "1105", "label": "callvalue == 0", "smooth": {"type": "cubicBezier"}, "to": "1106"}, {"arrows": "to", "from": "1105", "label": "Not(callvalue == 0)", "smooth": {"type": "cubicBezier"}, "to": "1109"}, {"arrows": "to", "from": "1104", "label": "Extract(0xff, 0xe0, calldata_Unknown_0) == 0x6241bfd1", "smooth": {"type": "cubicBezier"}, "to": "1105"}, {"arrows": "to", "from": "1113", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1114"}, {"arrows": "to", "from": "1112", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1113"}, {"arrows": "to", "from": "1111", "label": "callvalue == 0", "smooth": {"type": "cubicBezier"}, "to": "1112"}, {"arrows": "to", "from": "1111", "label": "Not(callvalue == 0)", "smooth": {"type": "cubicBezier"}, "to": "1115"}, {"arrows": "to", "from": "1110", "label": "Extract(0xff, 0xe0, calldata_Unknown_0) == 0x70a08231", "smooth": {"type": "cubicBezier"}, "to": "1111"}, {"arrows": "to", "from": "1120", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1121"}, {"arrows": "to", "from": "1119", "label": "True", "smooth": {"type": "cubicBezier"}, "to": "1120"}, {"arrows": "to", "from": "1118", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1119"}, {"arrows": "to", "from": "1117", "label": "callvalue == 0", "smooth": {"type": "cubicBezier"}, "to": "1118"}, {"arrows": "to", "from": "1117", "label": "Not(callvalue == 0)", "smooth": {"type": "cubicBezier"}, "to": "1122"}, {"arrows": "to", "from": "1116", "label": "Extract(0xff, 0xe0, calldata_Unknown_0) == 0xa3210e87", "smooth": {"type": "cubicBezier"}, "to": "1117"}, {"arrows": "to", "from": "1116", "label": "Not(Extract(0xff, 0xe0, calldata_Unknown_0) == 0xa3210e87)", "smooth": {"type": "cubicBezier"}, "to": "1123"}, {"arrows": "to", "from": "1110", "label": "Not(Extract(0xff, 0xe0, calldata_Unknown_0) == 0x70a08231)", "smooth": {"type": "cubicBezier"}, "to": "1116"}, {"arrows": "to", "from": "1104", "label": "Not(Extract(0xff, 0xe0, calldata_Unknown_0) == 0x6241bfd1)", "smooth": {"type": "cubicBezier"}, "to": "1110"}, {"arrows": "to", "from": "1098", "label": "Not(Extract(0xff, 0xe0, calldata_Unknown_0) == 0x18160ddd)", "smooth": {"type": "cubicBezier"}, "to": "1104"}, {"arrows": "to", "from": "1096", "label": "ULE(4, calldatasize_Unknown)", "smooth": {"type": "cubicBezier"}, "to": "1098"}];
</script>
</head>
<body>
<p>Mythril / Ethereum LASER Symbolic VM</p>
<p><div id="mynetwork"></div><br/></p>
<script type="text/javascript">
var container = document.getElementById('mynetwork');
var nodesSet = new vis.DataSet(nodes);
var edgesSet = new vis.DataSet(edges);
var data = {'nodes': nodesSet, 'edges': edgesSet}
var gph = new vis.Network(container, data, options);
gph.on("click", function (params) {
// parse node id
var nodeID = params['nodes']['0'];
if (nodeID) {
var clickedNode = nodesSet.get(nodeID);
if(clickedNode.isExpanded) {
clickedNode.label = clickedNode.truncLabel;
}
else {
clickedNode.label = clickedNode.fullLabel;
}
clickedNode.isExpanded = !clickedNode.isExpanded;
nodesSet.update(clickedNode);
}
});
</script>
</body>
</html>