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/origin.sol.o.graph.html

56 lines
15 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": "76 JUMPDEST fallback\n77 PUSH1 0x00\n79 DUP1\n80 REVERT", "id": "1133", "isExpanded": false, "label": "76 JUMPDEST fallback\n77 PUSH1 0x00\n79 DUP1\n80 REVERT", "size": 150, "truncLabel": "76 JUMPDEST fallback\n77 PUSH1 0x00\n79 DUP1\n80 REVERT"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "100 JUMPDEST _function_0x8da5cb5b\n101 PUSH1 0x40\n103 MLOAD\n104 DUP1\n105 DUP3\n106 PUSH20 0xffffffffffffffffffffffffffffffffffffffff\n127 AND\n128 PUSH20 0xffffffffffffffffffffffffffffffffffffffff\n149 AND\n150 DUP2\n151 MSTORE\n152 PUSH1 0x20\n154 ADD\n155 SWAP2\n156 POP\n157 POP\n158 PUSH1 0x40\n160 MLOAD\n161 DUP1\n162 SWAP2\n163 SUB\n164 SWAP1\n165 RETURN", "id": "1138", "isExpanded": false, "label": "100 JUMPDEST _function_0x8da5cb5b\n101 PUSH1 0x40\n103 MLOAD\n104 DUP1\n105 DUP3\n106 PUSH20 0xffffffffffffffffffffffffffffffffffffffff\n(click to expand +)", "size": 150, "truncLabel": "100 JUMPDEST _function_0x8da5cb5b\n101 PUSH1 0x40\n103 MLOAD\n104 DUP1\n105 DUP3\n106 PUSH20 0xffffffffffffffffffffffffffffffffffffffff\n(click to expand +)"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "223 JUMPDEST _function_0x8da5cb5b\n224 PUSH1 0x00\n226 DUP1\n227 SWAP1\n228 SLOAD\n229 SWAP1\n230 PUSH2 0x0100\n233 EXP\n234 SWAP1\n235 DIV\n236 PUSH20 0xffffffffffffffffffffffffffffffffffffffff\n257 AND\n258 DUP2\n259 JUMP", "id": "1137", "isExpanded": false, "label": "223 JUMPDEST _function_0x8da5cb5b\n224 PUSH1 0x00\n226 DUP1\n227 SWAP1\n228 SLOAD\n229 SWAP1\n(click to expand +)", "size": 150, "truncLabel": "223 JUMPDEST _function_0x8da5cb5b\n224 PUSH1 0x00\n226 DUP1\n227 SWAP1\n228 SLOAD\n229 SWAP1\n(click to expand +)"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "92 JUMPDEST _function_0x8da5cb5b\n93 PUSH2 0x0064\n96 PUSH2 0x00df\n99 JUMP", "id": "1136", "isExpanded": false, "label": "92 JUMPDEST _function_0x8da5cb5b\n93 PUSH2 0x0064\n96 PUSH2 0x00df\n99 JUMP", "size": 150, "truncLabel": "92 JUMPDEST _function_0x8da5cb5b\n93 PUSH2 0x0064\n96 PUSH2 0x00df\n99 JUMP"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "88 PUSH1 0x00\n90 DUP1\n91 REVERT", "id": "1139", "isExpanded": false, "label": "88 PUSH1 0x00\n90 DUP1\n91 REVERT", "size": 150, "truncLabel": "88 PUSH1 0x00\n90 DUP1\n91 REVERT"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "81 JUMPDEST _function_0x8da5cb5b\n82 CALLVALUE\n83 ISZERO\n84 PUSH2 0x005c\n87 JUMPI", "id": "1135", "isExpanded": false, "label": "81 JUMPDEST _function_0x8da5cb5b\n82 CALLVALUE\n83 ISZERO\n84 PUSH2 0x005c\n87 JUMPI", "size": 150, "truncLabel": "81 JUMPDEST _function_0x8da5cb5b\n82 CALLVALUE\n83 ISZERO\n84 PUSH2 0x005c\n87 JUMPI"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "221 JUMPDEST transferOwnership(address)\n222 STOP", "id": "1146", "isExpanded": false, "label": "221 JUMPDEST transferOwnership(address)\n222 STOP", "size": 150, "truncLabel": "221 JUMPDEST transferOwnership(address)\n222 STOP"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "470 JUMPDEST transferOwnership(address)\n471 POP\n472 JUMP", "id": "1145", "isExpanded": false, "label": "470 JUMPDEST transferOwnership(address)\n471 POP\n472 JUMP", "size": 150, "truncLabel": "470 JUMPDEST transferOwnership(address)\n471 POP\n472 JUMP"}, {"color": {"background": "#2f7e5b", "border": "#26996f", "highlight": {"background": "#28a16f", "border": "#26996f"}}, "fullLabel": "221 JUMPDEST transferOwner
var edges = [{"arrows": "to", "from": "1132", "label": "Not(ULE(4, calldatasize_Unknown))", "smooth": {"type": "cubicBezier"}, "to": "1133"}, {"arrows": "to", "from": "1137", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1138"}, {"arrows": "to", "from": "1136", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1137"}, {"arrows": "to", "from": "1135", "label": "callvalue == 0", "smooth": {"type": "cubicBezier"}, "to": "1136"}, {"arrows": "to", "from": "1135", "label": "Not(callvalue == 0)", "smooth": {"type": "cubicBezier"}, "to": "1139"}, {"arrows": "to", "from": "1134", "label": "Extract(0xff, 0xe0, calldata_Unknown_0) == 0x8da5cb5b", "smooth": {"type": "cubicBezier"}, "to": "1135"}, {"arrows": "to", "from": "1145", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1146"}, {"arrows": "to", "from": "1144", "label": "Extract(0x9f, 0, calldata_Unknown_4) == 0", "smooth": {"type": "cubicBezier"}, "to": "1145"}, {"arrows": "to", "from": "1147", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1148"}, {"arrows": "to", "from": "1144", "label": "Not(Extract(0x9f, 0, calldata_Unknown_4) == 0)", "smooth": {"type": "cubicBezier"}, "to": "1147"}, {"arrows": "to", "from": "1143", "label": "Extract(0x9f, 0, origin) == Extract(0xa7, 8, storage_0)", "smooth": {"type": "cubicBezier"}, "to": "1144"}, {"arrows": "to", "from": "1143", "label": "Not(Extract(0x9f, 0, origin) == Extract(0xa7, 8, storage_0))", "smooth": {"type": "cubicBezier"}, "to": "1149"}, {"arrows": "to", "from": "1142", "label": "", "smooth": {"type": "cubicBezier"}, "to": "1143"}, {"arrows": "to", "from": "1141", "label": "callvalue == 0", "smooth": {"type": "cubicBezier"}, "to": "1142"}, {"arrows": "to", "from": "1141", "label": "Not(callvalue == 0)", "smooth": {"type": "cubicBezier"}, "to": "1150"}, {"arrows": "to", "from": "1140", "label": "Extract(0xff, 0xe0, calldata_Unknown_0) == 0xf2fde38b", "smooth": {"type": "cubicBezier"}, "to": "1141"}, {"arrows": "to", "from": "1140", "label": "Not(Extract(0xff, 0xe0, calldata_Unknown_0) == 0xf2fde38b)", "smooth": {"type": "cubicBezier"}, "to": "1151"}, {"arrows": "to", "from": "1134", "label": "Not(Extract(0xff, 0xe0, calldata_Unknown_0) == 0x8da5cb5b)", "smooth": {"type": "cubicBezier"}, "to": "1140"}, {"arrows": "to", "from": "1132", "label": "ULE(4, calldatasize_Unknown)", "smooth": {"type": "cubicBezier"}, "to": "1134"}];
</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>