Static Analyzer for Solidity
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.
 
 
 
 
slither/tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol.0.4.2...

4814 lines
235 KiB

[
[
{
"elements": [
{
"type": "function",
"name": "bad5",
"source_mapping": {
"start": 1137,
"length": 128,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
53,
54,
55,
56,
57
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad5(address)"
}
},
{
"type": "node",
"name": "ethSender(address(0))",
"source_mapping": {
"start": 1184,
"length": 21,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
54
],
"starting_column": 9,
"ending_column": 30
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad5",
"source_mapping": {
"start": 1137,
"length": 128,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
53,
54,
55,
56,
57
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad5(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls"
}
},
{
"type": "node",
"name": "address(target).call.value(1)()",
"source_mapping": {
"start": 1417,
"length": 31,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
64
],
"starting_column": 9,
"ending_column": 40
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "ethSender",
"source_mapping": {
"start": 1364,
"length": 91,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
63,
64,
65
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "ethSender(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "varChanger()",
"source_mapping": {
"start": 1215,
"length": 12,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
55
],
"starting_column": 9,
"ending_column": 21
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad5",
"source_mapping": {
"start": 1137,
"length": 128,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
53,
54,
55,
56,
57
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad5(address)"
}
}
},
"additional_fields": {
"underlying_type": "variables_written",
"variable_name": "anotherVariableToChange"
}
},
{
"type": "node",
"name": "anotherVariableToChange ++",
"source_mapping": {
"start": 1501,
"length": 25,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
68
],
"starting_column": 9,
"ending_column": 34
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "varChanger",
"source_mapping": {
"start": 1461,
"length": 72,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
67,
68,
69
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "varChanger()"
}
}
},
"additional_fields": {
"underlying_type": "variables_written",
"variable_name": "anotherVariableToChange"
}
}
],
"description": "Reentrancy in ReentrancyBenign.bad5(address) (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#53-57):\n\tExternal calls:\n\t- ethSender(address(0)) (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#54)\n\t\t- address(target).call.value(1)() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#64)\n\tState variables written after the call(s):\n\t- varChanger() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#55)\n\t\t- anotherVariableToChange ++ (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#68)\n",
"markdown": "Reentrancy in [ReentrancyBenign.bad5(address)](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L53-L57):\n\tExternal calls:\n\t- [ethSender(address(0))](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L54)\n\t\t- [address(target).call.value(1)()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L64)\n\tState variables written after the call(s):\n\t- [varChanger()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L55)\n\t\t- [anotherVariableToChange ++](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L68)\n",
"first_markdown_element": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L53-L57",
"id": "254751a69c99356562e79eb0a53483ca1bcb0e9c4c847219206c665624db8a4c",
"check": "reentrancy-benign",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad0",
"source_mapping": {
"start": 322,
"length": 120,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
16,
17,
18,
19,
20,
21
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad0()"
}
},
{
"type": "node",
"name": "! (msg.sender.call())",
"source_mapping": {
"start": 359,
"length": 20,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
17
],
"starting_column": 13,
"ending_column": 33
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad0",
"source_mapping": {
"start": 322,
"length": 120,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
16,
17,
18,
19,
20,
21
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad0()"
}
}
},
"additional_fields": {
"underlying_type": "external_calls"
}
},
{
"type": "node",
"name": "! (msg.sender.call())",
"source_mapping": {
"start": 359,
"length": 20,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
17
],
"starting_column": 13,
"ending_column": 33
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad0",
"source_mapping": {
"start": 322,
"length": 120,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
16,
17,
18,
19,
20,
21
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad0()"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "counter += 1",
"source_mapping": {
"start": 423,
"length": 12,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
20
],
"starting_column": 9,
"ending_column": 21
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad0",
"source_mapping": {
"start": 322,
"length": 120,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
16,
17,
18,
19,
20,
21
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad0()"
}
}
},
"additional_fields": {
"underlying_type": "variables_written",
"variable_name": "counter"
}
}
],
"description": "Reentrancy in ReentrancyBenign.bad0() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#16-21):\n\tExternal calls:\n\t- ! (msg.sender.call()) (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#17)\n\tState variables written after the call(s):\n\t- counter += 1 (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#20)\n",
"markdown": "Reentrancy in [ReentrancyBenign.bad0()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L16-L21):\n\tExternal calls:\n\t- [! (msg.sender.call())](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L17)\n\tState variables written after the call(s):\n\t- [counter += 1](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L20)\n",
"first_markdown_element": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L16-L21",
"id": "2a39756367d068df6d24cfb010f495564ad89f8696ab2eaf9635d640412963cb",
"check": "reentrancy-benign",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad4",
"source_mapping": {
"start": 961,
"length": 170,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
46,
47,
48,
49,
50,
51
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad4(address)"
}
},
{
"type": "node",
"name": "externalCaller(target)",
"source_mapping": {
"start": 1008,
"length": 22,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
47
],
"starting_column": 9,
"ending_column": 31
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad4",
"source_mapping": {
"start": 961,
"length": 170,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
46,
47,
48,
49,
50,
51
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad4(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls"
}
},
{
"type": "node",
"name": "address(target).call()",
"source_mapping": {
"start": 1329,
"length": 22,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
60
],
"starting_column": 9,
"ending_column": 31
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "externalCaller",
"source_mapping": {
"start": 1271,
"length": 87,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
59,
60,
61
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "externalCaller(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "ethSender(address(0))",
"source_mapping": {
"start": 1040,
"length": 21,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
48
],
"starting_column": 9,
"ending_column": 30
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad4",
"source_mapping": {
"start": 961,
"length": 170,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
46,
47,
48,
49,
50,
51
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad4(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls"
}
},
{
"type": "node",
"name": "address(target).call.value(1)()",
"source_mapping": {
"start": 1417,
"length": 31,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
64
],
"starting_column": 9,
"ending_column": 40
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "ethSender",
"source_mapping": {
"start": 1364,
"length": 91,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
63,
64,
65
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "ethSender(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "externalCaller(target)",
"source_mapping": {
"start": 1008,
"length": 22,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
47
],
"starting_column": 9,
"ending_column": 31
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad4",
"source_mapping": {
"start": 961,
"length": 170,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
46,
47,
48,
49,
50,
51
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad4(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "address(target).call()",
"source_mapping": {
"start": 1329,
"length": 22,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
60
],
"starting_column": 9,
"ending_column": 31
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "externalCaller",
"source_mapping": {
"start": 1271,
"length": 87,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
59,
60,
61
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "externalCaller(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "ethSender(address(0))",
"source_mapping": {
"start": 1040,
"length": 21,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
48
],
"starting_column": 9,
"ending_column": 30
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad4",
"source_mapping": {
"start": 961,
"length": 170,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
46,
47,
48,
49,
50,
51
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad4(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "address(target).call.value(1)()",
"source_mapping": {
"start": 1417,
"length": 31,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
64
],
"starting_column": 9,
"ending_column": 40
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "ethSender",
"source_mapping": {
"start": 1364,
"length": 91,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
63,
64,
65
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "ethSender(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "varChanger()",
"source_mapping": {
"start": 1071,
"length": 12,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
49
],
"starting_column": 9,
"ending_column": 21
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad4",
"source_mapping": {
"start": 961,
"length": 170,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
46,
47,
48,
49,
50,
51
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad4(address)"
}
}
},
"additional_fields": {
"underlying_type": "variables_written",
"variable_name": "anotherVariableToChange"
}
},
{
"type": "node",
"name": "anotherVariableToChange ++",
"source_mapping": {
"start": 1501,
"length": 25,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
68
],
"starting_column": 9,
"ending_column": 34
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "varChanger",
"source_mapping": {
"start": 1461,
"length": 72,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
67,
68,
69
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "varChanger()"
}
}
},
"additional_fields": {
"underlying_type": "variables_written",
"variable_name": "anotherVariableToChange"
}
}
],
"description": "Reentrancy in ReentrancyBenign.bad4(address) (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#46-51):\n\tExternal calls:\n\t- externalCaller(target) (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#47)\n\t\t- address(target).call() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#60)\n\t- ethSender(address(0)) (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#48)\n\t\t- address(target).call.value(1)() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#64)\n\tExternal calls sending eth:\n\t- ethSender(address(0)) (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#48)\n\t\t- address(target).call.value(1)() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#64)\n\tState variables written after the call(s):\n\t- varChanger() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#49)\n\t\t- anotherVariableToChange ++ (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#68)\n",
"markdown": "Reentrancy in [ReentrancyBenign.bad4(address)](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L46-L51):\n\tExternal calls:\n\t- [externalCaller(target)](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L47)\n\t\t- [address(target).call()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L60)\n\t- [ethSender(address(0))](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L48)\n\t\t- [address(target).call.value(1)()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L64)\n\tExternal calls sending eth:\n\t- [ethSender(address(0))](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L48)\n\t\t- [address(target).call.value(1)()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L64)\n\tState variables written after the call(s):\n\t- [varChanger()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L49)\n\t\t- [anotherVariableToChange ++](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L68)\n",
"first_markdown_element": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L46-L51",
"id": "2c5b7e723892ca273cde4bf80ff3909e425d55cc6de2a2c0778c4cfed2e32e11",
"check": "reentrancy-benign",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad2",
"source_mapping": {
"start": 586,
"length": 238,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
29,
30,
31,
32,
33,
34,
35,
36,
37,
38
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad2(address)"
}
},
{
"type": "node",
"name": "success = target.call()",
"source_mapping": {
"start": 633,
"length": 30,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
30
],
"starting_column": 9,
"ending_column": 39
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad2",
"source_mapping": {
"start": 586,
"length": 238,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
29,
30,
31,
32,
33,
34,
35,
36,
37,
38
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad2(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls"
}
},
{
"type": "node",
"name": "address(target).call.value(1000)()",
"source_mapping": {
"start": 700,
"length": 34,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
32
],
"starting_column": 13,
"ending_column": 47
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad2",
"source_mapping": {
"start": 586,
"length": 238,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
29,
30,
31,
32,
33,
34,
35,
36,
37,
38
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad2(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls"
}
},
{
"type": "node",
"name": "success = target.call()",
"source_mapping": {
"start": 633,
"length": 30,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
30
],
"starting_column": 9,
"ending_column": 39
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad2",
"source_mapping": {
"start": 586,
"length": 238,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
29,
30,
31,
32,
33,
34,
35,
36,
37,
38
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad2(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "address(target).call.value(1000)()",
"source_mapping": {
"start": 700,
"length": 34,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
32
],
"starting_column": 13,
"ending_column": 47
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad2",
"source_mapping": {
"start": 586,
"length": 238,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
29,
30,
31,
32,
33,
34,
35,
36,
37,
38
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad2(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "counter += 1",
"source_mapping": {
"start": 748,
"length": 12,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
33
],
"starting_column": 13,
"ending_column": 25
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad2",
"source_mapping": {
"start": 586,
"length": 238,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
29,
30,
31,
32,
33,
34,
35,
36,
37,
38
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad2(address)"
}
}
},
"additional_fields": {
"underlying_type": "variables_written",
"variable_name": "counter"
}
}
],
"description": "Reentrancy in ReentrancyBenign.bad2(address) (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#29-38):\n\tExternal calls:\n\t- success = target.call() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#30)\n\t- address(target).call.value(1000)() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#32)\n\tExternal calls sending eth:\n\t- address(target).call.value(1000)() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#32)\n\tState variables written after the call(s):\n\t- counter += 1 (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#33)\n",
"markdown": "Reentrancy in [ReentrancyBenign.bad2(address)](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L29-L38):\n\tExternal calls:\n\t- [success = target.call()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L30)\n\t- [address(target).call.value(1000)()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L32)\n\tExternal calls sending eth:\n\t- [address(target).call.value(1000)()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L32)\n\tState variables written after the call(s):\n\t- [counter += 1](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L33)\n",
"first_markdown_element": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L29-L38",
"id": "3180ddee7a1760e704dea65602dda2c269e95d0623dd8dba90c0fa59fc983078",
"check": "reentrancy-benign",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad1",
"source_mapping": {
"start": 448,
"length": 132,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
23,
24,
25,
26,
27
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad1(address)"
}
},
{
"type": "node",
"name": "success = target.call()",
"source_mapping": {
"start": 495,
"length": 30,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
24
],
"starting_column": 9,
"ending_column": 39
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad1",
"source_mapping": {
"start": 448,
"length": 132,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
23,
24,
25,
26,
27
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad1(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls"
}
},
{
"type": "node",
"name": "success = target.call()",
"source_mapping": {
"start": 495,
"length": 30,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
24
],
"starting_column": 9,
"ending_column": 39
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad1",
"source_mapping": {
"start": 448,
"length": 132,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
23,
24,
25,
26,
27
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad1(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "counter += 1",
"source_mapping": {
"start": 561,
"length": 12,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
26
],
"starting_column": 9,
"ending_column": 21
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad1",
"source_mapping": {
"start": 448,
"length": 132,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
23,
24,
25,
26,
27
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad1(address)"
}
}
},
"additional_fields": {
"underlying_type": "variables_written",
"variable_name": "counter"
}
}
],
"description": "Reentrancy in ReentrancyBenign.bad1(address) (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#23-27):\n\tExternal calls:\n\t- success = target.call() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#24)\n\tState variables written after the call(s):\n\t- counter += 1 (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#26)\n",
"markdown": "Reentrancy in [ReentrancyBenign.bad1(address)](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L23-L27):\n\tExternal calls:\n\t- [success = target.call()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L24)\n\tState variables written after the call(s):\n\t- [counter += 1](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L26)\n",
"first_markdown_element": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L23-L27",
"id": "5fb57eb2a5139fdffbb315bf81a08464938d5f19d8b87e1c292d5be33d8ddd40",
"check": "reentrancy-benign",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad3",
"source_mapping": {
"start": 830,
"length": 125,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
40,
41,
42,
43,
44
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad3(address)"
}
},
{
"type": "node",
"name": "externalCaller(target)",
"source_mapping": {
"start": 877,
"length": 22,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
41
],
"starting_column": 9,
"ending_column": 31
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad3",
"source_mapping": {
"start": 830,
"length": 125,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
40,
41,
42,
43,
44
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad3(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls"
}
},
{
"type": "node",
"name": "address(target).call()",
"source_mapping": {
"start": 1329,
"length": 22,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
60
],
"starting_column": 9,
"ending_column": 31
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "externalCaller",
"source_mapping": {
"start": 1271,
"length": 87,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
59,
60,
61
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "externalCaller(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "externalCaller(target)",
"source_mapping": {
"start": 877,
"length": 22,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
41
],
"starting_column": 9,
"ending_column": 31
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad3",
"source_mapping": {
"start": 830,
"length": 125,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
40,
41,
42,
43,
44
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad3(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "address(target).call()",
"source_mapping": {
"start": 1329,
"length": 22,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
60
],
"starting_column": 9,
"ending_column": 31
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "externalCaller",
"source_mapping": {
"start": 1271,
"length": 87,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
59,
60,
61
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "externalCaller(address)"
}
}
},
"additional_fields": {
"underlying_type": "external_calls_sending_eth"
}
},
{
"type": "node",
"name": "varChanger()",
"source_mapping": {
"start": 909,
"length": 12,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
42
],
"starting_column": 9,
"ending_column": 21
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad3",
"source_mapping": {
"start": 830,
"length": 125,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
40,
41,
42,
43,
44
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "bad3(address)"
}
}
},
"additional_fields": {
"underlying_type": "variables_written",
"variable_name": "anotherVariableToChange"
}
},
{
"type": "node",
"name": "anotherVariableToChange ++",
"source_mapping": {
"start": 1501,
"length": 25,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
68
],
"starting_column": 9,
"ending_column": 34
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "varChanger",
"source_mapping": {
"start": 1461,
"length": 72,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
67,
68,
69
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyBenign",
"source_mapping": {
"start": 25,
"length": 1510,
"filename_relative": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol",
"is_dependency": false,
"lines": [
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,
42,
43,
44,
45,
46,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
61,
62,
63,
64,
65,
66,
67,
68,
69,
70,
71
],
"starting_column": 1,
"ending_column": 0
}
},
"signature": "varChanger()"
}
}
},
"additional_fields": {
"underlying_type": "variables_written",
"variable_name": "anotherVariableToChange"
}
}
],
"description": "Reentrancy in ReentrancyBenign.bad3(address) (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#40-44):\n\tExternal calls:\n\t- externalCaller(target) (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#41)\n\t\t- address(target).call() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#60)\n\tState variables written after the call(s):\n\t- varChanger() (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#42)\n\t\t- anotherVariableToChange ++ (tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#68)\n",
"markdown": "Reentrancy in [ReentrancyBenign.bad3(address)](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L40-L44):\n\tExternal calls:\n\t- [externalCaller(target)](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L41)\n\t\t- [address(target).call()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L60)\n\tState variables written after the call(s):\n\t- [varChanger()](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L42)\n\t\t- [anotherVariableToChange ++](tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L68)\n",
"first_markdown_element": "tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol#L40-L44",
"id": "a810049262dd308ddb72c1e0ff5f221cc85389c1e0a91b3e9c1eb06264e8de75",
"check": "reentrancy-benign",
"impact": "Low",
"confidence": "Medium"
}
]
]