mirror of https://github.com/crytic/slither
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.
388 lines
18 KiB
388 lines
18 KiB
[
|
|
[
|
|
{
|
|
"elements": [
|
|
{
|
|
"type": "function",
|
|
"name": "direct",
|
|
"source_mapping": {
|
|
"start": 162,
|
|
"length": 79,
|
|
"filename_used": "/GENERIC_PATH",
|
|
"filename_relative": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"filename_absolute": "/GENERIC_PATH",
|
|
"filename_short": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"is_dependency": false,
|
|
"lines": [
|
|
11,
|
|
12,
|
|
13
|
|
],
|
|
"starting_column": 5,
|
|
"ending_column": 6
|
|
},
|
|
"type_specific_fields": {
|
|
"parent": {
|
|
"type": "contract",
|
|
"name": "Test",
|
|
"source_mapping": {
|
|
"start": 0,
|
|
"length": 884,
|
|
"filename_used": "/GENERIC_PATH",
|
|
"filename_relative": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"filename_absolute": "/GENERIC_PATH",
|
|
"filename_short": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"is_dependency": false,
|
|
"lines": [
|
|
1,
|
|
2,
|
|
3,
|
|
4,
|
|
5,
|
|
6,
|
|
7,
|
|
8,
|
|
9,
|
|
10,
|
|
11,
|
|
12,
|
|
13,
|
|
14,
|
|
15,
|
|
16,
|
|
17,
|
|
18,
|
|
19,
|
|
20,
|
|
21,
|
|
22,
|
|
23,
|
|
24,
|
|
25,
|
|
26,
|
|
27,
|
|
28,
|
|
29,
|
|
30,
|
|
31,
|
|
32,
|
|
33,
|
|
34,
|
|
35,
|
|
36,
|
|
37,
|
|
38,
|
|
39,
|
|
40,
|
|
41
|
|
],
|
|
"starting_column": 1,
|
|
"ending_column": 2
|
|
}
|
|
},
|
|
"signature": "direct()"
|
|
}
|
|
},
|
|
{
|
|
"type": "node",
|
|
"name": "msg.sender.send(address(this).balance)",
|
|
"source_mapping": {
|
|
"start": 196,
|
|
"length": 38,
|
|
"filename_used": "/GENERIC_PATH",
|
|
"filename_relative": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"filename_absolute": "/GENERIC_PATH",
|
|
"filename_short": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"is_dependency": false,
|
|
"lines": [
|
|
12
|
|
],
|
|
"starting_column": 9,
|
|
"ending_column": 47
|
|
},
|
|
"type_specific_fields": {
|
|
"parent": {
|
|
"type": "function",
|
|
"name": "direct",
|
|
"source_mapping": {
|
|
"start": 162,
|
|
"length": 79,
|
|
"filename_used": "/GENERIC_PATH",
|
|
"filename_relative": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"filename_absolute": "/GENERIC_PATH",
|
|
"filename_short": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"is_dependency": false,
|
|
"lines": [
|
|
11,
|
|
12,
|
|
13
|
|
],
|
|
"starting_column": 5,
|
|
"ending_column": 6
|
|
},
|
|
"type_specific_fields": {
|
|
"parent": {
|
|
"type": "contract",
|
|
"name": "Test",
|
|
"source_mapping": {
|
|
"start": 0,
|
|
"length": 884,
|
|
"filename_used": "/GENERIC_PATH",
|
|
"filename_relative": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"filename_absolute": "/GENERIC_PATH",
|
|
"filename_short": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"is_dependency": false,
|
|
"lines": [
|
|
1,
|
|
2,
|
|
3,
|
|
4,
|
|
5,
|
|
6,
|
|
7,
|
|
8,
|
|
9,
|
|
10,
|
|
11,
|
|
12,
|
|
13,
|
|
14,
|
|
15,
|
|
16,
|
|
17,
|
|
18,
|
|
19,
|
|
20,
|
|
21,
|
|
22,
|
|
23,
|
|
24,
|
|
25,
|
|
26,
|
|
27,
|
|
28,
|
|
29,
|
|
30,
|
|
31,
|
|
32,
|
|
33,
|
|
34,
|
|
35,
|
|
36,
|
|
37,
|
|
38,
|
|
39,
|
|
40,
|
|
41
|
|
],
|
|
"starting_column": 1,
|
|
"ending_column": 2
|
|
}
|
|
},
|
|
"signature": "direct()"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
],
|
|
"description": "Test.direct() (tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol#11-13) sends eth to arbitrary user\n\tDangerous calls:\n\t- msg.sender.send(address(this).balance) (tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol#12)\n",
|
|
"markdown": "[Test.direct()](tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol#L11-L13) sends eth to arbitrary user\n\tDangerous calls:\n\t- [msg.sender.send(address(this).balance)](tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol#L12)\n",
|
|
"id": "f541c43a03086c95960bfcf05b8d4941008505120331df11a91d0187dc4640c5",
|
|
"check": "arbitrary-send",
|
|
"impact": "High",
|
|
"confidence": "Medium"
|
|
},
|
|
{
|
|
"elements": [
|
|
{
|
|
"type": "function",
|
|
"name": "indirect",
|
|
"source_mapping": {
|
|
"start": 316,
|
|
"length": 82,
|
|
"filename_used": "/GENERIC_PATH",
|
|
"filename_relative": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"filename_absolute": "/GENERIC_PATH",
|
|
"filename_short": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"is_dependency": false,
|
|
"lines": [
|
|
19,
|
|
20,
|
|
21
|
|
],
|
|
"starting_column": 5,
|
|
"ending_column": 6
|
|
},
|
|
"type_specific_fields": {
|
|
"parent": {
|
|
"type": "contract",
|
|
"name": "Test",
|
|
"source_mapping": {
|
|
"start": 0,
|
|
"length": 884,
|
|
"filename_used": "/GENERIC_PATH",
|
|
"filename_relative": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"filename_absolute": "/GENERIC_PATH",
|
|
"filename_short": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"is_dependency": false,
|
|
"lines": [
|
|
1,
|
|
2,
|
|
3,
|
|
4,
|
|
5,
|
|
6,
|
|
7,
|
|
8,
|
|
9,
|
|
10,
|
|
11,
|
|
12,
|
|
13,
|
|
14,
|
|
15,
|
|
16,
|
|
17,
|
|
18,
|
|
19,
|
|
20,
|
|
21,
|
|
22,
|
|
23,
|
|
24,
|
|
25,
|
|
26,
|
|
27,
|
|
28,
|
|
29,
|
|
30,
|
|
31,
|
|
32,
|
|
33,
|
|
34,
|
|
35,
|
|
36,
|
|
37,
|
|
38,
|
|
39,
|
|
40,
|
|
41
|
|
],
|
|
"starting_column": 1,
|
|
"ending_column": 2
|
|
}
|
|
},
|
|
"signature": "indirect()"
|
|
}
|
|
},
|
|
{
|
|
"type": "node",
|
|
"name": "destination.send(address(this).balance)",
|
|
"source_mapping": {
|
|
"start": 352,
|
|
"length": 39,
|
|
"filename_used": "/GENERIC_PATH",
|
|
"filename_relative": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"filename_absolute": "/GENERIC_PATH",
|
|
"filename_short": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"is_dependency": false,
|
|
"lines": [
|
|
20
|
|
],
|
|
"starting_column": 9,
|
|
"ending_column": 48
|
|
},
|
|
"type_specific_fields": {
|
|
"parent": {
|
|
"type": "function",
|
|
"name": "indirect",
|
|
"source_mapping": {
|
|
"start": 316,
|
|
"length": 82,
|
|
"filename_used": "/GENERIC_PATH",
|
|
"filename_relative": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"filename_absolute": "/GENERIC_PATH",
|
|
"filename_short": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"is_dependency": false,
|
|
"lines": [
|
|
19,
|
|
20,
|
|
21
|
|
],
|
|
"starting_column": 5,
|
|
"ending_column": 6
|
|
},
|
|
"type_specific_fields": {
|
|
"parent": {
|
|
"type": "contract",
|
|
"name": "Test",
|
|
"source_mapping": {
|
|
"start": 0,
|
|
"length": 884,
|
|
"filename_used": "/GENERIC_PATH",
|
|
"filename_relative": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"filename_absolute": "/GENERIC_PATH",
|
|
"filename_short": "tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol",
|
|
"is_dependency": false,
|
|
"lines": [
|
|
1,
|
|
2,
|
|
3,
|
|
4,
|
|
5,
|
|
6,
|
|
7,
|
|
8,
|
|
9,
|
|
10,
|
|
11,
|
|
12,
|
|
13,
|
|
14,
|
|
15,
|
|
16,
|
|
17,
|
|
18,
|
|
19,
|
|
20,
|
|
21,
|
|
22,
|
|
23,
|
|
24,
|
|
25,
|
|
26,
|
|
27,
|
|
28,
|
|
29,
|
|
30,
|
|
31,
|
|
32,
|
|
33,
|
|
34,
|
|
35,
|
|
36,
|
|
37,
|
|
38,
|
|
39,
|
|
40,
|
|
41
|
|
],
|
|
"starting_column": 1,
|
|
"ending_column": 2
|
|
}
|
|
},
|
|
"signature": "indirect()"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
],
|
|
"description": "Test.indirect() (tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol#19-21) sends eth to arbitrary user\n\tDangerous calls:\n\t- destination.send(address(this).balance) (tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol#20)\n",
|
|
"markdown": "[Test.indirect()](tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol#L19-L21) sends eth to arbitrary user\n\tDangerous calls:\n\t- [destination.send(address(this).balance)](tests/detectors/arbitrary-send/arbitrary_send-0.5.1.sol#L20)\n",
|
|
"id": "6399c3b0638ef3e8fb62de3d7ad760649d315b03ebdf5a11d2674970f12452d9",
|
|
"check": "arbitrary-send",
|
|
"impact": "High",
|
|
"confidence": "Medium"
|
|
}
|
|
]
|
|
] |