Sort the detectors' results by Id

This should reduce the friction when updating detectors json results
pull/1049/head
Josselin 3 years ago
parent 65383b9a13
commit 6e58e7e30b
  1. 2
      slither/detectors/abstract_detector.py
  2. 276
      tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol.0.4.25.ABIEncoderV2Array.json
  3. 276
      tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol.0.5.9.ABIEncoderV2Array.json
  4. 92
      tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol.0.4.25.ArbitrarySend.json
  5. 92
      tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol.0.7.6.ArbitrarySend.json
  6. 942
      tests/detectors/array-by-reference/0.4.25/array_by_reference.sol.0.4.25.ArrayByReference.json
  7. 942
      tests/detectors/array-by-reference/0.5.16/array_by_reference.sol.0.5.16.ArrayByReference.json
  8. 942
      tests/detectors/array-by-reference/0.6.11/array_by_reference.sol.0.6.11.ArrayByReference.json
  9. 942
      tests/detectors/array-by-reference/0.7.6/array_by_reference.sol.0.7.6.ArrayByReference.json
  10. 232
      tests/detectors/assembly/0.6.11/inline_assembly_library.sol.0.6.11.Assembly.json
  11. 232
      tests/detectors/assembly/0.7.6/inline_assembly_library.sol.0.7.6.Assembly.json
  12. 92
      tests/detectors/assert-state-change/0.4.25/assert_state_change.sol.0.4.25.AssertStateChange.json
  13. 84
      tests/detectors/assert-state-change/0.5.16/assert_state_change.sol.0.5.16.AssertStateChange.json
  14. 92
      tests/detectors/assert-state-change/0.6.11/assert_state_change.sol.0.6.11.AssertStateChange.json
  15. 92
      tests/detectors/assert-state-change/0.7.6/assert_state_change.sol.0.7.6.AssertStateChange.json
  16. 402
      tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol.0.4.25.MultipleCallsInLoop.json
  17. 378
      tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol.0.5.16.MultipleCallsInLoop.json
  18. 336
      tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol.0.6.11.MultipleCallsInLoop.json
  19. 374
      tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol.0.7.6.MultipleCallsInLoop.json
  20. 112
      tests/detectors/constable-states/0.4.25/const_state_variables.sol.0.4.25.ConstCandidateStateVars.json
  21. 112
      tests/detectors/constable-states/0.5.16/const_state_variables.sol.0.5.16.ConstCandidateStateVars.json
  22. 112
      tests/detectors/constable-states/0.6.11/const_state_variables.sol.0.6.11.ConstCandidateStateVars.json
  23. 112
      tests/detectors/constable-states/0.7.6/const_state_variables.sol.0.7.6.ConstCandidateStateVars.json
  24. 44
      tests/detectors/constant-function-state/0.4.25/constant.sol.0.4.25.ConstantFunctionsState.json
  25. 32
      tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol.0.4.25.ArrayLengthAssignment.json
  26. 32
      tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol.0.5.16.ArrayLengthAssignment.json
  27. 96
      tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol.0.4.25.ControlledDelegateCall.json
  28. 96
      tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol.0.6.11.ControlledDelegateCall.json
  29. 96
      tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol.0.7.6.ControlledDelegateCall.json
  30. 382
      tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol.0.4.25.CostlyOperationsInLoop.json
  31. 156
      tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol.0.5.16.CostlyOperationsInLoop.json
  32. 430
      tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol.0.6.11.CostlyOperationsInLoop.json
  33. 430
      tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol.0.7.6.CostlyOperationsInLoop.json
  34. 112
      tests/detectors/dead-code/0.8.0/dead-code.sol.0.8.0.DeadCode.json
  35. 112
      tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol.0.4.25.DelegatecallInLoop.json
  36. 96
      tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol.0.6.11.DelegatecallInLoop.json
  37. 112
      tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol.0.7.6.DelegatecallInLoop.json
  38. 160
      tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol.0.8.0.DelegatecallInLoop.json
  39. 52
      tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol.0.4.25.UnindexedERC20EventParameters.json
  40. 52
      tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol.0.5.16.UnindexedERC20EventParameters.json
  41. 52
      tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol.0.6.11.UnindexedERC20EventParameters.json
  42. 52
      tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol.0.7.6.UnindexedERC20EventParameters.json
  43. 108
      tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol.0.4.25.IncorrectERC20InterfaceDetection.json
  44. 108
      tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol.0.5.16.IncorrectERC20InterfaceDetection.json
  45. 108
      tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol.0.6.11.IncorrectERC20InterfaceDetection.json
  46. 108
      tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol.0.7.6.IncorrectERC20InterfaceDetection.json
  47. 166
      tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol.0.4.25.IncorrectERC721InterfaceDetection.json
  48. 166
      tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol.0.5.16.IncorrectERC721InterfaceDetection.json
  49. 162
      tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol.0.6.11.IncorrectERC721InterfaceDetection.json
  50. 162
      tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol.0.7.6.IncorrectERC721InterfaceDetection.json
  51. 84
      tests/detectors/events-access/0.4.25/missing_events_access_control.sol.0.4.25.MissingEventsAccessControl.json
  52. 136
      tests/detectors/events-access/0.5.16/missing_events_access_control.sol.0.5.16.MissingEventsAccessControl.json
  53. 92
      tests/detectors/events-access/0.6.11/missing_events_access_control.sol.0.6.11.MissingEventsAccessControl.json
  54. 84
      tests/detectors/events-access/0.7.6/missing_events_access_control.sol.0.7.6.MissingEventsAccessControl.json
  55. 92
      tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol.0.7.6.MissingEventsArithmetic.json
  56. 116
      tests/detectors/external-function/0.4.25/external_function.sol.0.4.25.ExternalFunction.json
  57. 116
      tests/detectors/external-function/0.5.16/external_function.sol.0.5.16.ExternalFunction.json
  58. 116
      tests/detectors/external-function/0.6.11/external_function.sol.0.6.11.ExternalFunction.json
  59. 116
      tests/detectors/external-function/0.7.6/external_function.sol.0.7.6.ExternalFunction.json
  60. 72
      tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol.0.4.25.FunctionInitializedState.json
  61. 72
      tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol.0.5.16.FunctionInitializedState.json
  62. 72
      tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol.0.6.11.FunctionInitializedState.json
  63. 72
      tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol.0.7.6.FunctionInitializedState.json
  64. 1838
      tests/detectors/incorrect-equality/0.4.25/incorrect_equality.sol.0.4.25.IncorrectStrictEquality.json
  65. 1986
      tests/detectors/incorrect-equality/0.5.16/incorrect_equality.sol.0.5.16.IncorrectStrictEquality.json
  66. 1502
      tests/detectors/incorrect-equality/0.6.11/incorrect_equality.sol.0.6.11.IncorrectStrictEquality.json
  67. 2104
      tests/detectors/incorrect-equality/0.7.6/incorrect_equality.sol.0.7.6.IncorrectStrictEquality.json
  68. 66
      tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol.0.4.25.ModifierDefaultDetection.json
  69. 66
      tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol.0.5.16.ModifierDefaultDetection.json
  70. 66
      tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol.0.6.11.ModifierDefaultDetection.json
  71. 66
      tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol.0.7.6.ModifierDefaultDetection.json
  72. 126
      tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol.0.4.25.IncorrectUnaryExpressionDetection.json
  73. 366
      tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol.0.4.25.MappingDeletionDetection.json
  74. 366
      tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol.0.5.16.MappingDeletionDetection.json
  75. 366
      tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol.0.7.6.MappingDeletionDetection.json
  76. 392
      tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol.0.4.25.MissingZeroAddressValidation.json
  77. 310
      tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol.0.5.16.MissingZeroAddressValidation.json
  78. 310
      tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol.0.6.11.MissingZeroAddressValidation.json
  79. 320
      tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol.0.7.6.MissingZeroAddressValidation.json
  80. 104
      tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol.0.6.11.MsgValueInLoop.json
  81. 166
      tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol.0.7.6.MsgValueInLoop.json
  82. 904
      tests/detectors/naming-convention/0.4.25/naming_convention.sol.0.4.25.NamingConvention.json
  83. 904
      tests/detectors/naming-convention/0.5.16/naming_convention.sol.0.5.16.NamingConvention.json
  84. 904
      tests/detectors/naming-convention/0.6.11/naming_convention.sol.0.6.11.NamingConvention.json
  85. 904
      tests/detectors/naming-convention/0.7.6/naming_convention.sol.0.7.6.NamingConvention.json
  86. 162
      tests/detectors/redundant-statements/0.4.25/redundant_statements.sol.0.4.25.RedundantStatements.json
  87. 162
      tests/detectors/redundant-statements/0.5.16/redundant_statements.sol.0.5.16.RedundantStatements.json
  88. 174
      tests/detectors/redundant-statements/0.6.11/redundant_statements.sol.0.6.11.RedundantStatements.json
  89. 158
      tests/detectors/redundant-statements/0.7.6/redundant_statements.sol.0.7.6.RedundantStatements.json
  90. 2048
      tests/detectors/reentrancy-benign/0.4.25/reentrancy-benign.sol.0.4.25.ReentrancyBenign.json
  91. 2246
      tests/detectors/reentrancy-benign/0.5.16/reentrancy-benign.sol.0.5.16.ReentrancyBenign.json
  92. 1116
      tests/detectors/reentrancy-benign/0.6.11/reentrancy-benign.sol.0.6.11.ReentrancyBenign.json
  93. 1738
      tests/detectors/reentrancy-benign/0.7.6/reentrancy-benign.sol.0.7.6.ReentrancyBenign.json
  94. 9576
      tests/detectors/reentrancy-eth/0.4.25/DAO.sol.0.4.25.ReentrancyEth.json
  95. 222
      tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol.0.5.16.ReentrancyEth.json
  96. 222
      tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol.0.7.6.ReentrancyEth.json
  97. 7532
      tests/detectors/reentrancy-no-eth/0.4.25/DAO.sol.0.4.25.ReentrancyReadBeforeWritten.json
  98. 356
      tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol.0.5.16.ReentrancyReadBeforeWritten.json
  99. 356
      tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol.0.7.6.ReentrancyReadBeforeWritten.json
  100. 408
      tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol.0.4.21.ReusedBaseConstructor.json
  101. Some files were not shown because too many files have changed in this diff Show More

@ -208,6 +208,8 @@ class AbstractDetector(metaclass=abc.ABCMeta):
return [r for (idx, r) in enumerate(results) if idx not in indexes_converted] return [r for (idx, r) in enumerate(results) if idx not in indexes_converted]
except ValueError: except ValueError:
self.logger.error(yellow("Malformed input. Example of valid input: 0,1,2,3")) self.logger.error(yellow("Malformed input. Example of valid input: 0,1,2,3"))
results = sorted(results, key=lambda x: x["id"])
return results return results
@property @property

@ -4,19 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad1", "name": "bad3",
"source_mapping": { "source_mapping": {
"start": 726, "start": 1076,
"length": 63, "length": 154,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
29, 39,
30, 40,
31 41
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -136,42 +136,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(A.S[3])" "signature": "bad3()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "this.bad1_external(s)", "name": "b = abi.encode(s)",
"source_mapping": { "source_mapping": {
"start": 763, "start": 1195,
"length": 21, "length": 30,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
30 40
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 26 "ending_column": 35
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1", "name": "bad3",
"source_mapping": { "source_mapping": {
"start": 726, "start": 1076,
"length": 63, "length": 154,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
29, 39,
30, 40,
31 41
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -291,16 +291,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(A.S[3])" "signature": "bad3()"
} }
} }
} }
} }
], ],
"description": "Function A.bad1(A.S[3]) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#29-31) trigger an abi encoding bug:\n\t- this.bad1_external(s) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#30)\n", "description": "Function A.bad3() (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#39-41) trigger an abi encoding bug:\n\t- b = abi.encode(s) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#40)\n",
"markdown": "Function [A.bad1(A.S[3])](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L29-L31) trigger an abi encoding bug:\n\t- [this.bad1_external(s)](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L30)\n", "markdown": "Function [A.bad3()](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L39-L41) trigger an abi encoding bug:\n\t- [b = abi.encode(s)](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L40)\n",
"first_markdown_element": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L29-L31", "first_markdown_element": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L39-L41",
"id": "3febdd98f71332c80290c9557c5ef89ea9dbea4f520a084b0307f21b00da5010", "id": "0c50cf7f7b16d965ef04035beb09d25f3fa1fa4afeeb079ea42f2db879e8f1e9",
"check": "abiencoderv2-array", "check": "abiencoderv2-array",
"impact": "High", "impact": "High",
"confidence": "High" "confidence": "High"
@ -309,19 +309,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad4",
"source_mapping": { "source_mapping": {
"start": 852, "start": 1296,
"length": 160, "length": 148,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
34, 44,
35, 45,
36 46
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -441,42 +441,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad4()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "b = abi.encode(bad_arr)", "name": "event1_bad(bad_arr)",
"source_mapping": { "source_mapping": {
"start": 971, "start": 1415,
"length": 36, "length": 24,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
35 45
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 41 "ending_column": 29
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad4",
"source_mapping": { "source_mapping": {
"start": 852, "start": 1296,
"length": 160, "length": 148,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
34, 44,
35, 45,
36 46
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -596,16 +596,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad4()"
} }
} }
} }
} }
], ],
"description": "Function A.bad2() (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#34-36) trigger an abi encoding bug:\n\t- b = abi.encode(bad_arr) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#35)\n", "description": "Function A.bad4() (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#44-46) trigger an abi encoding bug:\n\t- event1_bad(bad_arr) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#45)\n",
"markdown": "Function [A.bad2()](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L34-L36) trigger an abi encoding bug:\n\t- [b = abi.encode(bad_arr)](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L35)\n", "markdown": "Function [A.bad4()](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L44-L46) trigger an abi encoding bug:\n\t- [event1_bad(bad_arr)](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L45)\n",
"first_markdown_element": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L34-L36", "first_markdown_element": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L44-L46",
"id": "d5860309d331920d1e3f44508fea706df75a4a7c2e93666ca96ca00ef32d7e01", "id": "144c77aebb4037fe38c2864892ecb888a4fb7d5e92e321e664b2d2226658a166",
"check": "abiencoderv2-array", "check": "abiencoderv2-array",
"impact": "High", "impact": "High",
"confidence": "High" "confidence": "High"
@ -614,19 +614,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad3", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 1076, "start": 540,
"length": 154, "length": 61,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
39, 21,
40, 22,
41 23
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -746,42 +746,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3()" "signature": "bad0()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "b = abi.encode(s)", "name": "this.bad0_external(bad_arr)",
"source_mapping": { "source_mapping": {
"start": 1195, "start": 569,
"length": 30, "length": 27,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
40 22
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 35 "ending_column": 32
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 1076, "start": 540,
"length": 154, "length": 61,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
39, 21,
40, 22,
41 23
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -901,16 +901,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3()" "signature": "bad0()"
} }
} }
} }
} }
], ],
"description": "Function A.bad3() (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#39-41) trigger an abi encoding bug:\n\t- b = abi.encode(s) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#40)\n", "description": "Function A.bad0() (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#21-23) trigger an abi encoding bug:\n\t- this.bad0_external(bad_arr) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#22)\n",
"markdown": "Function [A.bad3()](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L39-L41) trigger an abi encoding bug:\n\t- [b = abi.encode(s)](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L40)\n", "markdown": "Function [A.bad0()](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L21-L23) trigger an abi encoding bug:\n\t- [this.bad0_external(bad_arr)](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L22)\n",
"first_markdown_element": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L39-L41", "first_markdown_element": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L21-L23",
"id": "0c50cf7f7b16d965ef04035beb09d25f3fa1fa4afeeb079ea42f2db879e8f1e9", "id": "3752da45df0ba78cc9ac01a10b398e4ad74e6ddd572764cf2f361e523a43a998",
"check": "abiencoderv2-array", "check": "abiencoderv2-array",
"impact": "High", "impact": "High",
"confidence": "High" "confidence": "High"
@ -919,19 +919,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 540, "start": 726,
"length": 61, "length": 63,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
21, 29,
22, 30,
23 31
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1051,42 +1051,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad1(A.S[3])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "this.bad0_external(bad_arr)", "name": "this.bad1_external(s)",
"source_mapping": { "source_mapping": {
"start": 569, "start": 763,
"length": 27, "length": 21,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
22 30
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 32 "ending_column": 26
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 540, "start": 726,
"length": 61, "length": 63,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
21, 29,
22, 30,
23 31
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1206,16 +1206,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad1(A.S[3])"
} }
} }
} }
} }
], ],
"description": "Function A.bad0() (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#21-23) trigger an abi encoding bug:\n\t- this.bad0_external(bad_arr) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#22)\n", "description": "Function A.bad1(A.S[3]) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#29-31) trigger an abi encoding bug:\n\t- this.bad1_external(s) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#30)\n",
"markdown": "Function [A.bad0()](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L21-L23) trigger an abi encoding bug:\n\t- [this.bad0_external(bad_arr)](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L22)\n", "markdown": "Function [A.bad1(A.S[3])](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L29-L31) trigger an abi encoding bug:\n\t- [this.bad1_external(s)](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L30)\n",
"first_markdown_element": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L21-L23", "first_markdown_element": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L29-L31",
"id": "3752da45df0ba78cc9ac01a10b398e4ad74e6ddd572764cf2f361e523a43a998", "id": "3febdd98f71332c80290c9557c5ef89ea9dbea4f520a084b0307f21b00da5010",
"check": "abiencoderv2-array", "check": "abiencoderv2-array",
"impact": "High", "impact": "High",
"confidence": "High" "confidence": "High"
@ -1224,19 +1224,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad5", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 1511, "start": 852,
"length": 142, "length": 160,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
49, 34,
50, 35,
51 36
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1356,42 +1356,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad5()" "signature": "bad2()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "event2_bad(s)", "name": "b = abi.encode(bad_arr)",
"source_mapping": { "source_mapping": {
"start": 1630, "start": 971,
"length": 18, "length": 36,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
50 35
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 23 "ending_column": 41
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad5", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 1511, "start": 852,
"length": 142, "length": 160,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
49, 34,
50, 35,
51 36
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1511,16 +1511,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad5()" "signature": "bad2()"
} }
} }
} }
} }
], ],
"description": "Function A.bad5() (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#49-51) trigger an abi encoding bug:\n\t- event2_bad(s) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#50)\n", "description": "Function A.bad2() (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#34-36) trigger an abi encoding bug:\n\t- b = abi.encode(bad_arr) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#35)\n",
"markdown": "Function [A.bad5()](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L49-L51) trigger an abi encoding bug:\n\t- [event2_bad(s)](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L50)\n", "markdown": "Function [A.bad2()](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L34-L36) trigger an abi encoding bug:\n\t- [b = abi.encode(bad_arr)](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L35)\n",
"first_markdown_element": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L49-L51", "first_markdown_element": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L34-L36",
"id": "e77767c95f4548636027a859ca0c63402cfb50af242f116dd3cfc5b038a4128e", "id": "d5860309d331920d1e3f44508fea706df75a4a7c2e93666ca96ca00ef32d7e01",
"check": "abiencoderv2-array", "check": "abiencoderv2-array",
"impact": "High", "impact": "High",
"confidence": "High" "confidence": "High"
@ -1529,19 +1529,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad4", "name": "bad5",
"source_mapping": { "source_mapping": {
"start": 1296, "start": 1511,
"length": 148, "length": 142,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
44, 49,
45, 50,
46 51
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1661,42 +1661,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad4()" "signature": "bad5()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "event1_bad(bad_arr)", "name": "event2_bad(s)",
"source_mapping": { "source_mapping": {
"start": 1415, "start": 1630,
"length": 24, "length": 18,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
45 50
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 29 "ending_column": 23
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad4", "name": "bad5",
"source_mapping": { "source_mapping": {
"start": 1296, "start": 1511,
"length": 148, "length": 142,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
44, 49,
45, 50,
46 51
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1816,16 +1816,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad4()" "signature": "bad5()"
} }
} }
} }
} }
], ],
"description": "Function A.bad4() (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#44-46) trigger an abi encoding bug:\n\t- event1_bad(bad_arr) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#45)\n", "description": "Function A.bad5() (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#49-51) trigger an abi encoding bug:\n\t- event2_bad(s) (tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#50)\n",
"markdown": "Function [A.bad4()](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L44-L46) trigger an abi encoding bug:\n\t- [event1_bad(bad_arr)](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L45)\n", "markdown": "Function [A.bad5()](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L49-L51) trigger an abi encoding bug:\n\t- [event2_bad(s)](tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L50)\n",
"first_markdown_element": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L44-L46", "first_markdown_element": "tests/detectors/abiencoderv2-array/0.4.25/storage_ABIEncoderV2_array.sol#L49-L51",
"id": "144c77aebb4037fe38c2864892ecb888a4fb7d5e92e321e664b2d2226658a166", "id": "e77767c95f4548636027a859ca0c63402cfb50af242f116dd3cfc5b038a4128e",
"check": "abiencoderv2-array", "check": "abiencoderv2-array",
"impact": "High", "impact": "High",
"confidence": "High" "confidence": "High"

@ -4,19 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad5", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 1536, "start": 744,
"length": 142, "length": 70,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
49, 29,
50, 30,
51 31
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -136,42 +136,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad5()" "signature": "bad1(A.S[3])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "event2_bad(s)", "name": "this.bad1_external(s)",
"source_mapping": { "source_mapping": {
"start": 1655, "start": 788,
"length": 18, "length": 21,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
50 30
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 23 "ending_column": 26
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad5", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 1536, "start": 744,
"length": 142, "length": 70,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
49, 29,
50, 30,
51 31
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -291,16 +291,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad5()" "signature": "bad1(A.S[3])"
} }
} }
} }
} }
], ],
"description": "Function A.bad5() (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#49-51) trigger an abi encoding bug:\n\t- event2_bad(s) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#50)\n", "description": "Function A.bad1(A.S[3]) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#29-31) trigger an abi encoding bug:\n\t- this.bad1_external(s) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#30)\n",
"markdown": "Function [A.bad5()](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L49-L51) trigger an abi encoding bug:\n\t- [event2_bad(s)](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L50)\n", "markdown": "Function [A.bad1(A.S[3])](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L29-L31) trigger an abi encoding bug:\n\t- [this.bad1_external(s)](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L30)\n",
"first_markdown_element": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L49-L51", "first_markdown_element": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L29-L31",
"id": "9c6da636be98419174c8e81e73efc09e7b942f9cf477cf0de793fb92c88fc976", "id": "04f20a6b780d160f34e95fca8f1dc426e8d05eaf7a452340a809bdeafcb84efb",
"check": "abiencoderv2-array", "check": "abiencoderv2-array",
"impact": "High", "impact": "High",
"confidence": "High" "confidence": "High"
@ -309,19 +309,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad4", "name": "bad3",
"source_mapping": { "source_mapping": {
"start": 1321, "start": 1101,
"length": 148, "length": 154,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
44, 39,
45, 40,
46 41
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -441,42 +441,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad4()" "signature": "bad3()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "event1_bad(bad_arr)", "name": "b = abi.encode(s)",
"source_mapping": { "source_mapping": {
"start": 1440, "start": 1220,
"length": 24, "length": 30,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
45 40
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 29 "ending_column": 35
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad4", "name": "bad3",
"source_mapping": { "source_mapping": {
"start": 1321, "start": 1101,
"length": 148, "length": 154,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
44, 39,
45, 40,
46 41
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -596,16 +596,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad4()" "signature": "bad3()"
} }
} }
} }
} }
], ],
"description": "Function A.bad4() (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#44-46) trigger an abi encoding bug:\n\t- event1_bad(bad_arr) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#45)\n", "description": "Function A.bad3() (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#39-41) trigger an abi encoding bug:\n\t- b = abi.encode(s) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#40)\n",
"markdown": "Function [A.bad4()](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L44-L46) trigger an abi encoding bug:\n\t- [event1_bad(bad_arr)](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L45)\n", "markdown": "Function [A.bad3()](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L39-L41) trigger an abi encoding bug:\n\t- [b = abi.encode(s)](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L40)\n",
"first_markdown_element": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L44-L46", "first_markdown_element": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L39-L41",
"id": "6e9dfeb7f6ea7c989276fa8c5e27d71ab0f6b63ee878fb3f761dab9d07942246", "id": "37e980d8d34fcffe10d2533052de986dd57c1d45700f02234332b275b532c71d",
"check": "abiencoderv2-array", "check": "abiencoderv2-array",
"impact": "High", "impact": "High",
"confidence": "High" "confidence": "High"
@ -614,19 +614,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad1", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 744, "start": 549,
"length": 70, "length": 61,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
29, 21,
30, 22,
31 23
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -746,42 +746,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(A.S[3])" "signature": "bad0()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "this.bad1_external(s)", "name": "this.bad0_external(bad_arr)",
"source_mapping": { "source_mapping": {
"start": 788, "start": 578,
"length": 21, "length": 27,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
30 22
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 26 "ending_column": 32
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 744, "start": 549,
"length": 70, "length": 61,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
29, 21,
30, 22,
31 23
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -901,16 +901,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(A.S[3])" "signature": "bad0()"
} }
} }
} }
} }
], ],
"description": "Function A.bad1(A.S[3]) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#29-31) trigger an abi encoding bug:\n\t- this.bad1_external(s) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#30)\n", "description": "Function A.bad0() (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#21-23) trigger an abi encoding bug:\n\t- this.bad0_external(bad_arr) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#22)\n",
"markdown": "Function [A.bad1(A.S[3])](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L29-L31) trigger an abi encoding bug:\n\t- [this.bad1_external(s)](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L30)\n", "markdown": "Function [A.bad0()](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L21-L23) trigger an abi encoding bug:\n\t- [this.bad0_external(bad_arr)](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L22)\n",
"first_markdown_element": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L29-L31", "first_markdown_element": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L21-L23",
"id": "04f20a6b780d160f34e95fca8f1dc426e8d05eaf7a452340a809bdeafcb84efb", "id": "4755c0ac779753117c13ea710352c179c82da332c5be5f08ea5da28efa4c63b6",
"check": "abiencoderv2-array", "check": "abiencoderv2-array",
"impact": "High", "impact": "High",
"confidence": "High" "confidence": "High"
@ -919,19 +919,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad0", "name": "bad4",
"source_mapping": { "source_mapping": {
"start": 549, "start": 1321,
"length": 61, "length": 148,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
21, 44,
22, 45,
23 46
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1051,42 +1051,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad4()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "this.bad0_external(bad_arr)", "name": "event1_bad(bad_arr)",
"source_mapping": { "source_mapping": {
"start": 578, "start": 1440,
"length": 27, "length": 24,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
22 45
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 32 "ending_column": 29
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0", "name": "bad4",
"source_mapping": { "source_mapping": {
"start": 549, "start": 1321,
"length": 61, "length": 148,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
21, 44,
22, 45,
23 46
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1206,16 +1206,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad4()"
} }
} }
} }
} }
], ],
"description": "Function A.bad0() (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#21-23) trigger an abi encoding bug:\n\t- this.bad0_external(bad_arr) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#22)\n", "description": "Function A.bad4() (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#44-46) trigger an abi encoding bug:\n\t- event1_bad(bad_arr) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#45)\n",
"markdown": "Function [A.bad0()](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L21-L23) trigger an abi encoding bug:\n\t- [this.bad0_external(bad_arr)](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L22)\n", "markdown": "Function [A.bad4()](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L44-L46) trigger an abi encoding bug:\n\t- [event1_bad(bad_arr)](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L45)\n",
"first_markdown_element": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L21-L23", "first_markdown_element": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L44-L46",
"id": "4755c0ac779753117c13ea710352c179c82da332c5be5f08ea5da28efa4c63b6", "id": "6e9dfeb7f6ea7c989276fa8c5e27d71ab0f6b63ee878fb3f761dab9d07942246",
"check": "abiencoderv2-array", "check": "abiencoderv2-array",
"impact": "High", "impact": "High",
"confidence": "High" "confidence": "High"
@ -1224,19 +1224,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad5",
"source_mapping": { "source_mapping": {
"start": 877, "start": 1536,
"length": 160, "length": 142,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
34, 49,
35, 50,
36 51
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1356,42 +1356,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad5()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "b = abi.encode(bad_arr)", "name": "event2_bad(s)",
"source_mapping": { "source_mapping": {
"start": 996, "start": 1655,
"length": 36, "length": 18,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
35 50
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 41 "ending_column": 23
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad5",
"source_mapping": { "source_mapping": {
"start": 877, "start": 1536,
"length": 160, "length": 142,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
34, 49,
35, 50,
36 51
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1511,16 +1511,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad5()"
} }
} }
} }
} }
], ],
"description": "Function A.bad2() (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#34-36) trigger an abi encoding bug:\n\t- b = abi.encode(bad_arr) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#35)\n", "description": "Function A.bad5() (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#49-51) trigger an abi encoding bug:\n\t- event2_bad(s) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#50)\n",
"markdown": "Function [A.bad2()](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L34-L36) trigger an abi encoding bug:\n\t- [b = abi.encode(bad_arr)](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L35)\n", "markdown": "Function [A.bad5()](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L49-L51) trigger an abi encoding bug:\n\t- [event2_bad(s)](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L50)\n",
"first_markdown_element": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L34-L36", "first_markdown_element": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L49-L51",
"id": "e976cd11118a9f5aaacfe5715cef990140fd67c7a35682446aedc878b63b3b24", "id": "9c6da636be98419174c8e81e73efc09e7b942f9cf477cf0de793fb92c88fc976",
"check": "abiencoderv2-array", "check": "abiencoderv2-array",
"impact": "High", "impact": "High",
"confidence": "High" "confidence": "High"
@ -1529,19 +1529,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad3", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 1101, "start": 877,
"length": 154, "length": 160,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
39, 34,
40, 35,
41 36
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1661,42 +1661,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3()" "signature": "bad2()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "b = abi.encode(s)", "name": "b = abi.encode(bad_arr)",
"source_mapping": { "source_mapping": {
"start": 1220, "start": 996,
"length": 30, "length": 36,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
40 35
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 35 "ending_column": 41
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 1101, "start": 877,
"length": 154, "length": 160,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_relative": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol", "filename_short": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
39, 34,
40, 35,
41 36
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1816,16 +1816,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3()" "signature": "bad2()"
} }
} }
} }
} }
], ],
"description": "Function A.bad3() (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#39-41) trigger an abi encoding bug:\n\t- b = abi.encode(s) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#40)\n", "description": "Function A.bad2() (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#34-36) trigger an abi encoding bug:\n\t- b = abi.encode(bad_arr) (tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#35)\n",
"markdown": "Function [A.bad3()](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L39-L41) trigger an abi encoding bug:\n\t- [b = abi.encode(s)](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L40)\n", "markdown": "Function [A.bad2()](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L34-L36) trigger an abi encoding bug:\n\t- [b = abi.encode(bad_arr)](tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L35)\n",
"first_markdown_element": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L39-L41", "first_markdown_element": "tests/detectors/abiencoderv2-array/0.5.9/storage_ABIEncoderV2_array.sol#L34-L36",
"id": "37e980d8d34fcffe10d2533052de986dd57c1d45700f02234332b275b532c71d", "id": "e976cd11118a9f5aaacfe5715cef990140fd67c7a35682446aedc878b63b3b24",
"check": "abiencoderv2-array", "check": "abiencoderv2-array",
"impact": "High", "impact": "High",
"confidence": "High" "confidence": "High"

@ -4,19 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "direct", "name": "indirect",
"source_mapping": { "source_mapping": {
"start": 147, "start": 301,
"length": 79, "length": 82,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol", "filename_relative": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol", "filename_short": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 19,
12, 20,
13 21
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -80,42 +80,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "direct()" "signature": "indirect()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "msg.sender.send(address(this).balance)", "name": "destination.send(address(this).balance)",
"source_mapping": { "source_mapping": {
"start": 181, "start": 337,
"length": 38, "length": 39,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol", "filename_relative": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol", "filename_short": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
12 20
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 47 "ending_column": 48
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "direct", "name": "indirect",
"source_mapping": { "source_mapping": {
"start": 147, "start": 301,
"length": 79, "length": 82,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol", "filename_relative": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol", "filename_short": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 19,
12, 20,
13 21
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -179,16 +179,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "direct()" "signature": "indirect()"
} }
} }
} }
} }
], ],
"description": "Test.direct() (tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#11-13) sends eth to arbitrary user\n\tDangerous calls:\n\t- msg.sender.send(address(this).balance) (tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#12)\n", "description": "Test.indirect() (tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#19-21) sends eth to arbitrary user\n\tDangerous calls:\n\t- destination.send(address(this).balance) (tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#20)\n",
"markdown": "[Test.direct()](tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#L11-L13) sends eth to arbitrary user\n\tDangerous calls:\n\t- [msg.sender.send(address(this).balance)](tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#L12)\n", "markdown": "[Test.indirect()](tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#L19-L21) sends eth to arbitrary user\n\tDangerous calls:\n\t- [destination.send(address(this).balance)](tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#L20)\n",
"first_markdown_element": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#L11-L13", "first_markdown_element": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#L19-L21",
"id": "477cc1ab9fa3d2263400e47d09146eaed3e478f5eecf7856b59d49a2a5093a1c", "id": "4759805615df746a3d8a6c068ce885d2c18c46edf411f83ae004593958caafe7",
"check": "arbitrary-send", "check": "arbitrary-send",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -197,19 +197,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "indirect", "name": "direct",
"source_mapping": { "source_mapping": {
"start": 301, "start": 147,
"length": 82, "length": 79,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol", "filename_relative": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol", "filename_short": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 11,
20, 12,
21 13
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -273,42 +273,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "indirect()" "signature": "direct()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "destination.send(address(this).balance)", "name": "msg.sender.send(address(this).balance)",
"source_mapping": { "source_mapping": {
"start": 337, "start": 181,
"length": 39, "length": 38,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol", "filename_relative": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol", "filename_short": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 12
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 48 "ending_column": 47
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "indirect", "name": "direct",
"source_mapping": { "source_mapping": {
"start": 301, "start": 147,
"length": 82, "length": 79,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol", "filename_relative": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol", "filename_short": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 11,
20, 12,
21 13
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -372,16 +372,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "indirect()" "signature": "direct()"
} }
} }
} }
} }
], ],
"description": "Test.indirect() (tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#19-21) sends eth to arbitrary user\n\tDangerous calls:\n\t- destination.send(address(this).balance) (tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#20)\n", "description": "Test.direct() (tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#11-13) sends eth to arbitrary user\n\tDangerous calls:\n\t- msg.sender.send(address(this).balance) (tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#12)\n",
"markdown": "[Test.indirect()](tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#L19-L21) sends eth to arbitrary user\n\tDangerous calls:\n\t- [destination.send(address(this).balance)](tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#L20)\n", "markdown": "[Test.direct()](tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#L11-L13) sends eth to arbitrary user\n\tDangerous calls:\n\t- [msg.sender.send(address(this).balance)](tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#L12)\n",
"first_markdown_element": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#L19-L21", "first_markdown_element": "tests/detectors/arbitrary-send/0.4.25/arbitrary_send.sol#L11-L13",
"id": "4759805615df746a3d8a6c068ce885d2c18c46edf411f83ae004593958caafe7", "id": "477cc1ab9fa3d2263400e47d09146eaed3e478f5eecf7856b59d49a2a5093a1c",
"check": "arbitrary-send", "check": "arbitrary-send",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -4,19 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "direct", "name": "indirect",
"source_mapping": { "source_mapping": {
"start": 162, "start": 316,
"length": 79, "length": 82,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol", "filename_relative": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol", "filename_short": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 19,
12, 20,
13 21
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -80,42 +80,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "direct()" "signature": "indirect()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "msg.sender.send(address(this).balance)", "name": "destination.send(address(this).balance)",
"source_mapping": { "source_mapping": {
"start": 196, "start": 352,
"length": 38, "length": 39,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol", "filename_relative": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol", "filename_short": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
12 20
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 47 "ending_column": 48
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "direct", "name": "indirect",
"source_mapping": { "source_mapping": {
"start": 162, "start": 316,
"length": 79, "length": 82,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol", "filename_relative": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol", "filename_short": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 19,
12, 20,
13 21
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -179,16 +179,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "direct()" "signature": "indirect()"
} }
} }
} }
} }
], ],
"description": "Test.direct() (tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#11-13) sends eth to arbitrary user\n\tDangerous calls:\n\t- msg.sender.send(address(this).balance) (tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#12)\n", "description": "Test.indirect() (tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#19-21) sends eth to arbitrary user\n\tDangerous calls:\n\t- destination.send(address(this).balance) (tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#20)\n",
"markdown": "[Test.direct()](tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#L11-L13) sends eth to arbitrary user\n\tDangerous calls:\n\t- [msg.sender.send(address(this).balance)](tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#L12)\n", "markdown": "[Test.indirect()](tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#L19-L21) sends eth to arbitrary user\n\tDangerous calls:\n\t- [destination.send(address(this).balance)](tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#L20)\n",
"first_markdown_element": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#L11-L13", "first_markdown_element": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#L19-L21",
"id": "90d9178119fb586af18c2298136d7f1af4d33a9b702b94d2ca0fcdbe6ee783c6", "id": "3bf41470de6f5fec21d1da5741e7d63ee1d3b63cfd2646d697274f4495e3f1a9",
"check": "arbitrary-send", "check": "arbitrary-send",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -197,19 +197,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "indirect", "name": "direct",
"source_mapping": { "source_mapping": {
"start": 316, "start": 162,
"length": 82, "length": 79,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol", "filename_relative": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol", "filename_short": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 11,
20, 12,
21 13
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -273,42 +273,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "indirect()" "signature": "direct()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "destination.send(address(this).balance)", "name": "msg.sender.send(address(this).balance)",
"source_mapping": { "source_mapping": {
"start": 352, "start": 196,
"length": 39, "length": 38,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol", "filename_relative": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol", "filename_short": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 12
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 48 "ending_column": 47
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "indirect", "name": "direct",
"source_mapping": { "source_mapping": {
"start": 316, "start": 162,
"length": 82, "length": 79,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol", "filename_relative": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol", "filename_short": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 11,
20, 12,
21 13
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -372,16 +372,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "indirect()" "signature": "direct()"
} }
} }
} }
} }
], ],
"description": "Test.indirect() (tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#19-21) sends eth to arbitrary user\n\tDangerous calls:\n\t- destination.send(address(this).balance) (tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#20)\n", "description": "Test.direct() (tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#11-13) sends eth to arbitrary user\n\tDangerous calls:\n\t- msg.sender.send(address(this).balance) (tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#12)\n",
"markdown": "[Test.indirect()](tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#L19-L21) sends eth to arbitrary user\n\tDangerous calls:\n\t- [destination.send(address(this).balance)](tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#L20)\n", "markdown": "[Test.direct()](tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#L11-L13) sends eth to arbitrary user\n\tDangerous calls:\n\t- [msg.sender.send(address(this).balance)](tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#L12)\n",
"first_markdown_element": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#L19-L21", "first_markdown_element": "tests/detectors/arbitrary-send/0.7.6/arbitrary_send.sol#L11-L13",
"id": "3bf41470de6f5fec21d1da5741e7d63ee1d3b63cfd2646d697274f4495e3f1a9", "id": "90d9178119fb586af18c2298136d7f1af4d33a9b702b94d2ca0fcdbe6ee783c6",
"check": "arbitrary-send", "check": "arbitrary-send",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -4,23 +4,39 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "sumAsm", "name": "sumPureAsm",
"source_mapping": { "source_mapping": {
"start": 574, "start": 911,
"length": 254, "length": 761,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol", "filename_relative": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol", "filename_short": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 23,
15, 24,
16, 25,
17, 26,
18, 27,
19, 28,
20 29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -87,48 +103,82 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "sumAsm(uint256[])" "signature": "sumPureAsm(uint256[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "", "name": "",
"source_mapping": { "source_mapping": {
"start": 708, "start": 995,
"length": 104, "length": 671,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol", "filename_relative": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol", "filename_short": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16, 24,
17, 25,
18 26,
27,
28,
29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44
], ],
"starting_column": 13, "starting_column": 9,
"ending_column": 14 "ending_column": 10
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "sumAsm", "name": "sumPureAsm",
"source_mapping": { "source_mapping": {
"start": 574, "start": 911,
"length": 254, "length": 761,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol", "filename_relative": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol", "filename_short": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 23,
15, 24,
16, 25,
17, 26,
18, 27,
19, 28,
20 29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -195,16 +245,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "sumAsm(uint256[])" "signature": "sumPureAsm(uint256[])"
} }
} }
} }
} }
], ],
"description": "VectorSum.sumAsm(uint256[]) (tests/detectors/assembly/0.6.11/inline_assembly_library.sol#14-20) uses assembly\n\t- INLINE ASM (tests/detectors/assembly/0.6.11/inline_assembly_library.sol#16-18)\n", "description": "VectorSum.sumPureAsm(uint256[]) (tests/detectors/assembly/0.6.11/inline_assembly_library.sol#23-45) uses assembly\n\t- INLINE ASM (tests/detectors/assembly/0.6.11/inline_assembly_library.sol#24-44)\n",
"markdown": "[VectorSum.sumAsm(uint256[])](tests/detectors/assembly/0.6.11/inline_assembly_library.sol#L14-L20) uses assembly\n\t- [INLINE ASM](tests/detectors/assembly/0.6.11/inline_assembly_library.sol#L16-L18)\n", "markdown": "[VectorSum.sumPureAsm(uint256[])](tests/detectors/assembly/0.6.11/inline_assembly_library.sol#L23-L45) uses assembly\n\t- [INLINE ASM](tests/detectors/assembly/0.6.11/inline_assembly_library.sol#L24-L44)\n",
"first_markdown_element": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol#L14-L20", "first_markdown_element": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol#L23-L45",
"id": "a8d71513166310212c49c4edecbdf8fbc3040b1cb5b5756f0ad1971ae7d4cdb1", "id": "5964c7440a9efb78bf78544bcdc60c789e3d9dff73438108bcb07ac98d60876a",
"check": "assembly", "check": "assembly",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -213,39 +263,23 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "sumPureAsm", "name": "sumAsm",
"source_mapping": { "source_mapping": {
"start": 911, "start": 574,
"length": 761, "length": 254,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol", "filename_relative": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol", "filename_short": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 14,
24, 15,
25, 16,
26, 17,
27, 18,
28, 19,
29, 20
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -312,82 +346,48 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "sumPureAsm(uint256[])" "signature": "sumAsm(uint256[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "", "name": "",
"source_mapping": { "source_mapping": {
"start": 995, "start": 708,
"length": 671, "length": 104,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol", "filename_relative": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol", "filename_short": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
24, 16,
25, 17,
26, 18
27,
28,
29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44
], ],
"starting_column": 9, "starting_column": 13,
"ending_column": 10 "ending_column": 14
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "sumPureAsm", "name": "sumAsm",
"source_mapping": { "source_mapping": {
"start": 911, "start": 574,
"length": 761, "length": 254,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol", "filename_relative": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol", "filename_short": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 14,
24, 15,
25, 16,
26, 17,
27, 18,
28, 19,
29, 20
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -454,16 +454,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "sumPureAsm(uint256[])" "signature": "sumAsm(uint256[])"
} }
} }
} }
} }
], ],
"description": "VectorSum.sumPureAsm(uint256[]) (tests/detectors/assembly/0.6.11/inline_assembly_library.sol#23-45) uses assembly\n\t- INLINE ASM (tests/detectors/assembly/0.6.11/inline_assembly_library.sol#24-44)\n", "description": "VectorSum.sumAsm(uint256[]) (tests/detectors/assembly/0.6.11/inline_assembly_library.sol#14-20) uses assembly\n\t- INLINE ASM (tests/detectors/assembly/0.6.11/inline_assembly_library.sol#16-18)\n",
"markdown": "[VectorSum.sumPureAsm(uint256[])](tests/detectors/assembly/0.6.11/inline_assembly_library.sol#L23-L45) uses assembly\n\t- [INLINE ASM](tests/detectors/assembly/0.6.11/inline_assembly_library.sol#L24-L44)\n", "markdown": "[VectorSum.sumAsm(uint256[])](tests/detectors/assembly/0.6.11/inline_assembly_library.sol#L14-L20) uses assembly\n\t- [INLINE ASM](tests/detectors/assembly/0.6.11/inline_assembly_library.sol#L16-L18)\n",
"first_markdown_element": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol#L23-L45", "first_markdown_element": "tests/detectors/assembly/0.6.11/inline_assembly_library.sol#L14-L20",
"id": "5964c7440a9efb78bf78544bcdc60c789e3d9dff73438108bcb07ac98d60876a", "id": "a8d71513166310212c49c4edecbdf8fbc3040b1cb5b5756f0ad1971ae7d4cdb1",
"check": "assembly", "check": "assembly",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -4,23 +4,39 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "sumAsm", "name": "sumPureAsm",
"source_mapping": { "source_mapping": {
"start": 574, "start": 911,
"length": 254, "length": 761,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol", "filename_relative": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol", "filename_short": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 23,
15, 24,
16, 25,
17, 26,
18, 27,
19, 28,
20 29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -87,48 +103,82 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "sumAsm(uint256[])" "signature": "sumPureAsm(uint256[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "", "name": "",
"source_mapping": { "source_mapping": {
"start": 708, "start": 995,
"length": 104, "length": 671,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol", "filename_relative": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol", "filename_short": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16, 24,
17, 25,
18 26,
27,
28,
29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44
], ],
"starting_column": 13, "starting_column": 9,
"ending_column": 14 "ending_column": 10
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "sumAsm", "name": "sumPureAsm",
"source_mapping": { "source_mapping": {
"start": 574, "start": 911,
"length": 254, "length": 761,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol", "filename_relative": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol", "filename_short": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 23,
15, 24,
16, 25,
17, 26,
18, 27,
19, 28,
20 29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -195,16 +245,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "sumAsm(uint256[])" "signature": "sumPureAsm(uint256[])"
} }
} }
} }
} }
], ],
"description": "VectorSum.sumAsm(uint256[]) (tests/detectors/assembly/0.7.6/inline_assembly_library.sol#14-20) uses assembly\n\t- INLINE ASM (tests/detectors/assembly/0.7.6/inline_assembly_library.sol#16-18)\n", "description": "VectorSum.sumPureAsm(uint256[]) (tests/detectors/assembly/0.7.6/inline_assembly_library.sol#23-45) uses assembly\n\t- INLINE ASM (tests/detectors/assembly/0.7.6/inline_assembly_library.sol#24-44)\n",
"markdown": "[VectorSum.sumAsm(uint256[])](tests/detectors/assembly/0.7.6/inline_assembly_library.sol#L14-L20) uses assembly\n\t- [INLINE ASM](tests/detectors/assembly/0.7.6/inline_assembly_library.sol#L16-L18)\n", "markdown": "[VectorSum.sumPureAsm(uint256[])](tests/detectors/assembly/0.7.6/inline_assembly_library.sol#L23-L45) uses assembly\n\t- [INLINE ASM](tests/detectors/assembly/0.7.6/inline_assembly_library.sol#L24-L44)\n",
"first_markdown_element": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol#L14-L20", "first_markdown_element": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol#L23-L45",
"id": "a83582beb2c0460617fa82fbdfc38a050004e285749b17141b63e8051062248b", "id": "5cafb3e9d7d87c17203cf2c296eeec7de6b774b2a8d71908f8cfc9b8d916cb4b",
"check": "assembly", "check": "assembly",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -213,39 +263,23 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "sumPureAsm", "name": "sumAsm",
"source_mapping": { "source_mapping": {
"start": 911, "start": 574,
"length": 761, "length": 254,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol", "filename_relative": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol", "filename_short": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 14,
24, 15,
25, 16,
26, 17,
27, 18,
28, 19,
29, 20
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -312,82 +346,48 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "sumPureAsm(uint256[])" "signature": "sumAsm(uint256[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "", "name": "",
"source_mapping": { "source_mapping": {
"start": 995, "start": 708,
"length": 671, "length": 104,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol", "filename_relative": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol", "filename_short": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
24, 16,
25, 17,
26, 18
27,
28,
29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44
], ],
"starting_column": 9, "starting_column": 13,
"ending_column": 10 "ending_column": 14
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "sumPureAsm", "name": "sumAsm",
"source_mapping": { "source_mapping": {
"start": 911, "start": 574,
"length": 761, "length": 254,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol", "filename_relative": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol", "filename_short": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 14,
24, 15,
25, 16,
26, 17,
27, 18,
28, 19,
29, 20
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -454,16 +454,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "sumPureAsm(uint256[])" "signature": "sumAsm(uint256[])"
} }
} }
} }
} }
], ],
"description": "VectorSum.sumPureAsm(uint256[]) (tests/detectors/assembly/0.7.6/inline_assembly_library.sol#23-45) uses assembly\n\t- INLINE ASM (tests/detectors/assembly/0.7.6/inline_assembly_library.sol#24-44)\n", "description": "VectorSum.sumAsm(uint256[]) (tests/detectors/assembly/0.7.6/inline_assembly_library.sol#14-20) uses assembly\n\t- INLINE ASM (tests/detectors/assembly/0.7.6/inline_assembly_library.sol#16-18)\n",
"markdown": "[VectorSum.sumPureAsm(uint256[])](tests/detectors/assembly/0.7.6/inline_assembly_library.sol#L23-L45) uses assembly\n\t- [INLINE ASM](tests/detectors/assembly/0.7.6/inline_assembly_library.sol#L24-L44)\n", "markdown": "[VectorSum.sumAsm(uint256[])](tests/detectors/assembly/0.7.6/inline_assembly_library.sol#L14-L20) uses assembly\n\t- [INLINE ASM](tests/detectors/assembly/0.7.6/inline_assembly_library.sol#L16-L18)\n",
"first_markdown_element": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol#L23-L45", "first_markdown_element": "tests/detectors/assembly/0.7.6/inline_assembly_library.sol#L14-L20",
"id": "5cafb3e9d7d87c17203cf2c296eeec7de6b774b2a8d71908f8cfc9b8d916cb4b", "id": "a83582beb2c0460617fa82fbdfc38a050004e285749b17141b63e8051062248b",
"check": "assembly", "check": "assembly",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -4,19 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad0", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 77, "start": 398,
"length": 57, "length": 55,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6, 19,
7, 20,
8 21
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -78,42 +78,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad2()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "assert(bool)((s_a += 1) > 10)", "name": "assert(bool)(bad2_callee())",
"source_mapping": { "source_mapping": {
"start": 106, "start": 427,
"length": 23, "length": 21,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 28 "ending_column": 26
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 77, "start": 398,
"length": 57, "length": 55,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6, 19,
7, 20,
8 21
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -175,16 +175,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad2()"
} }
} }
} }
} }
], ],
"description": "A.bad0() (tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#6-8) has an assert() call which possibly changes state.\n\t-assert(bool)((s_a += 1) > 10) (tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#7)\nConsider using require() or change the invariant to not modify the state.\n", "description": "A.bad2() (tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#19-21) has an assert() call which possibly changes state.\n\t-assert(bool)(bad2_callee()) (tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#20)\nConsider using require() or change the invariant to not modify the state.\n",
"markdown": "[A.bad0()](tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#L6-L8) has an assert() call which possibly changes state.\n\t-[assert(bool)((s_a += 1) > 10)](tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#L7)\nConsider using require() or change the invariant to not modify the state.\n", "markdown": "[A.bad2()](tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#L19-L21) has an assert() call which possibly changes state.\n\t-[assert(bool)(bad2_callee())](tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#L20)\nConsider using require() or change the invariant to not modify the state.\n",
"first_markdown_element": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#L6-L8", "first_markdown_element": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#L19-L21",
"id": "a01104ede08ddc5107a2d63d851930d477642029aeef70d6cb44eb2a640b282a", "id": "47c8c39b084f8d339822d44f892cb049c1a3834f52fd48d2dcef80bac56996a3",
"check": "assert-state-change", "check": "assert-state-change",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -382,19 +382,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 398, "start": 77,
"length": 55, "length": 57,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 6,
20, 7,
21 8
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -456,42 +456,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad0()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "assert(bool)(bad2_callee())", "name": "assert(bool)((s_a += 1) > 10)",
"source_mapping": { "source_mapping": {
"start": 427, "start": 106,
"length": 21, "length": 23,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 26 "ending_column": 28
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 398, "start": 77,
"length": 55, "length": 57,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 6,
20, 7,
21 8
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -553,16 +553,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad0()"
} }
} }
} }
} }
], ],
"description": "A.bad2() (tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#19-21) has an assert() call which possibly changes state.\n\t-assert(bool)(bad2_callee()) (tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#20)\nConsider using require() or change the invariant to not modify the state.\n", "description": "A.bad0() (tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#6-8) has an assert() call which possibly changes state.\n\t-assert(bool)((s_a += 1) > 10) (tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#7)\nConsider using require() or change the invariant to not modify the state.\n",
"markdown": "[A.bad2()](tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#L19-L21) has an assert() call which possibly changes state.\n\t-[assert(bool)(bad2_callee())](tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#L20)\nConsider using require() or change the invariant to not modify the state.\n", "markdown": "[A.bad0()](tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#L6-L8) has an assert() call which possibly changes state.\n\t-[assert(bool)((s_a += 1) > 10)](tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#L7)\nConsider using require() or change the invariant to not modify the state.\n",
"first_markdown_element": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#L19-L21", "first_markdown_element": "tests/detectors/assert-state-change/0.4.25/assert_state_change.sol#L6-L8",
"id": "47c8c39b084f8d339822d44f892cb049c1a3834f52fd48d2dcef80bac56996a3", "id": "a01104ede08ddc5107a2d63d851930d477642029aeef70d6cb44eb2a640b282a",
"check": "assert-state-change", "check": "assert-state-change",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -4,19 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 77, "start": 186,
"length": 57, "length": 66,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6, 11,
7, 12,
8 13
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -78,14 +78,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad1(uint256)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "assert(bool)((s_a += 1) > 10)", "name": "assert(bool)((s_a += a) > 10)",
"source_mapping": { "source_mapping": {
"start": 106, "start": 224,
"length": 23, "length": 23,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol",
@ -93,7 +93,7 @@
"filename_short": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 12
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 28 "ending_column": 28
@ -101,19 +101,19 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 77, "start": 186,
"length": 57, "length": 66,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6, 11,
7, 12,
8 13
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -175,16 +175,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad1(uint256)"
} }
} }
} }
} }
], ],
"description": "A.bad0() (tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#6-8) has an assert() call which possibly changes state.\n\t-assert(bool)((s_a += 1) > 10) (tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#7)\nConsider using require() or change the invariant to not modify the state.\n", "description": "A.bad1(uint256) (tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#11-13) has an assert() call which possibly changes state.\n\t-assert(bool)((s_a += a) > 10) (tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#12)\nConsider using require() or change the invariant to not modify the state.\n",
"markdown": "[A.bad0()](tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#L6-L8) has an assert() call which possibly changes state.\n\t-[assert(bool)((s_a += 1) > 10)](tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#L7)\nConsider using require() or change the invariant to not modify the state.\n", "markdown": "[A.bad1(uint256)](tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#L11-L13) has an assert() call which possibly changes state.\n\t-[assert(bool)((s_a += a) > 10)](tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#L12)\nConsider using require() or change the invariant to not modify the state.\n",
"first_markdown_element": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#L6-L8", "first_markdown_element": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#L11-L13",
"id": "ed7344e23d057576887c7e524b215bd0b52464ce035f686bab51b271460e43a0", "id": "ea912d34e8adabfd2ce93ecd5723df8d2e7ebec7e66de5fc56f3304c780488b3",
"check": "assert-state-change", "check": "assert-state-change",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -193,19 +193,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad1", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 186, "start": 77,
"length": 66, "length": 57,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 6,
12, 7,
13 8
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -267,14 +267,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(uint256)" "signature": "bad0()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "assert(bool)((s_a += a) > 10)", "name": "assert(bool)((s_a += 1) > 10)",
"source_mapping": { "source_mapping": {
"start": 224, "start": 106,
"length": 23, "length": 23,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol",
@ -282,7 +282,7 @@
"filename_short": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
12 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 28 "ending_column": 28
@ -290,19 +290,19 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 186, "start": 77,
"length": 66, "length": 57,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 6,
12, 7,
13 8
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -364,16 +364,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(uint256)" "signature": "bad0()"
} }
} }
} }
} }
], ],
"description": "A.bad1(uint256) (tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#11-13) has an assert() call which possibly changes state.\n\t-assert(bool)((s_a += a) > 10) (tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#12)\nConsider using require() or change the invariant to not modify the state.\n", "description": "A.bad0() (tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#6-8) has an assert() call which possibly changes state.\n\t-assert(bool)((s_a += 1) > 10) (tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#7)\nConsider using require() or change the invariant to not modify the state.\n",
"markdown": "[A.bad1(uint256)](tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#L11-L13) has an assert() call which possibly changes state.\n\t-[assert(bool)((s_a += a) > 10)](tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#L12)\nConsider using require() or change the invariant to not modify the state.\n", "markdown": "[A.bad0()](tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#L6-L8) has an assert() call which possibly changes state.\n\t-[assert(bool)((s_a += 1) > 10)](tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#L7)\nConsider using require() or change the invariant to not modify the state.\n",
"first_markdown_element": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#L11-L13", "first_markdown_element": "tests/detectors/assert-state-change/0.5.16/assert_state_change.sol#L6-L8",
"id": "ea912d34e8adabfd2ce93ecd5723df8d2e7ebec7e66de5fc56f3304c780488b3", "id": "ed7344e23d057576887c7e524b215bd0b52464ce035f686bab51b271460e43a0",
"check": "assert-state-change", "check": "assert-state-change",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -193,19 +193,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad1", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 186, "start": 398,
"length": 66, "length": 55,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 19,
12, 20,
13 21
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -267,42 +267,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(uint256)" "signature": "bad2()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "assert(bool)((s_a += a) > 10)", "name": "assert(bool)(bad2_callee())",
"source_mapping": { "source_mapping": {
"start": 224, "start": 427,
"length": 23, "length": 21,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
12 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 28 "ending_column": 26
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 186, "start": 398,
"length": 66, "length": 55,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 19,
12, 20,
13 21
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -364,16 +364,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(uint256)" "signature": "bad2()"
} }
} }
} }
} }
], ],
"description": "A.bad1(uint256) (tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#11-13) has an assert() call which possibly changes state.\n\t-assert(bool)((s_a += a) > 10) (tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#12)\nConsider using require() or change the invariant to not modify the state.\n", "description": "A.bad2() (tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#19-21) has an assert() call which possibly changes state.\n\t-assert(bool)(bad2_callee()) (tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#20)\nConsider using require() or change the invariant to not modify the state.\n",
"markdown": "[A.bad1(uint256)](tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#L11-L13) has an assert() call which possibly changes state.\n\t-[assert(bool)((s_a += a) > 10)](tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#L12)\nConsider using require() or change the invariant to not modify the state.\n", "markdown": "[A.bad2()](tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#L19-L21) has an assert() call which possibly changes state.\n\t-[assert(bool)(bad2_callee())](tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#L20)\nConsider using require() or change the invariant to not modify the state.\n",
"first_markdown_element": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#L11-L13", "first_markdown_element": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#L19-L21",
"id": "c27ede68d9d7c6159032f3aef6bf9fa491390317da33307fa783a93c1b675bd7", "id": "6f4b2360043bf3035cc152b583d3462d8cc98e91de8577091fe3a0af569d5285",
"check": "assert-state-change", "check": "assert-state-change",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -382,19 +382,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 398, "start": 186,
"length": 55, "length": 66,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 11,
20, 12,
21 13
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -456,42 +456,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad1(uint256)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "assert(bool)(bad2_callee())", "name": "assert(bool)((s_a += a) > 10)",
"source_mapping": { "source_mapping": {
"start": 427, "start": 224,
"length": 21, "length": 23,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 12
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 26 "ending_column": 28
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 398, "start": 186,
"length": 55, "length": 66,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 11,
20, 12,
21 13
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -553,16 +553,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad1(uint256)"
} }
} }
} }
} }
], ],
"description": "A.bad2() (tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#19-21) has an assert() call which possibly changes state.\n\t-assert(bool)(bad2_callee()) (tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#20)\nConsider using require() or change the invariant to not modify the state.\n", "description": "A.bad1(uint256) (tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#11-13) has an assert() call which possibly changes state.\n\t-assert(bool)((s_a += a) > 10) (tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#12)\nConsider using require() or change the invariant to not modify the state.\n",
"markdown": "[A.bad2()](tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#L19-L21) has an assert() call which possibly changes state.\n\t-[assert(bool)(bad2_callee())](tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#L20)\nConsider using require() or change the invariant to not modify the state.\n", "markdown": "[A.bad1(uint256)](tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#L11-L13) has an assert() call which possibly changes state.\n\t-[assert(bool)((s_a += a) > 10)](tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#L12)\nConsider using require() or change the invariant to not modify the state.\n",
"first_markdown_element": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#L19-L21", "first_markdown_element": "tests/detectors/assert-state-change/0.6.11/assert_state_change.sol#L11-L13",
"id": "6f4b2360043bf3035cc152b583d3462d8cc98e91de8577091fe3a0af569d5285", "id": "c27ede68d9d7c6159032f3aef6bf9fa491390317da33307fa783a93c1b675bd7",
"check": "assert-state-change", "check": "assert-state-change",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -4,19 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad0", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 77, "start": 398,
"length": 57, "length": 55,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6, 19,
7, 20,
8 21
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -78,42 +78,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad2()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "assert(bool)((s_a += 1) > 10)", "name": "assert(bool)(bad2_callee())",
"source_mapping": { "source_mapping": {
"start": 106, "start": 427,
"length": 23, "length": 21,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 28 "ending_column": 26
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 77, "start": 398,
"length": 57, "length": 55,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6, 19,
7, 20,
8 21
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -175,16 +175,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad2()"
} }
} }
} }
} }
], ],
"description": "A.bad0() (tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#6-8) has an assert() call which possibly changes state.\n\t-assert(bool)((s_a += 1) > 10) (tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#7)\nConsider using require() or change the invariant to not modify the state.\n", "description": "A.bad2() (tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#19-21) has an assert() call which possibly changes state.\n\t-assert(bool)(bad2_callee()) (tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#20)\nConsider using require() or change the invariant to not modify the state.\n",
"markdown": "[A.bad0()](tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#L6-L8) has an assert() call which possibly changes state.\n\t-[assert(bool)((s_a += 1) > 10)](tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#L7)\nConsider using require() or change the invariant to not modify the state.\n", "markdown": "[A.bad2()](tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#L19-L21) has an assert() call which possibly changes state.\n\t-[assert(bool)(bad2_callee())](tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#L20)\nConsider using require() or change the invariant to not modify the state.\n",
"first_markdown_element": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#L6-L8", "first_markdown_element": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#L19-L21",
"id": "a710d11e5510f0eb3acb2c1ec524779253f25bf2931bce4cb9c5c048ec586b80", "id": "4b31923b05dec7d68f1bf133b986b4ec06fcc82ff3b8f0414d3ee3d623b69265",
"check": "assert-state-change", "check": "assert-state-change",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -382,19 +382,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 398, "start": 77,
"length": 55, "length": 57,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 6,
20, 7,
21 8
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -456,42 +456,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad0()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "assert(bool)(bad2_callee())", "name": "assert(bool)((s_a += 1) > 10)",
"source_mapping": { "source_mapping": {
"start": 427, "start": 106,
"length": 21, "length": 23,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 26 "ending_column": 28
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 398, "start": 77,
"length": 55, "length": 57,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol", "filename_relative": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol", "filename_short": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 6,
20, 7,
21 8
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -553,16 +553,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad0()"
} }
} }
} }
} }
], ],
"description": "A.bad2() (tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#19-21) has an assert() call which possibly changes state.\n\t-assert(bool)(bad2_callee()) (tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#20)\nConsider using require() or change the invariant to not modify the state.\n", "description": "A.bad0() (tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#6-8) has an assert() call which possibly changes state.\n\t-assert(bool)((s_a += 1) > 10) (tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#7)\nConsider using require() or change the invariant to not modify the state.\n",
"markdown": "[A.bad2()](tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#L19-L21) has an assert() call which possibly changes state.\n\t-[assert(bool)(bad2_callee())](tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#L20)\nConsider using require() or change the invariant to not modify the state.\n", "markdown": "[A.bad0()](tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#L6-L8) has an assert() call which possibly changes state.\n\t-[assert(bool)((s_a += 1) > 10)](tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#L7)\nConsider using require() or change the invariant to not modify the state.\n",
"first_markdown_element": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#L19-L21", "first_markdown_element": "tests/detectors/assert-state-change/0.7.6/assert_state_change.sol#L6-L8",
"id": "4b31923b05dec7d68f1bf133b986b4ec06fcc82ff3b8f0414d3ee3d623b69265", "id": "a710d11e5510f0eb3acb2c1ec524779253f25bf2931bce4cb9c5c048ec586b80",
"check": "assert-state-change", "check": "assert-state-change",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -1,148 +1,5 @@
[ [
[ [
{
"elements": [
{
"type": "function",
"name": "bad_base",
"source_mapping": {
"start": 173,
"length": 150,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
9,
10,
11,
12,
13
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CallInLoopBase",
"source_mapping": {
"start": 0,
"length": 325,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13,
14
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
},
{
"type": "node",
"name": "destinations_base[i].transfer(i)",
"source_mapping": {
"start": 274,
"length": 32,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
11
],
"starting_column": 13,
"ending_column": 45
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad_base",
"source_mapping": {
"start": 173,
"length": 150,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
9,
10,
11,
12,
13
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CallInLoopBase",
"source_mapping": {
"start": 0,
"length": 325,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13,
14
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
}
}
}
],
"description": "CallInLoopBase.bad_base() (tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#9-13) has external calls inside a loop: destinations_base[i].transfer(i) (tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#11)\n",
"markdown": "[CallInLoopBase.bad_base()](tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L9-L13) has external calls inside a loop: [destinations_base[i].transfer(i)](tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L11)\n",
"first_markdown_element": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L9-L13",
"id": "66e6cb3d36ce6385ebe80eb42e75cfcc0be03eee32eb49b287c75258de7433f6",
"check": "calls-loop",
"impact": "Low",
"confidence": "Medium"
},
{ {
"elements": [ "elements": [
{ {
@ -330,24 +187,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad3_internal",
"source_mapping": { "source_mapping": {
"start": 671, "start": 1074,
"length": 245, "length": 81,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
30, 45,
31, 46,
32, 47
33,
34,
35,
36,
37
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -404,47 +256,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad3_internal(address,uint256)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "destinations[i].transfer(i)", "name": "a.transfer(i)",
"source_mapping": { "source_mapping": {
"start": 872, "start": 1135,
"length": 27, "length": 13,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
35 46
], ],
"starting_column": 13, "starting_column": 9,
"ending_column": 40 "ending_column": 22
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad3_internal",
"source_mapping": { "source_mapping": {
"start": 671, "start": 1074,
"length": 245, "length": 81,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
30, 45,
31, 46,
32, 47
33,
34,
35,
36,
37
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -501,16 +348,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad3_internal(address,uint256)"
} }
} }
} }
} }
], ],
"description": "CallInLoop.bad2() (tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#30-37) has external calls inside a loop: destinations[i].transfer(i) (tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#35)\n", "description": "CallInLoop.bad3_internal(address,uint256) (tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#45-47) has external calls inside a loop: a.transfer(i) (tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#46)\n",
"markdown": "[CallInLoop.bad2()](tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L30-L37) has external calls inside a loop: [destinations[i].transfer(i)](tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L35)\n", "markdown": "[CallInLoop.bad3_internal(address,uint256)](tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L45-L47) has external calls inside a loop: [a.transfer(i)](tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L46)\n",
"first_markdown_element": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L30-L37", "first_markdown_element": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L45-L47",
"id": "bcf4888be2bdca9c6e3794ed50d3a0c4cbffe97f6cafdd8c9f6b2a940f92330d", "id": "29874ab93647beebd98e69e6e02bfb9e8d07d22d82990b77e1e33ea9d64caddc",
"check": "calls-loop", "check": "calls-loop",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -519,19 +366,167 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad3_internal", "name": "bad_base",
"source_mapping": { "source_mapping": {
"start": 1074, "start": 173,
"length": 81, "length": 150,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
45, 9,
46, 10,
47 11,
12,
13
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CallInLoopBase",
"source_mapping": {
"start": 0,
"length": 325,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13,
14
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
},
{
"type": "node",
"name": "destinations_base[i].transfer(i)",
"source_mapping": {
"start": 274,
"length": 32,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
11
],
"starting_column": 13,
"ending_column": 45
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad_base",
"source_mapping": {
"start": 173,
"length": 150,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
9,
10,
11,
12,
13
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CallInLoopBase",
"source_mapping": {
"start": 0,
"length": 325,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13,
14
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
}
}
}
],
"description": "CallInLoopBase.bad_base() (tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#9-13) has external calls inside a loop: destinations_base[i].transfer(i) (tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#11)\n",
"markdown": "[CallInLoopBase.bad_base()](tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L9-L13) has external calls inside a loop: [destinations_base[i].transfer(i)](tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L11)\n",
"first_markdown_element": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L9-L13",
"id": "66e6cb3d36ce6385ebe80eb42e75cfcc0be03eee32eb49b287c75258de7433f6",
"check": "calls-loop",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad2",
"source_mapping": {
"start": 671,
"length": 245,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
30,
31,
32,
33,
34,
35,
36,
37
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -588,42 +583,47 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_internal(address,uint256)" "signature": "bad2()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "a.transfer(i)", "name": "destinations[i].transfer(i)",
"source_mapping": { "source_mapping": {
"start": 1135, "start": 872,
"length": 13, "length": 27,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
46 35
], ],
"starting_column": 9, "starting_column": 13,
"ending_column": 22 "ending_column": 40
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_internal", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 1074, "start": 671,
"length": 81, "length": 245,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
45, 30,
46, 31,
47 32,
33,
34,
35,
36,
37
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -680,16 +680,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_internal(address,uint256)" "signature": "bad2()"
} }
} }
} }
} }
], ],
"description": "CallInLoop.bad3_internal(address,uint256) (tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#45-47) has external calls inside a loop: a.transfer(i) (tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#46)\n", "description": "CallInLoop.bad2() (tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#30-37) has external calls inside a loop: destinations[i].transfer(i) (tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#35)\n",
"markdown": "[CallInLoop.bad3_internal(address,uint256)](tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L45-L47) has external calls inside a loop: [a.transfer(i)](tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L46)\n", "markdown": "[CallInLoop.bad2()](tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L30-L37) has external calls inside a loop: [destinations[i].transfer(i)](tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L35)\n",
"first_markdown_element": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L45-L47", "first_markdown_element": "tests/detectors/calls-loop/0.4.25/multiple_calls_in_loop.sol#L30-L37",
"id": "29874ab93647beebd98e69e6e02bfb9e8d07d22d82990b77e1e33ea9d64caddc", "id": "bcf4888be2bdca9c6e3794ed50d3a0c4cbffe97f6cafdd8c9f6b2a940f92330d",
"check": "calls-loop", "check": "calls-loop",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"

@ -1,5 +1,194 @@
[ [
[ [
{
"elements": [
{
"type": "function",
"name": "bad2",
"source_mapping": {
"start": 721,
"length": 263,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
30,
31,
32,
33,
34,
35,
36,
37
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CallInLoop",
"source_mapping": {
"start": 352,
"length": 892,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
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
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad2()"
}
},
{
"type": "node",
"name": "address(uint160(destinations[i])).transfer(i)",
"source_mapping": {
"start": 922,
"length": 45,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
35
],
"starting_column": 13,
"ending_column": 58
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad2",
"source_mapping": {
"start": 721,
"length": 263,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
30,
31,
32,
33,
34,
35,
36,
37
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CallInLoop",
"source_mapping": {
"start": 352,
"length": 892,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
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
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad2()"
}
}
}
}
],
"description": "CallInLoop.bad2() (tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol#30-37) has external calls inside a loop: address(uint160(destinations[i])).transfer(i) (tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol#35)\n",
"markdown": "[CallInLoop.bad2()](tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol#L30-L37) has external calls inside a loop: [address(uint160(destinations[i])).transfer(i)](tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol#L35)\n",
"first_markdown_element": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol#L30-L37",
"id": "25c86080b32e786ebc200a68d29ce99aac3f426760b120f9bd359930a78e1e31",
"check": "calls-loop",
"impact": "Low",
"confidence": "Medium"
},
{ {
"elements": [ "elements": [
{ {
@ -326,195 +515,6 @@
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
}, },
{
"elements": [
{
"type": "function",
"name": "bad2",
"source_mapping": {
"start": 721,
"length": 263,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
30,
31,
32,
33,
34,
35,
36,
37
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CallInLoop",
"source_mapping": {
"start": 352,
"length": 892,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
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
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad2()"
}
},
{
"type": "node",
"name": "address(uint160(destinations[i])).transfer(i)",
"source_mapping": {
"start": 922,
"length": 45,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
35
],
"starting_column": 13,
"ending_column": 58
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad2",
"source_mapping": {
"start": 721,
"length": 263,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
30,
31,
32,
33,
34,
35,
36,
37
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CallInLoop",
"source_mapping": {
"start": 352,
"length": 892,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol",
"is_dependency": false,
"lines": [
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
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad2()"
}
}
}
}
],
"description": "CallInLoop.bad2() (tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol#30-37) has external calls inside a loop: address(uint160(destinations[i])).transfer(i) (tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol#35)\n",
"markdown": "[CallInLoop.bad2()](tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol#L30-L37) has external calls inside a loop: [address(uint160(destinations[i])).transfer(i)](tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol#L35)\n",
"first_markdown_element": "tests/detectors/calls-loop/0.5.16/multiple_calls_in_loop.sol#L30-L37",
"id": "25c86080b32e786ebc200a68d29ce99aac3f426760b120f9bd359930a78e1e31",
"check": "calls-loop",
"impact": "Low",
"confidence": "Medium"
},
{ {
"elements": [ "elements": [
{ {

@ -4,21 +4,24 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad_base", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 180, "start": 721,
"length": 168, "length": 263,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9, 30,
10, 31,
11, 32,
12, 33,
13 34,
35,
36,
37
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -26,73 +29,96 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "CallInLoopBase", "name": "CallInLoop",
"source_mapping": { "source_mapping": {
"start": 0, "start": 352,
"length": 350, "length": 892,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
1, 16,
2, 17,
3, 18,
4, 19,
5, 20,
6, 21,
7, 22,
8, 23,
9, 24,
10, 25,
11, 26,
12, 27,
13, 28,
14 29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45,
46,
47,
48,
49
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_base()" "signature": "bad2()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(uint160(destinations_base[i])).transfer(i)", "name": "address(uint160(destinations[i])).transfer(i)",
"source_mapping": { "source_mapping": {
"start": 281, "start": 922,
"length": 50, "length": 45,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11 35
], ],
"starting_column": 13, "starting_column": 13,
"ending_column": 63 "ending_column": 58
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad_base", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 180, "start": 721,
"length": 168, "length": 263,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9, 30,
10, 31,
11, 32,
12, 33,
13 34,
35,
36,
37
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -100,45 +126,65 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "CallInLoopBase", "name": "CallInLoop",
"source_mapping": { "source_mapping": {
"start": 0, "start": 352,
"length": 350, "length": 892,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
1, 16,
2, 17,
3, 18,
4, 19,
5, 20,
6, 21,
7, 22,
8, 23,
9, 24,
10, 25,
11, 26,
12, 27,
13, 28,
14 29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45,
46,
47,
48,
49
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_base()" "signature": "bad2()"
} }
} }
} }
} }
], ],
"description": "CallInLoopBase.bad_base() (tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#9-13) has external calls inside a loop: address(uint160(destinations_base[i])).transfer(i) (tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#11)\n", "description": "CallInLoop.bad2() (tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#30-37) has external calls inside a loop: address(uint160(destinations[i])).transfer(i) (tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#35)\n",
"markdown": "[CallInLoopBase.bad_base()](tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#L9-L13) has external calls inside a loop: [address(uint160(destinations_base[i])).transfer(i)](tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#L11)\n", "markdown": "[CallInLoop.bad2()](tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#L30-L37) has external calls inside a loop: [address(uint160(destinations[i])).transfer(i)](tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#L35)\n",
"first_markdown_element": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#L9-L13", "first_markdown_element": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#L30-L37",
"id": "676f5509699708442e5b513a2250f8e0e64781b139d2eafd86273c17528a16ce", "id": "3b1948778e97667e6e749205edf70beeac8b8db364e68da43900136e2e7f4c8b",
"check": "calls-loop", "check": "calls-loop",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -330,24 +376,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad_base",
"source_mapping": { "source_mapping": {
"start": 721, "start": 180,
"length": 263, "length": 168,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
30, 9,
31, 10,
32, 11,
33, 12,
34, 13
35,
36,
37
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -355,96 +398,73 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "CallInLoop", "name": "CallInLoopBase",
"source_mapping": { "source_mapping": {
"start": 352, "start": 0,
"length": 892, "length": 350,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16, 1,
17, 2,
18, 3,
19, 4,
20, 5,
21, 6,
22, 7,
23, 8,
24, 9,
25, 10,
26, 11,
27, 12,
28, 13,
29, 14
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45,
46,
47,
48,
49
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad_base()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(uint160(destinations[i])).transfer(i)", "name": "address(uint160(destinations_base[i])).transfer(i)",
"source_mapping": { "source_mapping": {
"start": 922, "start": 281,
"length": 45, "length": 50,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
35 11
], ],
"starting_column": 13, "starting_column": 13,
"ending_column": 58 "ending_column": 63
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad_base",
"source_mapping": { "source_mapping": {
"start": 721, "start": 180,
"length": 263, "length": 168,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
30, 9,
31, 10,
32, 11,
33, 12,
34, 13
35,
36,
37
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -452,65 +472,45 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "CallInLoop", "name": "CallInLoopBase",
"source_mapping": { "source_mapping": {
"start": 352, "start": 0,
"length": 892, "length": 350,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16, 1,
17, 2,
18, 3,
19, 4,
20, 5,
21, 6,
22, 7,
23, 8,
24, 9,
25, 10,
26, 11,
27, 12,
28, 13,
29, 14
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45,
46,
47,
48,
49
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad_base()"
} }
} }
} }
} }
], ],
"description": "CallInLoop.bad2() (tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#30-37) has external calls inside a loop: address(uint160(destinations[i])).transfer(i) (tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#35)\n", "description": "CallInLoopBase.bad_base() (tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#9-13) has external calls inside a loop: address(uint160(destinations_base[i])).transfer(i) (tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#11)\n",
"markdown": "[CallInLoop.bad2()](tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#L30-L37) has external calls inside a loop: [address(uint160(destinations[i])).transfer(i)](tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#L35)\n", "markdown": "[CallInLoopBase.bad_base()](tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#L9-L13) has external calls inside a loop: [address(uint160(destinations_base[i])).transfer(i)](tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#L11)\n",
"first_markdown_element": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#L30-L37", "first_markdown_element": "tests/detectors/calls-loop/0.6.11/multiple_calls_in_loop.sol#L9-L13",
"id": "3b1948778e97667e6e749205edf70beeac8b8db364e68da43900136e2e7f4c8b", "id": "676f5509699708442e5b513a2250f8e0e64781b139d2eafd86273c17528a16ce",
"check": "calls-loop", "check": "calls-loop",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"

@ -4,21 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad_base", "name": "bad3_internal",
"source_mapping": { "source_mapping": {
"start": 180, "start": 1142,
"length": 168, "length": 99,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9, 45,
10, 46,
11, 47
12,
13
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -26,73 +24,91 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "CallInLoopBase", "name": "CallInLoop",
"source_mapping": { "source_mapping": {
"start": 0, "start": 352,
"length": 350, "length": 892,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
1, 16,
2, 17,
3, 18,
4, 19,
5, 20,
6, 21,
7, 22,
8, 23,
9, 24,
10, 25,
11, 26,
12, 27,
13, 28,
14 29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45,
46,
47,
48,
49
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_base()" "signature": "bad3_internal(address,uint256)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(uint160(destinations_base[i])).transfer(i)", "name": "address(uint160(a)).transfer(i)",
"source_mapping": { "source_mapping": {
"start": 281, "start": 1203,
"length": 50, "length": 31,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11 46
], ],
"starting_column": 13, "starting_column": 9,
"ending_column": 63 "ending_column": 40
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad_base", "name": "bad3_internal",
"source_mapping": { "source_mapping": {
"start": 180, "start": 1142,
"length": 168, "length": 99,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9, 45,
10, 46,
11, 47
12,
13
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -100,45 +116,65 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "CallInLoopBase", "name": "CallInLoop",
"source_mapping": { "source_mapping": {
"start": 0, "start": 352,
"length": 350, "length": 892,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
1, 16,
2, 17,
3, 18,
4, 19,
5, 20,
6, 21,
7, 22,
8, 23,
9, 24,
10, 25,
11, 26,
12, 27,
13, 28,
14 29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45,
46,
47,
48,
49
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_base()" "signature": "bad3_internal(address,uint256)"
} }
} }
} }
} }
], ],
"description": "CallInLoopBase.bad_base() (tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#9-13) has external calls inside a loop: address(uint160(destinations_base[i])).transfer(i) (tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#11)\n", "description": "CallInLoop.bad3_internal(address,uint256) (tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#45-47) has external calls inside a loop: address(uint160(a)).transfer(i) (tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#46)\n",
"markdown": "[CallInLoopBase.bad_base()](tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L9-L13) has external calls inside a loop: [address(uint160(destinations_base[i])).transfer(i)](tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L11)\n", "markdown": "[CallInLoop.bad3_internal(address,uint256)](tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L45-L47) has external calls inside a loop: [address(uint160(a)).transfer(i)](tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L46)\n",
"first_markdown_element": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L9-L13", "first_markdown_element": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L45-L47",
"id": "2cb70798cc39fa47453799bd93bf9275930f21bcbfb2746e57cf2b77700b8cd8", "id": "2834a80b6dbcd04a8c58bd803038e5f03936c886067d1ee39d0a31d0bb9e88ae",
"check": "calls-loop", "check": "calls-loop",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -147,21 +183,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad", "name": "bad_base",
"source_mapping": { "source_mapping": {
"start": 562, "start": 180,
"length": 153, "length": 168,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
24, 9,
25, 10,
26, 11,
27, 12,
28 13
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -169,93 +205,73 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "CallInLoop", "name": "CallInLoopBase",
"source_mapping": { "source_mapping": {
"start": 352, "start": 0,
"length": 892, "length": 350,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16, 1,
17, 2,
18, 3,
19, 4,
20, 5,
21, 6,
22, 7,
23, 8,
24, 9,
25, 10,
26, 11,
27, 12,
28, 13,
29, 14
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45,
46,
47,
48,
49
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad()" "signature": "bad_base()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(uint160(destinations[i])).transfer(i)", "name": "address(uint160(destinations_base[i])).transfer(i)",
"source_mapping": { "source_mapping": {
"start": 653, "start": 281,
"length": 45, "length": 50,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26 11
], ],
"starting_column": 13, "starting_column": 13,
"ending_column": 58 "ending_column": 63
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad", "name": "bad_base",
"source_mapping": { "source_mapping": {
"start": 562, "start": 180,
"length": 153, "length": 168,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
24, 9,
25, 10,
26, 11,
27, 12,
28 13
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -263,65 +279,45 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "CallInLoop", "name": "CallInLoopBase",
"source_mapping": { "source_mapping": {
"start": 352, "start": 0,
"length": 892, "length": 350,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16, 1,
17, 2,
18, 3,
19, 4,
20, 5,
21, 6,
22, 7,
23, 8,
24, 9,
25, 10,
26, 11,
27, 12,
28, 13,
29, 14
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45,
46,
47,
48,
49
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad()" "signature": "bad_base()"
} }
} }
} }
} }
], ],
"description": "CallInLoop.bad() (tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#24-28) has external calls inside a loop: address(uint160(destinations[i])).transfer(i) (tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#26)\n", "description": "CallInLoopBase.bad_base() (tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#9-13) has external calls inside a loop: address(uint160(destinations_base[i])).transfer(i) (tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#11)\n",
"markdown": "[CallInLoop.bad()](tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L24-L28) has external calls inside a loop: [address(uint160(destinations[i])).transfer(i)](tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L26)\n", "markdown": "[CallInLoopBase.bad_base()](tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L9-L13) has external calls inside a loop: [address(uint160(destinations_base[i])).transfer(i)](tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L11)\n",
"first_markdown_element": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L24-L28", "first_markdown_element": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L9-L13",
"id": "f11a3c532d51a71adce3b5df738ce354d0a70ea3be928459582028cb72b5fdbd", "id": "2cb70798cc39fa47453799bd93bf9275930f21bcbfb2746e57cf2b77700b8cd8",
"check": "calls-loop", "check": "calls-loop",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -519,19 +515,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad3_internal", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 1142, "start": 562,
"length": 99, "length": 153,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
45, 24,
46, 25,
47 26,
27,
28
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -588,42 +586,44 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_internal(address,uint256)" "signature": "bad()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(uint160(a)).transfer(i)", "name": "address(uint160(destinations[i])).transfer(i)",
"source_mapping": { "source_mapping": {
"start": 1203, "start": 653,
"length": 31, "length": 45,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
46 26
], ],
"starting_column": 9, "starting_column": 13,
"ending_column": 40 "ending_column": 58
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_internal", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 1142, "start": 562,
"length": 99, "length": 153,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_relative": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol", "filename_short": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
45, 24,
46, 25,
47 26,
27,
28
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -680,16 +680,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_internal(address,uint256)" "signature": "bad()"
} }
} }
} }
} }
], ],
"description": "CallInLoop.bad3_internal(address,uint256) (tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#45-47) has external calls inside a loop: address(uint160(a)).transfer(i) (tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#46)\n", "description": "CallInLoop.bad() (tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#24-28) has external calls inside a loop: address(uint160(destinations[i])).transfer(i) (tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#26)\n",
"markdown": "[CallInLoop.bad3_internal(address,uint256)](tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L45-L47) has external calls inside a loop: [address(uint160(a)).transfer(i)](tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L46)\n", "markdown": "[CallInLoop.bad()](tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L24-L28) has external calls inside a loop: [address(uint160(destinations[i])).transfer(i)](tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L26)\n",
"first_markdown_element": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L45-L47", "first_markdown_element": "tests/detectors/calls-loop/0.7.6/multiple_calls_in_loop.sol#L24-L28",
"id": "2834a80b6dbcd04a8c58bd803038e5f03936c886067d1ee39d0a31d0bb9e88ae", "id": "f11a3c532d51a71adce3b5df738ce354d0a70ea3be928459582028cb72b5fdbd",
"check": "calls-loop", "check": "calls-loop",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"

@ -136,52 +136,48 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "text2", "name": "should_be_constant_2",
"source_mapping": { "source_mapping": {
"start": 333, "start": 841,
"length": 20, "length": 33,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.4.25/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.4.25/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.4.25/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.4.25/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 43
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 25 "ending_column": 38
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "A", "name": "MyConc",
"source_mapping": { "source_mapping": {
"start": 29, "start": 746,
"length": 441, "length": 342,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.4.25/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.4.25/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.4.25/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.4.25/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
4, 39,
5, 40,
6, 41,
7, 42,
8, 43,
9, 44,
10, 45,
11, 46,
12, 47,
13, 48,
14, 49,
15, 50,
16, 51,
17, 52
18,
19,
20,
21
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -190,10 +186,10 @@
} }
} }
], ],
"description": "A.text2 (tests/detectors/constable-states/0.4.25/const_state_variables.sol#14) should be constant\n", "description": "MyConc.should_be_constant_2 (tests/detectors/constable-states/0.4.25/const_state_variables.sol#43) should be constant\n",
"markdown": "[A.text2](tests/detectors/constable-states/0.4.25/const_state_variables.sol#L14) should be constant\n", "markdown": "[MyConc.should_be_constant_2](tests/detectors/constable-states/0.4.25/const_state_variables.sol#L43) should be constant\n",
"first_markdown_element": "tests/detectors/constable-states/0.4.25/const_state_variables.sol#L14", "first_markdown_element": "tests/detectors/constable-states/0.4.25/const_state_variables.sol#L43",
"id": "df11e6201c4558a8c5cd90b55b134b9ca8f07203b2264d3aa93bd7745e8cb4ba", "id": "9a48a4122de1a6a4774a9f1e0d4917bd0fa08f17b4af41b86ba07689e51bf711",
"check": "constable-states", "check": "constable-states",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"
@ -326,48 +322,52 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "should_be_constant_2", "name": "text2",
"source_mapping": { "source_mapping": {
"start": 841, "start": 333,
"length": 33, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.4.25/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.4.25/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.4.25/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.4.25/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
43 14
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 38 "ending_column": 25
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "MyConc", "name": "A",
"source_mapping": { "source_mapping": {
"start": 746, "start": 29,
"length": 342, "length": 441,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.4.25/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.4.25/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.4.25/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.4.25/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
39, 4,
40, 5,
41, 6,
42, 7,
43, 8,
44, 9,
45, 10,
46, 11,
47, 12,
48, 13,
49, 14,
50, 15,
51, 16,
52 17,
18,
19,
20,
21
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -376,10 +376,10 @@
} }
} }
], ],
"description": "MyConc.should_be_constant_2 (tests/detectors/constable-states/0.4.25/const_state_variables.sol#43) should be constant\n", "description": "A.text2 (tests/detectors/constable-states/0.4.25/const_state_variables.sol#14) should be constant\n",
"markdown": "[MyConc.should_be_constant_2](tests/detectors/constable-states/0.4.25/const_state_variables.sol#L43) should be constant\n", "markdown": "[A.text2](tests/detectors/constable-states/0.4.25/const_state_variables.sol#L14) should be constant\n",
"first_markdown_element": "tests/detectors/constable-states/0.4.25/const_state_variables.sol#L43", "first_markdown_element": "tests/detectors/constable-states/0.4.25/const_state_variables.sol#L14",
"id": "9a48a4122de1a6a4774a9f1e0d4917bd0fa08f17b4af41b86ba07689e51bf711", "id": "df11e6201c4558a8c5cd90b55b134b9ca8f07203b2264d3aa93bd7745e8cb4ba",
"check": "constable-states", "check": "constable-states",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"

@ -136,52 +136,48 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "text2", "name": "should_be_constant_2",
"source_mapping": { "source_mapping": {
"start": 333, "start": 841,
"length": 20, "length": 33,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.5.16/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.5.16/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.5.16/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.5.16/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 43
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 25 "ending_column": 38
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "A", "name": "MyConc",
"source_mapping": { "source_mapping": {
"start": 29, "start": 746,
"length": 441, "length": 342,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.5.16/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.5.16/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.5.16/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.5.16/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
4, 39,
5, 40,
6, 41,
7, 42,
8, 43,
9, 44,
10, 45,
11, 46,
12, 47,
13, 48,
14, 49,
15, 50,
16, 51,
17, 52
18,
19,
20,
21
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -190,10 +186,10 @@
} }
} }
], ],
"description": "A.text2 (tests/detectors/constable-states/0.5.16/const_state_variables.sol#14) should be constant\n", "description": "MyConc.should_be_constant_2 (tests/detectors/constable-states/0.5.16/const_state_variables.sol#43) should be constant\n",
"markdown": "[A.text2](tests/detectors/constable-states/0.5.16/const_state_variables.sol#L14) should be constant\n", "markdown": "[MyConc.should_be_constant_2](tests/detectors/constable-states/0.5.16/const_state_variables.sol#L43) should be constant\n",
"first_markdown_element": "tests/detectors/constable-states/0.5.16/const_state_variables.sol#L14", "first_markdown_element": "tests/detectors/constable-states/0.5.16/const_state_variables.sol#L43",
"id": "df11e6201c4558a8c5cd90b55b134b9ca8f07203b2264d3aa93bd7745e8cb4ba", "id": "9a48a4122de1a6a4774a9f1e0d4917bd0fa08f17b4af41b86ba07689e51bf711",
"check": "constable-states", "check": "constable-states",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"
@ -326,48 +322,52 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "should_be_constant_2", "name": "text2",
"source_mapping": { "source_mapping": {
"start": 841, "start": 333,
"length": 33, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.5.16/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.5.16/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.5.16/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.5.16/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
43 14
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 38 "ending_column": 25
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "MyConc", "name": "A",
"source_mapping": { "source_mapping": {
"start": 746, "start": 29,
"length": 342, "length": 441,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.5.16/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.5.16/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.5.16/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.5.16/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
39, 4,
40, 5,
41, 6,
42, 7,
43, 8,
44, 9,
45, 10,
46, 11,
47, 12,
48, 13,
49, 14,
50, 15,
51, 16,
52 17,
18,
19,
20,
21
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -376,10 +376,10 @@
} }
} }
], ],
"description": "MyConc.should_be_constant_2 (tests/detectors/constable-states/0.5.16/const_state_variables.sol#43) should be constant\n", "description": "A.text2 (tests/detectors/constable-states/0.5.16/const_state_variables.sol#14) should be constant\n",
"markdown": "[MyConc.should_be_constant_2](tests/detectors/constable-states/0.5.16/const_state_variables.sol#L43) should be constant\n", "markdown": "[A.text2](tests/detectors/constable-states/0.5.16/const_state_variables.sol#L14) should be constant\n",
"first_markdown_element": "tests/detectors/constable-states/0.5.16/const_state_variables.sol#L43", "first_markdown_element": "tests/detectors/constable-states/0.5.16/const_state_variables.sol#L14",
"id": "9a48a4122de1a6a4774a9f1e0d4917bd0fa08f17b4af41b86ba07689e51bf711", "id": "df11e6201c4558a8c5cd90b55b134b9ca8f07203b2264d3aa93bd7745e8cb4ba",
"check": "constable-states", "check": "constable-states",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"

@ -136,52 +136,48 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "text2", "name": "should_be_constant_2",
"source_mapping": { "source_mapping": {
"start": 333, "start": 841,
"length": 20, "length": 33,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.6.11/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.6.11/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.6.11/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.6.11/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 43
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 25 "ending_column": 38
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "A", "name": "MyConc",
"source_mapping": { "source_mapping": {
"start": 29, "start": 746,
"length": 441, "length": 342,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.6.11/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.6.11/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.6.11/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.6.11/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
4, 39,
5, 40,
6, 41,
7, 42,
8, 43,
9, 44,
10, 45,
11, 46,
12, 47,
13, 48,
14, 49,
15, 50,
16, 51,
17, 52
18,
19,
20,
21
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -190,10 +186,10 @@
} }
} }
], ],
"description": "A.text2 (tests/detectors/constable-states/0.6.11/const_state_variables.sol#14) should be constant\n", "description": "MyConc.should_be_constant_2 (tests/detectors/constable-states/0.6.11/const_state_variables.sol#43) should be constant\n",
"markdown": "[A.text2](tests/detectors/constable-states/0.6.11/const_state_variables.sol#L14) should be constant\n", "markdown": "[MyConc.should_be_constant_2](tests/detectors/constable-states/0.6.11/const_state_variables.sol#L43) should be constant\n",
"first_markdown_element": "tests/detectors/constable-states/0.6.11/const_state_variables.sol#L14", "first_markdown_element": "tests/detectors/constable-states/0.6.11/const_state_variables.sol#L43",
"id": "df11e6201c4558a8c5cd90b55b134b9ca8f07203b2264d3aa93bd7745e8cb4ba", "id": "9a48a4122de1a6a4774a9f1e0d4917bd0fa08f17b4af41b86ba07689e51bf711",
"check": "constable-states", "check": "constable-states",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"
@ -326,48 +322,52 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "should_be_constant_2", "name": "text2",
"source_mapping": { "source_mapping": {
"start": 841, "start": 333,
"length": 33, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.6.11/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.6.11/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.6.11/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.6.11/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
43 14
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 38 "ending_column": 25
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "MyConc", "name": "A",
"source_mapping": { "source_mapping": {
"start": 746, "start": 29,
"length": 342, "length": 441,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.6.11/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.6.11/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.6.11/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.6.11/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
39, 4,
40, 5,
41, 6,
42, 7,
43, 8,
44, 9,
45, 10,
46, 11,
47, 12,
48, 13,
49, 14,
50, 15,
51, 16,
52 17,
18,
19,
20,
21
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -376,10 +376,10 @@
} }
} }
], ],
"description": "MyConc.should_be_constant_2 (tests/detectors/constable-states/0.6.11/const_state_variables.sol#43) should be constant\n", "description": "A.text2 (tests/detectors/constable-states/0.6.11/const_state_variables.sol#14) should be constant\n",
"markdown": "[MyConc.should_be_constant_2](tests/detectors/constable-states/0.6.11/const_state_variables.sol#L43) should be constant\n", "markdown": "[A.text2](tests/detectors/constable-states/0.6.11/const_state_variables.sol#L14) should be constant\n",
"first_markdown_element": "tests/detectors/constable-states/0.6.11/const_state_variables.sol#L43", "first_markdown_element": "tests/detectors/constable-states/0.6.11/const_state_variables.sol#L14",
"id": "9a48a4122de1a6a4774a9f1e0d4917bd0fa08f17b4af41b86ba07689e51bf711", "id": "df11e6201c4558a8c5cd90b55b134b9ca8f07203b2264d3aa93bd7745e8cb4ba",
"check": "constable-states", "check": "constable-states",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"

@ -136,52 +136,48 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "text2", "name": "should_be_constant_2",
"source_mapping": { "source_mapping": {
"start": 333, "start": 841,
"length": 20, "length": 33,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.7.6/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.7.6/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.7.6/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.7.6/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 43
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 25 "ending_column": 38
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "A", "name": "MyConc",
"source_mapping": { "source_mapping": {
"start": 29, "start": 746,
"length": 441, "length": 342,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.7.6/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.7.6/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.7.6/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.7.6/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
4, 39,
5, 40,
6, 41,
7, 42,
8, 43,
9, 44,
10, 45,
11, 46,
12, 47,
13, 48,
14, 49,
15, 50,
16, 51,
17, 52
18,
19,
20,
21
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -190,10 +186,10 @@
} }
} }
], ],
"description": "A.text2 (tests/detectors/constable-states/0.7.6/const_state_variables.sol#14) should be constant\n", "description": "MyConc.should_be_constant_2 (tests/detectors/constable-states/0.7.6/const_state_variables.sol#43) should be constant\n",
"markdown": "[A.text2](tests/detectors/constable-states/0.7.6/const_state_variables.sol#L14) should be constant\n", "markdown": "[MyConc.should_be_constant_2](tests/detectors/constable-states/0.7.6/const_state_variables.sol#L43) should be constant\n",
"first_markdown_element": "tests/detectors/constable-states/0.7.6/const_state_variables.sol#L14", "first_markdown_element": "tests/detectors/constable-states/0.7.6/const_state_variables.sol#L43",
"id": "df11e6201c4558a8c5cd90b55b134b9ca8f07203b2264d3aa93bd7745e8cb4ba", "id": "9a48a4122de1a6a4774a9f1e0d4917bd0fa08f17b4af41b86ba07689e51bf711",
"check": "constable-states", "check": "constable-states",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"
@ -326,48 +322,52 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "should_be_constant_2", "name": "text2",
"source_mapping": { "source_mapping": {
"start": 841, "start": 333,
"length": 33, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.7.6/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.7.6/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.7.6/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.7.6/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
43 14
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 38 "ending_column": 25
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "MyConc", "name": "A",
"source_mapping": { "source_mapping": {
"start": 746, "start": 29,
"length": 342, "length": 441,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constable-states/0.7.6/const_state_variables.sol", "filename_relative": "tests/detectors/constable-states/0.7.6/const_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constable-states/0.7.6/const_state_variables.sol", "filename_short": "tests/detectors/constable-states/0.7.6/const_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
39, 4,
40, 5,
41, 6,
42, 7,
43, 8,
44, 9,
45, 10,
46, 11,
47, 12,
48, 13,
49, 14,
50, 15,
51, 16,
52 17,
18,
19,
20,
21
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -376,10 +376,10 @@
} }
} }
], ],
"description": "MyConc.should_be_constant_2 (tests/detectors/constable-states/0.7.6/const_state_variables.sol#43) should be constant\n", "description": "A.text2 (tests/detectors/constable-states/0.7.6/const_state_variables.sol#14) should be constant\n",
"markdown": "[MyConc.should_be_constant_2](tests/detectors/constable-states/0.7.6/const_state_variables.sol#L43) should be constant\n", "markdown": "[A.text2](tests/detectors/constable-states/0.7.6/const_state_variables.sol#L14) should be constant\n",
"first_markdown_element": "tests/detectors/constable-states/0.7.6/const_state_variables.sol#L43", "first_markdown_element": "tests/detectors/constable-states/0.7.6/const_state_variables.sol#L14",
"id": "9a48a4122de1a6a4774a9f1e0d4917bd0fa08f17b4af41b86ba07689e51bf711", "id": "df11e6201c4558a8c5cd90b55b134b9ca8f07203b2264d3aa93bd7745e8cb4ba",
"check": "constable-states", "check": "constable-states",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"

@ -4,19 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "test_view_bug", "name": "test_constant_bug",
"source_mapping": { "source_mapping": {
"start": 45, "start": 113,
"length": 58, "length": 66,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constant-function-state/0.4.25/constant.sol", "filename_relative": "tests/detectors/constant-function-state/0.4.25/constant.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constant-function-state/0.4.25/constant.sol", "filename_short": "tests/detectors/constant-function-state/0.4.25/constant.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 9,
6, 10,
7 11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -64,7 +64,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "test_view_bug()" "signature": "test_constant_bug()"
} }
}, },
{ {
@ -130,10 +130,10 @@
} }
} }
], ],
"description": "Constant.test_view_bug() (tests/detectors/constant-function-state/0.4.25/constant.sol#5-7) is declared view but changes state variables:\n\t- Constant.a (tests/detectors/constant-function-state/0.4.25/constant.sol#3)\n", "description": "Constant.test_constant_bug() (tests/detectors/constant-function-state/0.4.25/constant.sol#9-11) is declared view but changes state variables:\n\t- Constant.a (tests/detectors/constant-function-state/0.4.25/constant.sol#3)\n",
"markdown": "[Constant.test_view_bug()](tests/detectors/constant-function-state/0.4.25/constant.sol#L5-L7) is declared view but changes state variables:\n\t- [Constant.a](tests/detectors/constant-function-state/0.4.25/constant.sol#L3)\n", "markdown": "[Constant.test_constant_bug()](tests/detectors/constant-function-state/0.4.25/constant.sol#L9-L11) is declared view but changes state variables:\n\t- [Constant.a](tests/detectors/constant-function-state/0.4.25/constant.sol#L3)\n",
"first_markdown_element": "tests/detectors/constant-function-state/0.4.25/constant.sol#L5-L7", "first_markdown_element": "tests/detectors/constant-function-state/0.4.25/constant.sol#L9-L11",
"id": "4dee61d8835d20c6f1f7c195d8bd1e9de5dbcc096396a5b8db391136f9f5fdf1", "id": "145e2d34dfc5b932c8d67d480c0eaec9baa8c728e2a310529572c0c4a5c6046a",
"additional_fields": { "additional_fields": {
"contains_assembly": false "contains_assembly": false
}, },
@ -145,19 +145,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "test_constant_bug", "name": "test_view_bug",
"source_mapping": { "source_mapping": {
"start": 113, "start": 45,
"length": 66, "length": 58,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/constant-function-state/0.4.25/constant.sol", "filename_relative": "tests/detectors/constant-function-state/0.4.25/constant.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/constant-function-state/0.4.25/constant.sol", "filename_short": "tests/detectors/constant-function-state/0.4.25/constant.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9, 5,
10, 6,
11 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -205,7 +205,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "test_constant_bug()" "signature": "test_view_bug()"
} }
}, },
{ {
@ -271,10 +271,10 @@
} }
} }
], ],
"description": "Constant.test_constant_bug() (tests/detectors/constant-function-state/0.4.25/constant.sol#9-11) is declared view but changes state variables:\n\t- Constant.a (tests/detectors/constant-function-state/0.4.25/constant.sol#3)\n", "description": "Constant.test_view_bug() (tests/detectors/constant-function-state/0.4.25/constant.sol#5-7) is declared view but changes state variables:\n\t- Constant.a (tests/detectors/constant-function-state/0.4.25/constant.sol#3)\n",
"markdown": "[Constant.test_constant_bug()](tests/detectors/constant-function-state/0.4.25/constant.sol#L9-L11) is declared view but changes state variables:\n\t- [Constant.a](tests/detectors/constant-function-state/0.4.25/constant.sol#L3)\n", "markdown": "[Constant.test_view_bug()](tests/detectors/constant-function-state/0.4.25/constant.sol#L5-L7) is declared view but changes state variables:\n\t- [Constant.a](tests/detectors/constant-function-state/0.4.25/constant.sol#L3)\n",
"first_markdown_element": "tests/detectors/constant-function-state/0.4.25/constant.sol#L9-L11", "first_markdown_element": "tests/detectors/constant-function-state/0.4.25/constant.sol#L5-L7",
"id": "145e2d34dfc5b932c8d67d480c0eaec9baa8c728e2a310529572c0c4a5c6046a", "id": "4dee61d8835d20c6f1f7c195d8bd1e9de5dbcc096396a5b8db391136f9f5fdf1",
"additional_fields": { "additional_fields": {
"contains_assembly": false "contains_assembly": false
}, },

@ -268,20 +268,20 @@
}, },
{ {
"type": "node", "type": "node",
"name": "a.x.length = param", "name": "b.subStruct.x.length = param + 1",
"source_mapping": { "source_mapping": {
"start": 818, "start": 964,
"length": 18, "length": 32,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol", "filename_relative": "tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol", "filename_short": "tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
36 41
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 27 "ending_column": 41
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -394,10 +394,10 @@
} }
} }
], ],
"description": "ArrayLengthAssignment (tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#1-46) contract sets array length with a user-controlled value:\n\t- a.x.length = param (tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#36)\n", "description": "ArrayLengthAssignment (tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#1-46) contract sets array length with a user-controlled value:\n\t- b.subStruct.x.length = param + 1 (tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#41)\n",
"markdown": "[ArrayLengthAssignment](tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#L1-L46) contract sets array length with a user-controlled value:\n\t- [a.x.length = param](tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#L36)\n", "markdown": "[ArrayLengthAssignment](tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#L1-L46) contract sets array length with a user-controlled value:\n\t- [b.subStruct.x.length = param + 1](tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#L41)\n",
"first_markdown_element": "tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#L1-L46", "first_markdown_element": "tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#L1-L46",
"id": "f455c672028771f21282b59fb58b5eac51185eae4ac44e65a2e1f4df6db0c6e4", "id": "82175a5c24c40a1afe4c59f4271a2c12e577ad25e89e6e319e47b4f8f2a76943",
"check": "controlled-array-length", "check": "controlled-array-length",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -469,20 +469,20 @@
}, },
{ {
"type": "node", "type": "node",
"name": "b.subStruct.x.length = param + 1", "name": "a.x.length = param",
"source_mapping": { "source_mapping": {
"start": 964, "start": 818,
"length": 32, "length": 18,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol", "filename_relative": "tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol", "filename_short": "tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
41 36
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 41 "ending_column": 27
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -595,10 +595,10 @@
} }
} }
], ],
"description": "ArrayLengthAssignment (tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#1-46) contract sets array length with a user-controlled value:\n\t- b.subStruct.x.length = param + 1 (tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#41)\n", "description": "ArrayLengthAssignment (tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#1-46) contract sets array length with a user-controlled value:\n\t- a.x.length = param (tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#36)\n",
"markdown": "[ArrayLengthAssignment](tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#L1-L46) contract sets array length with a user-controlled value:\n\t- [b.subStruct.x.length = param + 1](tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#L41)\n", "markdown": "[ArrayLengthAssignment](tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#L1-L46) contract sets array length with a user-controlled value:\n\t- [a.x.length = param](tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#L36)\n",
"first_markdown_element": "tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#L1-L46", "first_markdown_element": "tests/detectors/controlled-array-length/0.4.25/array_length_assignment.sol#L1-L46",
"id": "82175a5c24c40a1afe4c59f4271a2c12e577ad25e89e6e319e47b4f8f2a76943", "id": "f455c672028771f21282b59fb58b5eac51185eae4ac44e65a2e1f4df6db0c6e4",
"check": "controlled-array-length", "check": "controlled-array-length",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -67,9 +67,9 @@
}, },
{ {
"type": "node", "type": "node",
"name": "arr.length = param", "name": "a.x.length = param",
"source_mapping": { "source_mapping": {
"start": 527, "start": 818,
"length": 18, "length": 18,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol", "filename_relative": "tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol",
@ -77,10 +77,10 @@
"filename_short": "tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol", "filename_short": "tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26 36
], ],
"starting_column": 13, "starting_column": 9,
"ending_column": 31 "ending_column": 27
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -193,10 +193,10 @@
} }
} }
], ],
"description": "ArrayLengthAssignment (tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#1-46) contract sets array length with a user-controlled value:\n\t- arr.length = param (tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#26)\n", "description": "ArrayLengthAssignment (tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#1-46) contract sets array length with a user-controlled value:\n\t- a.x.length = param (tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#36)\n",
"markdown": "[ArrayLengthAssignment](tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#L1-L46) contract sets array length with a user-controlled value:\n\t- [arr.length = param](tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#L26)\n", "markdown": "[ArrayLengthAssignment](tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#L1-L46) contract sets array length with a user-controlled value:\n\t- [a.x.length = param](tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#L36)\n",
"first_markdown_element": "tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#L1-L46", "first_markdown_element": "tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#L1-L46",
"id": "5120add82e5b674971638ddcd430301e4fd0ff0abc12b425d78bb09baa519dd0", "id": "3ee7c4c1f07506f88bcd3b42a86641b32b24a3978768cbcb99301bd8a1fcb975",
"check": "controlled-array-length", "check": "controlled-array-length",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -268,9 +268,9 @@
}, },
{ {
"type": "node", "type": "node",
"name": "a.x.length = param", "name": "arr.length = param",
"source_mapping": { "source_mapping": {
"start": 818, "start": 527,
"length": 18, "length": 18,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol", "filename_relative": "tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol",
@ -278,10 +278,10 @@
"filename_short": "tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol", "filename_short": "tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
36 26
], ],
"starting_column": 9, "starting_column": 13,
"ending_column": 27 "ending_column": 31
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -394,10 +394,10 @@
} }
} }
], ],
"description": "ArrayLengthAssignment (tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#1-46) contract sets array length with a user-controlled value:\n\t- a.x.length = param (tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#36)\n", "description": "ArrayLengthAssignment (tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#1-46) contract sets array length with a user-controlled value:\n\t- arr.length = param (tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#26)\n",
"markdown": "[ArrayLengthAssignment](tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#L1-L46) contract sets array length with a user-controlled value:\n\t- [a.x.length = param](tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#L36)\n", "markdown": "[ArrayLengthAssignment](tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#L1-L46) contract sets array length with a user-controlled value:\n\t- [arr.length = param](tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#L26)\n",
"first_markdown_element": "tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#L1-L46", "first_markdown_element": "tests/detectors/controlled-array-length/0.5.16/array_length_assignment.sol#L1-L46",
"id": "3ee7c4c1f07506f88bcd3b42a86641b32b24a3978768cbcb99301bd8a1fcb975", "id": "5120add82e5b674971638ddcd430301e4fd0ff0abc12b425d78bb09baa519dd0",
"check": "controlled-array-length", "check": "controlled-array-length",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -4,20 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad_delegate_call", "name": "bad_delegate_call2",
"source_mapping": { "source_mapping": {
"start": 101, "start": 337,
"length": 134, "length": 118,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8, 18,
9, 19,
10, 20
11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -65,43 +64,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_delegate_call(bytes)" "signature": "bad_delegate_call2(bytes)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr_bad.delegatecall(data)", "name": "addr_bad.delegatecall(abi.encode(func_id,data))",
"source_mapping": { "source_mapping": {
"start": 201, "start": 400,
"length": 27, "length": 48,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 19
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 36 "ending_column": 57
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad_delegate_call", "name": "bad_delegate_call2",
"source_mapping": { "source_mapping": {
"start": 101, "start": 337,
"length": 134, "length": 118,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8, 18,
9, 19,
10, 20
11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -149,16 +147,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_delegate_call(bytes)" "signature": "bad_delegate_call2(bytes)"
} }
} }
} }
} }
], ],
"description": "C.bad_delegate_call(bytes) (tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#8-11) uses delegatecall to a input-controlled function id\n\t- addr_bad.delegatecall(data) (tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#10)\n", "description": "C.bad_delegate_call2(bytes) (tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#18-20) uses delegatecall to a input-controlled function id\n\t- addr_bad.delegatecall(abi.encode(func_id,data)) (tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#19)\n",
"markdown": "[C.bad_delegate_call(bytes)](tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#L8-L11) uses delegatecall to a input-controlled function id\n\t- [addr_bad.delegatecall(data)](tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#L10)\n", "markdown": "[C.bad_delegate_call2(bytes)](tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#L18-L20) uses delegatecall to a input-controlled function id\n\t- [addr_bad.delegatecall(abi.encode(func_id,data))](tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#L19)\n",
"first_markdown_element": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#L8-L11", "first_markdown_element": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#L18-L20",
"id": "90d4f387ca3c669975a3ed4d7a5b09665b786a1078e16ced61adf1c3f9f6efb8", "id": "12d6ba2d0139326b442352b37028ff77dfbdc625870a5ae858e6107cfa89cfbb",
"check": "controlled-delegatecall", "check": "controlled-delegatecall",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -167,19 +165,20 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad_delegate_call2", "name": "bad_delegate_call",
"source_mapping": { "source_mapping": {
"start": 337, "start": 101,
"length": 118, "length": 134,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
18, 8,
19, 9,
20 10,
11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -227,42 +226,43 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_delegate_call2(bytes)" "signature": "bad_delegate_call(bytes)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr_bad.delegatecall(abi.encode(func_id,data))", "name": "addr_bad.delegatecall(data)",
"source_mapping": { "source_mapping": {
"start": 400, "start": 201,
"length": 48, "length": 27,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19 10
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 57 "ending_column": 36
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad_delegate_call2", "name": "bad_delegate_call",
"source_mapping": { "source_mapping": {
"start": 337, "start": 101,
"length": 118, "length": 134,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
18, 8,
19, 9,
20 10,
11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -310,16 +310,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_delegate_call2(bytes)" "signature": "bad_delegate_call(bytes)"
} }
} }
} }
} }
], ],
"description": "C.bad_delegate_call2(bytes) (tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#18-20) uses delegatecall to a input-controlled function id\n\t- addr_bad.delegatecall(abi.encode(func_id,data)) (tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#19)\n", "description": "C.bad_delegate_call(bytes) (tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#8-11) uses delegatecall to a input-controlled function id\n\t- addr_bad.delegatecall(data) (tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#10)\n",
"markdown": "[C.bad_delegate_call2(bytes)](tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#L18-L20) uses delegatecall to a input-controlled function id\n\t- [addr_bad.delegatecall(abi.encode(func_id,data))](tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#L19)\n", "markdown": "[C.bad_delegate_call(bytes)](tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#L8-L11) uses delegatecall to a input-controlled function id\n\t- [addr_bad.delegatecall(data)](tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#L10)\n",
"first_markdown_element": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#L18-L20", "first_markdown_element": "tests/detectors/controlled-delegatecall/0.4.25/controlled_delegatecall.sol#L8-L11",
"id": "12d6ba2d0139326b442352b37028ff77dfbdc625870a5ae858e6107cfa89cfbb", "id": "90d4f387ca3c669975a3ed4d7a5b09665b786a1078e16ced61adf1c3f9f6efb8",
"check": "controlled-delegatecall", "check": "controlled-delegatecall",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -4,20 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad_delegate_call", "name": "bad_delegate_call2",
"source_mapping": { "source_mapping": {
"start": 101, "start": 337,
"length": 134, "length": 118,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8, 18,
9, 19,
10, 20
11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -65,43 +64,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_delegate_call(bytes)" "signature": "bad_delegate_call2(bytes)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr_bad.delegatecall(data)", "name": "addr_bad.delegatecall(abi.encode(func_id,data))",
"source_mapping": { "source_mapping": {
"start": 201, "start": 400,
"length": 27, "length": 48,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 19
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 36 "ending_column": 57
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad_delegate_call", "name": "bad_delegate_call2",
"source_mapping": { "source_mapping": {
"start": 101, "start": 337,
"length": 134, "length": 118,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8, 18,
9, 19,
10, 20
11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -149,16 +147,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_delegate_call(bytes)" "signature": "bad_delegate_call2(bytes)"
} }
} }
} }
} }
], ],
"description": "C.bad_delegate_call(bytes) (tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#8-11) uses delegatecall to a input-controlled function id\n\t- addr_bad.delegatecall(data) (tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#10)\n", "description": "C.bad_delegate_call2(bytes) (tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#18-20) uses delegatecall to a input-controlled function id\n\t- addr_bad.delegatecall(abi.encode(func_id,data)) (tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#19)\n",
"markdown": "[C.bad_delegate_call(bytes)](tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#L8-L11) uses delegatecall to a input-controlled function id\n\t- [addr_bad.delegatecall(data)](tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#L10)\n", "markdown": "[C.bad_delegate_call2(bytes)](tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#L18-L20) uses delegatecall to a input-controlled function id\n\t- [addr_bad.delegatecall(abi.encode(func_id,data))](tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#L19)\n",
"first_markdown_element": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#L8-L11", "first_markdown_element": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#L18-L20",
"id": "bed67f615a2f3a872e24eedf23fdedbdfbe5a540dc3f3ea4ca1430581997a8f6", "id": "82fc8a33f6b16eff457087ec9961f2bce3c61289628dac8284009c8275cea790",
"check": "controlled-delegatecall", "check": "controlled-delegatecall",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -167,19 +165,20 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad_delegate_call2", "name": "bad_delegate_call",
"source_mapping": { "source_mapping": {
"start": 337, "start": 101,
"length": 118, "length": 134,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
18, 8,
19, 9,
20 10,
11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -227,42 +226,43 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_delegate_call2(bytes)" "signature": "bad_delegate_call(bytes)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr_bad.delegatecall(abi.encode(func_id,data))", "name": "addr_bad.delegatecall(data)",
"source_mapping": { "source_mapping": {
"start": 400, "start": 201,
"length": 48, "length": 27,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19 10
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 57 "ending_column": 36
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad_delegate_call2", "name": "bad_delegate_call",
"source_mapping": { "source_mapping": {
"start": 337, "start": 101,
"length": 118, "length": 134,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
18, 8,
19, 9,
20 10,
11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -310,16 +310,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_delegate_call2(bytes)" "signature": "bad_delegate_call(bytes)"
} }
} }
} }
} }
], ],
"description": "C.bad_delegate_call2(bytes) (tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#18-20) uses delegatecall to a input-controlled function id\n\t- addr_bad.delegatecall(abi.encode(func_id,data)) (tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#19)\n", "description": "C.bad_delegate_call(bytes) (tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#8-11) uses delegatecall to a input-controlled function id\n\t- addr_bad.delegatecall(data) (tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#10)\n",
"markdown": "[C.bad_delegate_call2(bytes)](tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#L18-L20) uses delegatecall to a input-controlled function id\n\t- [addr_bad.delegatecall(abi.encode(func_id,data))](tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#L19)\n", "markdown": "[C.bad_delegate_call(bytes)](tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#L8-L11) uses delegatecall to a input-controlled function id\n\t- [addr_bad.delegatecall(data)](tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#L10)\n",
"first_markdown_element": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#L18-L20", "first_markdown_element": "tests/detectors/controlled-delegatecall/0.6.11/controlled_delegatecall.sol#L8-L11",
"id": "82fc8a33f6b16eff457087ec9961f2bce3c61289628dac8284009c8275cea790", "id": "bed67f615a2f3a872e24eedf23fdedbdfbe5a540dc3f3ea4ca1430581997a8f6",
"check": "controlled-delegatecall", "check": "controlled-delegatecall",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -4,20 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad_delegate_call", "name": "bad_delegate_call2",
"source_mapping": { "source_mapping": {
"start": 101, "start": 337,
"length": 134, "length": 118,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8, 18,
9, 19,
10, 20
11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -65,43 +64,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_delegate_call(bytes)" "signature": "bad_delegate_call2(bytes)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr_bad.delegatecall(data)", "name": "addr_bad.delegatecall(abi.encode(func_id,data))",
"source_mapping": { "source_mapping": {
"start": 201, "start": 400,
"length": 27, "length": 48,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 19
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 36 "ending_column": 57
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad_delegate_call", "name": "bad_delegate_call2",
"source_mapping": { "source_mapping": {
"start": 101, "start": 337,
"length": 134, "length": 118,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8, 18,
9, 19,
10, 20
11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -149,16 +147,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_delegate_call(bytes)" "signature": "bad_delegate_call2(bytes)"
} }
} }
} }
} }
], ],
"description": "C.bad_delegate_call(bytes) (tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#8-11) uses delegatecall to a input-controlled function id\n\t- addr_bad.delegatecall(data) (tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#10)\n", "description": "C.bad_delegate_call2(bytes) (tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#18-20) uses delegatecall to a input-controlled function id\n\t- addr_bad.delegatecall(abi.encode(func_id,data)) (tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#19)\n",
"markdown": "[C.bad_delegate_call(bytes)](tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#L8-L11) uses delegatecall to a input-controlled function id\n\t- [addr_bad.delegatecall(data)](tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#L10)\n", "markdown": "[C.bad_delegate_call2(bytes)](tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#L18-L20) uses delegatecall to a input-controlled function id\n\t- [addr_bad.delegatecall(abi.encode(func_id,data))](tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#L19)\n",
"first_markdown_element": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#L8-L11", "first_markdown_element": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#L18-L20",
"id": "59a70e53c14de214629ffde4abab9700cbb3bc66a99e281954e3b9f285a28c2d", "id": "04a4aed45b4c803d9fa03d70198a8f6d7f4228d2fd5e06bd61c4c68431be2c90",
"check": "controlled-delegatecall", "check": "controlled-delegatecall",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -167,19 +165,20 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad_delegate_call2", "name": "bad_delegate_call",
"source_mapping": { "source_mapping": {
"start": 337, "start": 101,
"length": 118, "length": 134,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
18, 8,
19, 9,
20 10,
11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -227,42 +226,43 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_delegate_call2(bytes)" "signature": "bad_delegate_call(bytes)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr_bad.delegatecall(abi.encode(func_id,data))", "name": "addr_bad.delegatecall(data)",
"source_mapping": { "source_mapping": {
"start": 400, "start": 201,
"length": 48, "length": 27,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19 10
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 57 "ending_column": 36
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad_delegate_call2", "name": "bad_delegate_call",
"source_mapping": { "source_mapping": {
"start": 337, "start": 101,
"length": 118, "length": 134,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol", "filename_relative": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol", "filename_short": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
18, 8,
19, 9,
20 10,
11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -310,16 +310,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad_delegate_call2(bytes)" "signature": "bad_delegate_call(bytes)"
} }
} }
} }
} }
], ],
"description": "C.bad_delegate_call2(bytes) (tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#18-20) uses delegatecall to a input-controlled function id\n\t- addr_bad.delegatecall(abi.encode(func_id,data)) (tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#19)\n", "description": "C.bad_delegate_call(bytes) (tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#8-11) uses delegatecall to a input-controlled function id\n\t- addr_bad.delegatecall(data) (tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#10)\n",
"markdown": "[C.bad_delegate_call2(bytes)](tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#L18-L20) uses delegatecall to a input-controlled function id\n\t- [addr_bad.delegatecall(abi.encode(func_id,data))](tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#L19)\n", "markdown": "[C.bad_delegate_call(bytes)](tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#L8-L11) uses delegatecall to a input-controlled function id\n\t- [addr_bad.delegatecall(data)](tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#L10)\n",
"first_markdown_element": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#L18-L20", "first_markdown_element": "tests/detectors/controlled-delegatecall/0.7.6/controlled_delegatecall.sol#L8-L11",
"id": "04a4aed45b4c803d9fa03d70198a8f6d7f4228d2fd5e06bd61c4c68431be2c90", "id": "59a70e53c14de214629ffde4abab9700cbb3bc66a99e281954e3b9f285a28c2d",
"check": "controlled-delegatecall", "check": "controlled-delegatecall",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -4,158 +4,24 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad_base", "name": "bad2",
"source_mapping": {
"start": 102,
"length": 389,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
5,
6,
7,
8,
9
],
"starting_column": 3,
"ending_column": 4
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CostlyOperationsInLoopBase",
"source_mapping": {
"start": 0,
"length": 494,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
},
{
"type": "node",
"name": "state_variable_base ++",
"source_mapping": {
"start": 271,
"length": 21,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
7
],
"starting_column": 7,
"ending_column": 28
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad_base",
"source_mapping": {
"start": 102,
"length": 389,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
5,
6,
7,
8,
9
],
"starting_column": 3,
"ending_column": 4
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CostlyOperationsInLoopBase",
"source_mapping": {
"start": 0,
"length": 494,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
}
}
}
],
"description": "CostlyOperationsInLoopBase.bad_base() (tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#5-9) has costly operations inside a loop:\n\t- state_variable_base ++ (tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#7)\n",
"markdown": "[CostlyOperationsInLoopBase.bad_base()](tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L5-L9) has costly operations inside a loop:\n\t- [state_variable_base ++](tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L7)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L5-L9",
"id": "a5134568bf722ac31d7c4d41595c23e1a5ff9b79902e9502f78ccfe9a430b87a",
"check": "costly-loop",
"impact": "Informational",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad",
"source_mapping": { "source_mapping": {
"start": 754, "start": 1131,
"length": 373, "length": 343,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 26,
21, 27,
22, 28,
23, 29,
24 30,
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -230,14 +96,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad()" "signature": "bad2()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "state_variable ++", "name": "state_variable ++",
"source_mapping": { "source_mapping": {
"start": 912, "start": 1363,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
@ -245,7 +111,7 @@
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
22 31
], ],
"starting_column": 7, "starting_column": 7,
"ending_column": 23 "ending_column": 23
@ -253,21 +119,24 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 754, "start": 1131,
"length": 373, "length": 343,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 26,
21, 27,
22, 28,
23, 29,
24 30,
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -342,16 +211,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad()" "signature": "bad2()"
} }
} }
} }
} }
], ],
"description": "CostlyOperationsInLoop.bad() (tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#20-24) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#22)\n", "description": "CostlyOperationsInLoop.bad2() (tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#26-33) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#31)\n",
"markdown": "[CostlyOperationsInLoop.bad()](tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L20-L24) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L22)\n", "markdown": "[CostlyOperationsInLoop.bad2()](tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L26-L33) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L31)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L20-L24", "first_markdown_element": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L26-L33",
"id": "92dbac16da1c357bad3a24661de0e92213ac3a701d80655fadb64359ff98d21d", "id": "0cde1ae7c1410e0eb0d07ff2c21adc20b1c7f7a654780c8d41069ad3a34e73b4",
"check": "costly-loop", "check": "costly-loop",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"
@ -360,24 +229,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 1131, "start": 754,
"length": 343, "length": 373,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 20,
27, 21,
28, 22,
29, 23,
30, 24
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -452,14 +318,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "state_variable ++", "name": "state_variable ++",
"source_mapping": { "source_mapping": {
"start": 1363, "start": 912,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
@ -467,7 +333,7 @@
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
31 22
], ],
"starting_column": 7, "starting_column": 7,
"ending_column": 23 "ending_column": 23
@ -475,24 +341,21 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 1131, "start": 754,
"length": 343, "length": 373,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 20,
27, 21,
28, 22,
29, 23,
30, 24
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -567,16 +430,153 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad()"
} }
} }
} }
} }
], ],
"description": "CostlyOperationsInLoop.bad2() (tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#26-33) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#31)\n", "description": "CostlyOperationsInLoop.bad() (tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#20-24) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#22)\n",
"markdown": "[CostlyOperationsInLoop.bad2()](tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L26-L33) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L31)\n", "markdown": "[CostlyOperationsInLoop.bad()](tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L20-L24) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L22)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L26-L33", "first_markdown_element": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L20-L24",
"id": "0cde1ae7c1410e0eb0d07ff2c21adc20b1c7f7a654780c8d41069ad3a34e73b4", "id": "92dbac16da1c357bad3a24661de0e92213ac3a701d80655fadb64359ff98d21d",
"check": "costly-loop",
"impact": "Informational",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad_base",
"source_mapping": {
"start": 102,
"length": 389,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
5,
6,
7,
8,
9
],
"starting_column": 3,
"ending_column": 4
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CostlyOperationsInLoopBase",
"source_mapping": {
"start": 0,
"length": 494,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
},
{
"type": "node",
"name": "state_variable_base ++",
"source_mapping": {
"start": 271,
"length": 21,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
7
],
"starting_column": 7,
"ending_column": 28
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad_base",
"source_mapping": {
"start": 102,
"length": 389,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
5,
6,
7,
8,
9
],
"starting_column": 3,
"ending_column": 4
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CostlyOperationsInLoopBase",
"source_mapping": {
"start": 0,
"length": 494,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
}
}
}
],
"description": "CostlyOperationsInLoopBase.bad_base() (tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#5-9) has costly operations inside a loop:\n\t- state_variable_base ++ (tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#7)\n",
"markdown": "[CostlyOperationsInLoopBase.bad_base()](tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L5-L9) has costly operations inside a loop:\n\t- [state_variable_base ++](tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L7)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.4.25/multiple_costly_operations_in_loop.sol#L5-L9",
"id": "a5134568bf722ac31d7c4d41595c23e1a5ff9b79902e9502f78ccfe9a430b87a",
"check": "costly-loop", "check": "costly-loop",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"

@ -141,21 +141,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad", "name": "bad3_internal",
"source_mapping": { "source_mapping": {
"start": 754, "start": 1855,
"length": 373, "length": 60,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 41,
21, 42,
22, 43
23,
24
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -230,14 +228,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad()" "signature": "bad3_internal()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "state_variable ++", "name": "state_variable ++",
"source_mapping": { "source_mapping": {
"start": 912, "start": 1894,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
@ -245,29 +243,27 @@
"filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
22 42
], ],
"starting_column": 7, "starting_column": 5,
"ending_column": 23 "ending_column": 21
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad", "name": "bad3_internal",
"source_mapping": { "source_mapping": {
"start": 754, "start": 1855,
"length": 373, "length": 60,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 41,
21, 42,
22, 43
23,
24
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -342,16 +338,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad()" "signature": "bad3_internal()"
} }
} }
} }
} }
], ],
"description": "CostlyOperationsInLoop.bad() (tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#20-24) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#22)\n", "description": "CostlyOperationsInLoop.bad3_internal() (tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#41-43) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#42)\n",
"markdown": "[CostlyOperationsInLoop.bad()](tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L20-L24) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L22)\n", "markdown": "[CostlyOperationsInLoop.bad3_internal()](tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L41-L43) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L42)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L20-L24", "first_markdown_element": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L41-L43",
"id": "94a7ffd0d3ada78ae8ace1304b276d677415a08dcdff51fc05889122e14633da", "id": "6ebf2ecedb330a477079a9b72f1ba6ffc5717e08017f700538ec42d3eeab355b",
"check": "costly-loop", "check": "costly-loop",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"
@ -360,24 +356,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 1131, "start": 754,
"length": 343, "length": 373,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 20,
27, 21,
28, 22,
29, 23,
30, 24
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -452,14 +445,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "state_variable ++", "name": "state_variable ++",
"source_mapping": { "source_mapping": {
"start": 1363, "start": 912,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
@ -467,7 +460,7 @@
"filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
31 22
], ],
"starting_column": 7, "starting_column": 7,
"ending_column": 23 "ending_column": 23
@ -475,24 +468,21 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 1131, "start": 754,
"length": 343, "length": 373,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 20,
27, 21,
28, 22,
29, 23,
30, 24
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -567,16 +557,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad()"
} }
} }
} }
} }
], ],
"description": "CostlyOperationsInLoop.bad2() (tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#26-33) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#31)\n", "description": "CostlyOperationsInLoop.bad() (tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#20-24) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#22)\n",
"markdown": "[CostlyOperationsInLoop.bad2()](tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L26-L33) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L31)\n", "markdown": "[CostlyOperationsInLoop.bad()](tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L20-L24) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L22)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L26-L33", "first_markdown_element": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L20-L24",
"id": "c0c91898e5b5af12af49b6aefdc4790190101774bffad8e446ba9c857ff86525", "id": "94a7ffd0d3ada78ae8ace1304b276d677415a08dcdff51fc05889122e14633da",
"check": "costly-loop", "check": "costly-loop",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"
@ -585,19 +575,24 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad3_internal", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 1855, "start": 1131,
"length": 60, "length": 343,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
41, 26,
42, 27,
43 28,
29,
30,
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -672,14 +667,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_internal()" "signature": "bad2()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "state_variable ++", "name": "state_variable ++",
"source_mapping": { "source_mapping": {
"start": 1894, "start": 1363,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
@ -687,27 +682,32 @@
"filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
42 31
], ],
"starting_column": 5, "starting_column": 7,
"ending_column": 21 "ending_column": 23
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_internal", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 1855, "start": 1131,
"length": 60, "length": 343,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
41, 26,
42, 27,
43 28,
29,
30,
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -782,16 +782,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_internal()" "signature": "bad2()"
} }
} }
} }
} }
], ],
"description": "CostlyOperationsInLoop.bad3_internal() (tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#41-43) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#42)\n", "description": "CostlyOperationsInLoop.bad2() (tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#26-33) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#31)\n",
"markdown": "[CostlyOperationsInLoop.bad3_internal()](tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L41-L43) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L42)\n", "markdown": "[CostlyOperationsInLoop.bad2()](tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L26-L33) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L31)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L41-L43", "first_markdown_element": "tests/detectors/costly-loop/0.5.16/multiple_costly_operations_in_loop.sol#L26-L33",
"id": "6ebf2ecedb330a477079a9b72f1ba6ffc5717e08017f700538ec42d3eeab355b", "id": "c0c91898e5b5af12af49b6aefdc4790190101774bffad8e446ba9c857ff86525",
"check": "costly-loop", "check": "costly-loop",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"

@ -4,158 +4,24 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad_base", "name": "bad2",
"source_mapping": {
"start": 102,
"length": 389,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
5,
6,
7,
8,
9
],
"starting_column": 3,
"ending_column": 4
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CostlyOperationsInLoopBase",
"source_mapping": {
"start": 0,
"length": 494,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
},
{
"type": "node",
"name": "state_variable_base ++",
"source_mapping": {
"start": 271,
"length": 21,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
7
],
"starting_column": 7,
"ending_column": 28
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad_base",
"source_mapping": {
"start": 102,
"length": 389,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
5,
6,
7,
8,
9
],
"starting_column": 3,
"ending_column": 4
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CostlyOperationsInLoopBase",
"source_mapping": {
"start": 0,
"length": 494,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
}
}
}
],
"description": "CostlyOperationsInLoopBase.bad_base() (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#5-9) has costly operations inside a loop:\n\t- state_variable_base ++ (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#7)\n",
"markdown": "[CostlyOperationsInLoopBase.bad_base()](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L5-L9) has costly operations inside a loop:\n\t- [state_variable_base ++](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L7)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L5-L9",
"id": "53602b905c8ae68d5325f0c11263f1c9b905406799ec70ca13638f4b1094c37f",
"check": "costly-loop",
"impact": "Informational",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad",
"source_mapping": { "source_mapping": {
"start": 754, "start": 1131,
"length": 373, "length": 343,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 26,
21, 27,
22, 28,
23, 29,
24 30,
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -230,14 +96,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad()" "signature": "bad2()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "state_variable ++", "name": "state_variable ++",
"source_mapping": { "source_mapping": {
"start": 912, "start": 1363,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
@ -245,7 +111,7 @@
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
22 31
], ],
"starting_column": 7, "starting_column": 7,
"ending_column": 23 "ending_column": 23
@ -253,21 +119,24 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 754, "start": 1131,
"length": 373, "length": 343,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 26,
21, 27,
22, 28,
23, 29,
24 30,
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -342,16 +211,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad()" "signature": "bad2()"
} }
} }
} }
} }
], ],
"description": "CostlyOperationsInLoop.bad() (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#20-24) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#22)\n", "description": "CostlyOperationsInLoop.bad2() (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#26-33) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#31)\n",
"markdown": "[CostlyOperationsInLoop.bad()](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L20-L24) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L22)\n", "markdown": "[CostlyOperationsInLoop.bad2()](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L26-L33) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L31)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L20-L24", "first_markdown_element": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L26-L33",
"id": "a4f559a14007167a13506a3c865345fb2c050b8d2c660804cc5e301db553822a", "id": "3a1b0ff0bee83dfad403a074eb81c6d845c5da8e99e98433004ba72c1b2c624c",
"check": "costly-loop", "check": "costly-loop",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"
@ -360,24 +229,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad3_internal",
"source_mapping": { "source_mapping": {
"start": 1131, "start": 1855,
"length": 343, "length": 60,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 41,
27, 42,
28, 43
29,
30,
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -452,14 +316,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad3_internal()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "state_variable ++", "name": "state_variable ++",
"source_mapping": { "source_mapping": {
"start": 1363, "start": 1894,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
@ -467,32 +331,27 @@
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
31 42
], ],
"starting_column": 7, "starting_column": 5,
"ending_column": 23 "ending_column": 21
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad3_internal",
"source_mapping": { "source_mapping": {
"start": 1131, "start": 1855,
"length": 343, "length": 60,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 41,
27, 42,
28, 43
29,
30,
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -567,16 +426,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad3_internal()"
} }
} }
} }
} }
], ],
"description": "CostlyOperationsInLoop.bad2() (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#26-33) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#31)\n", "description": "CostlyOperationsInLoop.bad3_internal() (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#41-43) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#42)\n",
"markdown": "[CostlyOperationsInLoop.bad2()](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L26-L33) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L31)\n", "markdown": "[CostlyOperationsInLoop.bad3_internal()](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L41-L43) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L42)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L26-L33", "first_markdown_element": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L41-L43",
"id": "3a1b0ff0bee83dfad403a074eb81c6d845c5da8e99e98433004ba72c1b2c624c", "id": "4bb89ccd252e2233f67cccaf8b40354da7edcb7c5b36df1edfeab0cafed05b74",
"check": "costly-loop", "check": "costly-loop",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"
@ -585,19 +444,158 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad3_internal", "name": "bad_base",
"source_mapping": { "source_mapping": {
"start": 1855, "start": 102,
"length": 60, "length": 389,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
41, 5,
42, 6,
43 7,
8,
9
],
"starting_column": 3,
"ending_column": 4
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CostlyOperationsInLoopBase",
"source_mapping": {
"start": 0,
"length": 494,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
},
{
"type": "node",
"name": "state_variable_base ++",
"source_mapping": {
"start": 271,
"length": 21,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
7
],
"starting_column": 7,
"ending_column": 28
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad_base",
"source_mapping": {
"start": 102,
"length": 389,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
5,
6,
7,
8,
9
],
"starting_column": 3,
"ending_column": 4
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CostlyOperationsInLoopBase",
"source_mapping": {
"start": 0,
"length": 494,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
}
}
}
],
"description": "CostlyOperationsInLoopBase.bad_base() (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#5-9) has costly operations inside a loop:\n\t- state_variable_base ++ (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#7)\n",
"markdown": "[CostlyOperationsInLoopBase.bad_base()](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L5-L9) has costly operations inside a loop:\n\t- [state_variable_base ++](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L7)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L5-L9",
"id": "53602b905c8ae68d5325f0c11263f1c9b905406799ec70ca13638f4b1094c37f",
"check": "costly-loop",
"impact": "Informational",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad",
"source_mapping": {
"start": 754,
"length": 373,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
20,
21,
22,
23,
24
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -672,14 +670,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_internal()" "signature": "bad()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "state_variable ++", "name": "state_variable ++",
"source_mapping": { "source_mapping": {
"start": 1894, "start": 912,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
@ -687,27 +685,29 @@
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
42 22
], ],
"starting_column": 5, "starting_column": 7,
"ending_column": 21 "ending_column": 23
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_internal", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 1855, "start": 754,
"length": 60, "length": 373,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
41, 20,
42, 21,
43 22,
23,
24
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -782,16 +782,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_internal()" "signature": "bad()"
} }
} }
} }
} }
], ],
"description": "CostlyOperationsInLoop.bad3_internal() (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#41-43) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#42)\n", "description": "CostlyOperationsInLoop.bad() (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#20-24) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#22)\n",
"markdown": "[CostlyOperationsInLoop.bad3_internal()](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L41-L43) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L42)\n", "markdown": "[CostlyOperationsInLoop.bad()](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L20-L24) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L22)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L41-L43", "first_markdown_element": "tests/detectors/costly-loop/0.6.11/multiple_costly_operations_in_loop.sol#L20-L24",
"id": "4bb89ccd252e2233f67cccaf8b40354da7edcb7c5b36df1edfeab0cafed05b74", "id": "a4f559a14007167a13506a3c865345fb2c050b8d2c660804cc5e301db553822a",
"check": "costly-loop", "check": "costly-loop",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"

@ -4,158 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad_base", "name": "bad3_internal",
"source_mapping": {
"start": 102,
"length": 389,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
5,
6,
7,
8,
9
],
"starting_column": 3,
"ending_column": 4
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CostlyOperationsInLoopBase",
"source_mapping": {
"start": 0,
"length": 494,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
},
{
"type": "node",
"name": "state_variable_base ++",
"source_mapping": {
"start": 271,
"length": 21,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
7
],
"starting_column": 7,
"ending_column": 28
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad_base",
"source_mapping": {
"start": 102,
"length": 389,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
5,
6,
7,
8,
9
],
"starting_column": 3,
"ending_column": 4
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CostlyOperationsInLoopBase",
"source_mapping": {
"start": 0,
"length": 494,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
}
}
}
],
"description": "CostlyOperationsInLoopBase.bad_base() (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#5-9) has costly operations inside a loop:\n\t- state_variable_base ++ (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#7)\n",
"markdown": "[CostlyOperationsInLoopBase.bad_base()](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L5-L9) has costly operations inside a loop:\n\t- [state_variable_base ++](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L7)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L5-L9",
"id": "a150cde3056e29877ab4fc8d64ce48a08db143bcb5dc2bcccae8f7848e666940",
"check": "costly-loop",
"impact": "Informational",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad",
"source_mapping": { "source_mapping": {
"start": 754, "start": 1855,
"length": 373, "length": 60,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 41,
21, 42,
22, 43
23,
24
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -230,14 +91,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad()" "signature": "bad3_internal()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "state_variable ++", "name": "state_variable ++",
"source_mapping": { "source_mapping": {
"start": 912, "start": 1894,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
@ -245,29 +106,27 @@
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
22 42
], ],
"starting_column": 7, "starting_column": 5,
"ending_column": 23 "ending_column": 21
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad", "name": "bad3_internal",
"source_mapping": { "source_mapping": {
"start": 754, "start": 1855,
"length": 373, "length": 60,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 41,
21, 42,
22, 43
23,
24
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -342,16 +201,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad()" "signature": "bad3_internal()"
} }
} }
} }
} }
], ],
"description": "CostlyOperationsInLoop.bad() (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#20-24) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#22)\n", "description": "CostlyOperationsInLoop.bad3_internal() (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#41-43) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#42)\n",
"markdown": "[CostlyOperationsInLoop.bad()](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L20-L24) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L22)\n", "markdown": "[CostlyOperationsInLoop.bad3_internal()](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L41-L43) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L42)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L20-L24", "first_markdown_element": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L41-L43",
"id": "c92490750428b640ff46202b5fe9d0eb62ab98a70419cef5ca80530c15b14180", "id": "77bb0a1e0308312bb9696553d6384270c433fcbebd6311e053c6979d4bdc2128",
"check": "costly-loop", "check": "costly-loop",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"
@ -360,24 +219,158 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad_base",
"source_mapping": { "source_mapping": {
"start": 1131, "start": 102,
"length": 343, "length": 389,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 5,
27, 6,
28, 7,
29, 8,
30, 9
31, ],
32, "starting_column": 3,
33 "ending_column": 4
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CostlyOperationsInLoopBase",
"source_mapping": {
"start": 0,
"length": 494,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
},
{
"type": "node",
"name": "state_variable_base ++",
"source_mapping": {
"start": 271,
"length": 21,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
7
],
"starting_column": 7,
"ending_column": 28
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad_base",
"source_mapping": {
"start": 102,
"length": 389,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
5,
6,
7,
8,
9
],
"starting_column": 3,
"ending_column": 4
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "CostlyOperationsInLoopBase",
"source_mapping": {
"start": 0,
"length": 494,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad_base()"
}
}
}
}
],
"description": "CostlyOperationsInLoopBase.bad_base() (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#5-9) has costly operations inside a loop:\n\t- state_variable_base ++ (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#7)\n",
"markdown": "[CostlyOperationsInLoopBase.bad_base()](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L5-L9) has costly operations inside a loop:\n\t- [state_variable_base ++](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L7)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L5-L9",
"id": "a150cde3056e29877ab4fc8d64ce48a08db143bcb5dc2bcccae8f7848e666940",
"check": "costly-loop",
"impact": "Informational",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad",
"source_mapping": {
"start": 754,
"length": 373,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false,
"lines": [
20,
21,
22,
23,
24
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -452,14 +445,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "state_variable ++", "name": "state_variable ++",
"source_mapping": { "source_mapping": {
"start": 1363, "start": 912,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
@ -467,7 +460,7 @@
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
31 22
], ],
"starting_column": 7, "starting_column": 7,
"ending_column": 23 "ending_column": 23
@ -475,24 +468,21 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 1131, "start": 754,
"length": 343, "length": 373,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 20,
27, 21,
28, 22,
29, 23,
30, 24
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -567,16 +557,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2()" "signature": "bad()"
} }
} }
} }
} }
], ],
"description": "CostlyOperationsInLoop.bad2() (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#26-33) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#31)\n", "description": "CostlyOperationsInLoop.bad() (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#20-24) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#22)\n",
"markdown": "[CostlyOperationsInLoop.bad2()](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L26-L33) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L31)\n", "markdown": "[CostlyOperationsInLoop.bad()](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L20-L24) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L22)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L26-L33", "first_markdown_element": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L20-L24",
"id": "f7ebc0c37f31c1a68b8fbfe7530fd66f3c590e5631478cc88d03eeaa8c09f6a6", "id": "c92490750428b640ff46202b5fe9d0eb62ab98a70419cef5ca80530c15b14180",
"check": "costly-loop", "check": "costly-loop",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"
@ -585,19 +575,24 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad3_internal", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 1855, "start": 1131,
"length": 60, "length": 343,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
41, 26,
42, 27,
43 28,
29,
30,
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -672,14 +667,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_internal()" "signature": "bad2()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "state_variable ++", "name": "state_variable ++",
"source_mapping": { "source_mapping": {
"start": 1894, "start": 1363,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
@ -687,27 +682,32 @@
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
42 31
], ],
"starting_column": 5, "starting_column": 7,
"ending_column": 21 "ending_column": 23
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_internal", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 1855, "start": 1131,
"length": 60, "length": 343,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_relative": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol", "filename_short": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
41, 26,
42, 27,
43 28,
29,
30,
31,
32,
33
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -782,16 +782,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_internal()" "signature": "bad2()"
} }
} }
} }
} }
], ],
"description": "CostlyOperationsInLoop.bad3_internal() (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#41-43) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#42)\n", "description": "CostlyOperationsInLoop.bad2() (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#26-33) has costly operations inside a loop:\n\t- state_variable ++ (tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#31)\n",
"markdown": "[CostlyOperationsInLoop.bad3_internal()](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L41-L43) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L42)\n", "markdown": "[CostlyOperationsInLoop.bad2()](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L26-L33) has costly operations inside a loop:\n\t- [state_variable ++](tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L31)\n",
"first_markdown_element": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L41-L43", "first_markdown_element": "tests/detectors/costly-loop/0.7.6/multiple_costly_operations_in_loop.sol#L26-L33",
"id": "77bb0a1e0308312bb9696553d6384270c433fcbebd6311e053c6979d4bdc2128", "id": "f7ebc0c37f31c1a68b8fbfe7530fd66f3c590e5631478cc88d03eeaa8c09f6a6",
"check": "costly-loop", "check": "costly-loop",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"

@ -4,19 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "unused", "name": "unused_but_shadowed",
"source_mapping": { "source_mapping": {
"start": 19, "start": 319,
"length": 34, "length": 56,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/dead-code/0.8.0/dead-code.sol", "filename_relative": "tests/detectors/dead-code/0.8.0/dead-code.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/dead-code/0.8.0/dead-code.sol", "filename_short": "tests/detectors/dead-code/0.8.0/dead-code.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
2, 26,
3, 27,
4 28
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -24,34 +24,34 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "Test", "name": "Test4",
"source_mapping": { "source_mapping": {
"start": 0, "start": 290,
"length": 55, "length": 87,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/dead-code/0.8.0/dead-code.sol", "filename_relative": "tests/detectors/dead-code/0.8.0/dead-code.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/dead-code/0.8.0/dead-code.sol", "filename_short": "tests/detectors/dead-code/0.8.0/dead-code.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
1, 25,
2, 26,
3, 27,
4, 28,
5 29
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "unused()" "signature": "unused_but_shadowed()"
} }
} }
], ],
"description": "Test.unused() (tests/detectors/dead-code/0.8.0/dead-code.sol#2-4) is never used and should be removed\n", "description": "Test4.unused_but_shadowed() (tests/detectors/dead-code/0.8.0/dead-code.sol#26-28) is never used and should be removed\n",
"markdown": "[Test.unused()](tests/detectors/dead-code/0.8.0/dead-code.sol#L2-L4) is never used and should be removed\n", "markdown": "[Test4.unused_but_shadowed()](tests/detectors/dead-code/0.8.0/dead-code.sol#L26-L28) is never used and should be removed\n",
"first_markdown_element": "tests/detectors/dead-code/0.8.0/dead-code.sol#L2-L4", "first_markdown_element": "tests/detectors/dead-code/0.8.0/dead-code.sol#L26-L28",
"id": "a7c13823116566bbbbb68e8a7efa78fe64785fcb8582069373eda7f27c523cb3", "id": "74ea8421cf7fa9e04d243014b61f3eee7a9c7648df98316c3881dd4f1f2ab3f7",
"check": "dead-code", "check": "dead-code",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"
@ -60,19 +60,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "unused_but_shadowed", "name": "unused",
"source_mapping": { "source_mapping": {
"start": 79, "start": 19,
"length": 55, "length": 34,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/dead-code/0.8.0/dead-code.sol", "filename_relative": "tests/detectors/dead-code/0.8.0/dead-code.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/dead-code/0.8.0/dead-code.sol", "filename_short": "tests/detectors/dead-code/0.8.0/dead-code.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10, 2,
11, 3,
12 4
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -80,35 +80,34 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "Test2", "name": "Test",
"source_mapping": { "source_mapping": {
"start": 58, "start": 0,
"length": 78, "length": 55,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/dead-code/0.8.0/dead-code.sol", "filename_relative": "tests/detectors/dead-code/0.8.0/dead-code.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/dead-code/0.8.0/dead-code.sol", "filename_short": "tests/detectors/dead-code/0.8.0/dead-code.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8, 1,
9, 2,
10, 3,
11, 4,
12, 5
13
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "unused_but_shadowed()" "signature": "unused()"
} }
} }
], ],
"description": "Test2.unused_but_shadowed() (tests/detectors/dead-code/0.8.0/dead-code.sol#10-12) is never used and should be removed\n", "description": "Test.unused() (tests/detectors/dead-code/0.8.0/dead-code.sol#2-4) is never used and should be removed\n",
"markdown": "[Test2.unused_but_shadowed()](tests/detectors/dead-code/0.8.0/dead-code.sol#L10-L12) is never used and should be removed\n", "markdown": "[Test.unused()](tests/detectors/dead-code/0.8.0/dead-code.sol#L2-L4) is never used and should be removed\n",
"first_markdown_element": "tests/detectors/dead-code/0.8.0/dead-code.sol#L10-L12", "first_markdown_element": "tests/detectors/dead-code/0.8.0/dead-code.sol#L2-L4",
"id": "aaba496684b73955e90b555de174e1cd03f0fee337849c4d58c10ef76ff93582", "id": "a7c13823116566bbbbb68e8a7efa78fe64785fcb8582069373eda7f27c523cb3",
"check": "dead-code", "check": "dead-code",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"
@ -119,17 +118,17 @@
"type": "function", "type": "function",
"name": "unused_but_shadowed", "name": "unused_but_shadowed",
"source_mapping": { "source_mapping": {
"start": 319, "start": 79,
"length": 56, "length": 55,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/dead-code/0.8.0/dead-code.sol", "filename_relative": "tests/detectors/dead-code/0.8.0/dead-code.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/dead-code/0.8.0/dead-code.sol", "filename_short": "tests/detectors/dead-code/0.8.0/dead-code.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 10,
27, 11,
28 12
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -137,21 +136,22 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "Test4", "name": "Test2",
"source_mapping": { "source_mapping": {
"start": 290, "start": 58,
"length": 87, "length": 78,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/dead-code/0.8.0/dead-code.sol", "filename_relative": "tests/detectors/dead-code/0.8.0/dead-code.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/dead-code/0.8.0/dead-code.sol", "filename_short": "tests/detectors/dead-code/0.8.0/dead-code.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 8,
26, 9,
27, 10,
28, 11,
29 12,
13
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -161,10 +161,10 @@
} }
} }
], ],
"description": "Test4.unused_but_shadowed() (tests/detectors/dead-code/0.8.0/dead-code.sol#26-28) is never used and should be removed\n", "description": "Test2.unused_but_shadowed() (tests/detectors/dead-code/0.8.0/dead-code.sol#10-12) is never used and should be removed\n",
"markdown": "[Test4.unused_but_shadowed()](tests/detectors/dead-code/0.8.0/dead-code.sol#L26-L28) is never used and should be removed\n", "markdown": "[Test2.unused_but_shadowed()](tests/detectors/dead-code/0.8.0/dead-code.sol#L10-L12) is never used and should be removed\n",
"first_markdown_element": "tests/detectors/dead-code/0.8.0/dead-code.sol#L26-L28", "first_markdown_element": "tests/detectors/dead-code/0.8.0/dead-code.sol#L10-L12",
"id": "74ea8421cf7fa9e04d243014b61f3eee7a9c7648df98316c3881dd4f1f2ab3f7", "id": "aaba496684b73955e90b555de174e1cd03f0fee337849c4d58c10ef76ff93582",
"check": "dead-code", "check": "dead-code",
"impact": "Informational", "impact": "Informational",
"confidence": "Medium" "confidence": "Medium"

@ -4,21 +4,23 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad", "name": "bad3",
"source_mapping": { "source_mapping": {
"start": 61, "start": 738,
"length": 232, "length": 312,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 25,
6, 26,
7, 27,
8, 28,
9 29,
30,
31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -75,14 +77,14 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad(address[])" "signature": "bad3(address[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))", "name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))",
"source_mapping": { "source_mapping": {
"start": 188, "start": 931,
"length": 88, "length": 88,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol",
@ -90,29 +92,31 @@
"filename_short": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 28
], ],
"starting_column": 13, "starting_column": 17,
"ending_column": 101 "ending_column": 105
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad", "name": "bad3",
"source_mapping": { "source_mapping": {
"start": 61, "start": 738,
"length": 232, "length": 312,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 25,
6, 26,
7, 27,
8, 28,
9 29,
30,
31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -169,16 +173,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad(address[])" "signature": "bad3(address[])"
} }
} }
} }
} }
], ],
"description": "C.bad(address[]) (tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#5-9) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#7)\n", "description": "C.bad3(address[]) (tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#25-31) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#28)\n",
"markdown": "[C.bad(address[])](tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#L5-L9) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#L7)\n", "markdown": "[C.bad3(address[])](tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#L25-L31) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#L28)\n",
"first_markdown_element": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#L5-L9", "first_markdown_element": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#L25-L31",
"id": "e057dff3814f9be2d5eca53fe80f41323b8ed90d20bb1e33600bb4e043c40b66", "id": "77dda07eb6e2fe62ccfc45730422fa556ee775c1f6686148258f1ccc76c86491",
"check": "delegatecall-loop", "check": "delegatecall-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -370,23 +374,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad3", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 738, "start": 61,
"length": 312, "length": 232,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 5,
26, 6,
27, 7,
28, 8,
29, 9
30,
31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -443,14 +445,14 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad3(address[])" "signature": "bad(address[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))", "name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))",
"source_mapping": { "source_mapping": {
"start": 931, "start": 188,
"length": 88, "length": 88,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol",
@ -458,31 +460,29 @@
"filename_short": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28 7
], ],
"starting_column": 17, "starting_column": 13,
"ending_column": 105 "ending_column": 101
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 738, "start": 61,
"length": 312, "length": 232,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 5,
26, 6,
27, 7,
28, 8,
29, 9
30,
31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -539,16 +539,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad3(address[])" "signature": "bad(address[])"
} }
} }
} }
} }
], ],
"description": "C.bad3(address[]) (tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#25-31) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#28)\n", "description": "C.bad(address[]) (tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#5-9) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#7)\n",
"markdown": "[C.bad3(address[])](tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#L25-L31) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#L28)\n", "markdown": "[C.bad(address[])](tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#L5-L9) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#L7)\n",
"first_markdown_element": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#L25-L31", "first_markdown_element": "tests/detectors/delegatecall-loop/0.4.25/delegatecall_loop.sol#L5-L9",
"id": "77dda07eb6e2fe62ccfc45730422fa556ee775c1f6686148258f1ccc76c86491", "id": "e057dff3814f9be2d5eca53fe80f41323b8ed90d20bb1e33600bb4e043c40b66",
"check": "delegatecall-loop", "check": "delegatecall-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -4,21 +4,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad", "name": "bad2_internal",
"source_mapping": { "source_mapping": {
"start": 61, "start": 496,
"length": 232, "length": 236,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 19,
6, 20,
7, 21,
8, 22,
9 23
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -75,14 +75,14 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad(address[])" "signature": "bad2_internal(address[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))", "name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))",
"source_mapping": { "source_mapping": {
"start": 188, "start": 627,
"length": 88, "length": 88,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol",
@ -90,7 +90,7 @@
"filename_short": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 21
], ],
"starting_column": 13, "starting_column": 13,
"ending_column": 101 "ending_column": 101
@ -98,21 +98,21 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad", "name": "bad2_internal",
"source_mapping": { "source_mapping": {
"start": 61, "start": 496,
"length": 232, "length": 236,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 19,
6, 20,
7, 21,
8, 22,
9 23
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -169,16 +169,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad(address[])" "signature": "bad2_internal(address[])"
} }
} }
} }
} }
], ],
"description": "C.bad(address[]) (tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#5-9) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#7)\n", "description": "C.bad2_internal(address[]) (tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#19-23) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#21)\n",
"markdown": "[C.bad(address[])](tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#L5-L9) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#L7)\n", "markdown": "[C.bad2_internal(address[])](tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#L19-L23) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#L21)\n",
"first_markdown_element": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#L5-L9", "first_markdown_element": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#L19-L23",
"id": "dfa0a166dfe43235e3fbeab4eadd8b0c7c612cd2fefe3cf281d909129b3b824e", "id": "50e1b9196dcf1e1d7678184956c7a9d3ba470ab23d7be04163d366b092e2df41",
"check": "delegatecall-loop", "check": "delegatecall-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -187,21 +187,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2_internal", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 496, "start": 61,
"length": 236, "length": 232,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 5,
20, 6,
21, 7,
22, 8,
23 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -258,14 +258,14 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad2_internal(address[])" "signature": "bad(address[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))", "name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))",
"source_mapping": { "source_mapping": {
"start": 627, "start": 188,
"length": 88, "length": 88,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol",
@ -273,7 +273,7 @@
"filename_short": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
21 7
], ],
"starting_column": 13, "starting_column": 13,
"ending_column": 101 "ending_column": 101
@ -281,21 +281,21 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_internal", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 496, "start": 61,
"length": 236, "length": 232,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 5,
20, 6,
21, 7,
22, 8,
23 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -352,16 +352,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad2_internal(address[])" "signature": "bad(address[])"
} }
} }
} }
} }
], ],
"description": "C.bad2_internal(address[]) (tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#19-23) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#21)\n", "description": "C.bad(address[]) (tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#5-9) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#7)\n",
"markdown": "[C.bad2_internal(address[])](tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#L19-L23) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#L21)\n", "markdown": "[C.bad(address[])](tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#L5-L9) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#L7)\n",
"first_markdown_element": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#L19-L23", "first_markdown_element": "tests/detectors/delegatecall-loop/0.6.11/delegatecall_loop.sol#L5-L9",
"id": "50e1b9196dcf1e1d7678184956c7a9d3ba470ab23d7be04163d366b092e2df41", "id": "dfa0a166dfe43235e3fbeab4eadd8b0c7c612cd2fefe3cf281d909129b3b824e",
"check": "delegatecall-loop", "check": "delegatecall-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -187,21 +187,23 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2_internal", "name": "bad3",
"source_mapping": { "source_mapping": {
"start": 496, "start": 738,
"length": 236, "length": 312,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 25,
20, 26,
21, 27,
22, 28,
23 29,
30,
31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -258,14 +260,14 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad2_internal(address[])" "signature": "bad3(address[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))", "name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))",
"source_mapping": { "source_mapping": {
"start": 627, "start": 931,
"length": 88, "length": 88,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol",
@ -273,29 +275,31 @@
"filename_short": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
21 28
], ],
"starting_column": 13, "starting_column": 17,
"ending_column": 101 "ending_column": 105
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_internal", "name": "bad3",
"source_mapping": { "source_mapping": {
"start": 496, "start": 738,
"length": 236, "length": 312,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 25,
20, 26,
21, 27,
22, 28,
23 29,
30,
31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -352,16 +356,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad2_internal(address[])" "signature": "bad3(address[])"
} }
} }
} }
} }
], ],
"description": "C.bad2_internal(address[]) (tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#19-23) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#21)\n", "description": "C.bad3(address[]) (tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#25-31) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#28)\n",
"markdown": "[C.bad2_internal(address[])](tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#L19-L23) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#L21)\n", "markdown": "[C.bad3(address[])](tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#L25-L31) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#L28)\n",
"first_markdown_element": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#L19-L23", "first_markdown_element": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#L25-L31",
"id": "a7f58e5431f4817c8f3e39d7efdb1b1633316d9be3fd73669e509ec33b6bd2d3", "id": "40cecf9f87caeb930a800e6eb9c668fd6ca5077af3176e48af13c4892bcaf419",
"check": "delegatecall-loop", "check": "delegatecall-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -370,23 +374,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad3", "name": "bad2_internal",
"source_mapping": { "source_mapping": {
"start": 738, "start": 496,
"length": 312, "length": 236,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 19,
26, 20,
27, 21,
28, 22,
29, 23
30,
31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -443,14 +445,14 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad3(address[])" "signature": "bad2_internal(address[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))", "name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))",
"source_mapping": { "source_mapping": {
"start": 931, "start": 627,
"length": 88, "length": 88,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol",
@ -458,31 +460,29 @@
"filename_short": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28 21
], ],
"starting_column": 17, "starting_column": 13,
"ending_column": 105 "ending_column": 101
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3", "name": "bad2_internal",
"source_mapping": { "source_mapping": {
"start": 738, "start": 496,
"length": 312, "length": 236,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 19,
26, 20,
27, 21,
28, 22,
29, 23
30,
31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -539,16 +539,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad3(address[])" "signature": "bad2_internal(address[])"
} }
} }
} }
} }
], ],
"description": "C.bad3(address[]) (tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#25-31) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#28)\n", "description": "C.bad2_internal(address[]) (tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#19-23) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#21)\n",
"markdown": "[C.bad3(address[])](tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#L25-L31) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#L28)\n", "markdown": "[C.bad2_internal(address[])](tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#L19-L23) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#L21)\n",
"first_markdown_element": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#L25-L31", "first_markdown_element": "tests/detectors/delegatecall-loop/0.7.6/delegatecall_loop.sol#L19-L23",
"id": "40cecf9f87caeb930a800e6eb9c668fd6ca5077af3176e48af13c4892bcaf419", "id": "a7f58e5431f4817c8f3e39d7efdb1b1633316d9be3fd73669e509ec33b6bd2d3",
"check": "delegatecall-loop", "check": "delegatecall-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -4,21 +4,23 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad", "name": "bad3",
"source_mapping": { "source_mapping": {
"start": 61, "start": 738,
"length": 232, "length": 312,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 25,
6, 26,
7, 27,
8, 28,
9 29,
30,
31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -75,14 +77,14 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad(address[])" "signature": "bad3(address[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))", "name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))",
"source_mapping": { "source_mapping": {
"start": 188, "start": 931,
"length": 88, "length": 88,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
@ -90,29 +92,31 @@
"filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 28
], ],
"starting_column": 13, "starting_column": 17,
"ending_column": 101 "ending_column": 105
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad", "name": "bad3",
"source_mapping": { "source_mapping": {
"start": 61, "start": 738,
"length": 232, "length": 312,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 25,
6, 26,
7, 27,
8, 28,
9 29,
30,
31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -169,16 +173,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad(address[])" "signature": "bad3(address[])"
} }
} }
} }
} }
], ],
"description": "C.bad(address[]) (tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#5-9) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#7)\n", "description": "C.bad3(address[]) (tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#25-31) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#28)\n",
"markdown": "[C.bad(address[])](tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L5-L9) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L7)\n", "markdown": "[C.bad3(address[])](tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L25-L31) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L28)\n",
"first_markdown_element": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L5-L9", "first_markdown_element": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L25-L31",
"id": "b810117268c82cb0e2ba1fce4549cef820197f59c877fd5f0701661a0f7bbf47", "id": "0bacdb8b28979c680bd97f07b6a7e17d687dde34b125b23d9d71514d37d5e863",
"check": "delegatecall-loop", "check": "delegatecall-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -187,21 +191,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2_internal", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 496, "start": 61,
"length": 236, "length": 232,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 5,
20, 6,
21, 7,
22, 8,
23 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -258,14 +262,14 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad2_internal(address[])" "signature": "bad(address[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))", "name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))",
"source_mapping": { "source_mapping": {
"start": 627, "start": 188,
"length": 88, "length": 88,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
@ -273,7 +277,7 @@
"filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
21 7
], ],
"starting_column": 13, "starting_column": 13,
"ending_column": 101 "ending_column": 101
@ -281,21 +285,21 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_internal", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 496, "start": 61,
"length": 236, "length": 232,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 5,
20, 6,
21, 7,
22, 8,
23 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -352,16 +356,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad2_internal(address[])" "signature": "bad(address[])"
} }
} }
} }
} }
], ],
"description": "C.bad2_internal(address[]) (tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#19-23) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#21)\n", "description": "C.bad(address[]) (tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#5-9) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#7)\n",
"markdown": "[C.bad2_internal(address[])](tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L19-L23) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L21)\n", "markdown": "[C.bad(address[])](tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L5-L9) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L7)\n",
"first_markdown_element": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L19-L23", "first_markdown_element": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L5-L9",
"id": "c09bee70334dcac1e61b8295e12f2928ec522c8a0682f6068e6c283361ab1e59", "id": "b810117268c82cb0e2ba1fce4549cef820197f59c877fd5f0701661a0f7bbf47",
"check": "delegatecall-loop", "check": "delegatecall-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -370,23 +374,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad3", "name": "bad2_internal",
"source_mapping": { "source_mapping": {
"start": 738, "start": 496,
"length": 312, "length": 236,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 19,
26, 20,
27, 21,
28, 22,
29, 23
30,
31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -443,14 +445,14 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad3(address[])" "signature": "bad2_internal(address[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))", "name": "address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))",
"source_mapping": { "source_mapping": {
"start": 931, "start": 627,
"length": 88, "length": 88,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
@ -458,31 +460,29 @@
"filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28 21
], ],
"starting_column": 17, "starting_column": 13,
"ending_column": 105 "ending_column": 101
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3", "name": "bad2_internal",
"source_mapping": { "source_mapping": {
"start": 738, "start": 496,
"length": 312, "length": 236,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_relative": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol", "filename_short": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 19,
26, 20,
27, 21,
28, 22,
29, 23
30,
31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -539,16 +539,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad3(address[])" "signature": "bad2_internal(address[])"
} }
} }
} }
} }
], ],
"description": "C.bad3(address[]) (tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#25-31) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#28)\n", "description": "C.bad2_internal(address[]) (tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#19-23) has delegatecall inside a loop in a payable function: address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i])) (tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#21)\n",
"markdown": "[C.bad3(address[])](tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L25-L31) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L28)\n", "markdown": "[C.bad2_internal(address[])](tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L19-L23) has delegatecall inside a loop in a payable function: [address(this).delegatecall(abi.encodeWithSignature(addBalance(address),receivers[i]))](tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L21)\n",
"first_markdown_element": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L25-L31", "first_markdown_element": "tests/detectors/delegatecall-loop/0.8.0/delegatecall_loop.sol#L19-L23",
"id": "0bacdb8b28979c680bd97f07b6a7e17d687dde34b125b23d9d71514d37d5e863", "id": "c09bee70334dcac1e61b8295e12f2928ec522c8a0682f6068e6c283361ab1e59",
"check": "delegatecall-loop", "check": "delegatecall-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -50,14 +50,14 @@
"signature": "Transfer(address,address,uint256)" "signature": "Transfer(address,address,uint256)"
}, },
"additional_fields": { "additional_fields": {
"parameter_name": "from" "parameter_name": "to"
} }
} }
], ],
"description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#19)does not index parameter from\n", "description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#19)does not index parameter to\n",
"markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#L19)does not index parameter from\n", "markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#L19)does not index parameter to\n",
"first_markdown_element": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#L19", "first_markdown_element": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#L19",
"id": "a86c7a54115f270548e82d71570dc4d2900b622b0f82c6fce137f3a35314af53", "id": "29c46eb3a4695004959847ae09377729cdf3aa583de95560090b9bd49977c49b",
"check": "erc20-indexed", "check": "erc20-indexed",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -66,20 +66,20 @@
"elements": [ "elements": [
{ {
"type": "event", "type": "event",
"name": "Transfer", "name": "Approval",
"source_mapping": { "source_mapping": {
"start": 1090, "start": 1148,
"length": 53, "length": 59,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol", "filename_relative": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol", "filename_short": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 58 "ending_column": 64
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -109,17 +109,17 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "Transfer(address,address,uint256)" "signature": "Approval(address,address,uint256)"
}, },
"additional_fields": { "additional_fields": {
"parameter_name": "to" "parameter_name": "owner"
} }
} }
], ],
"description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#19)does not index parameter to\n", "description": "ERC20 event IERC20BadApproval(address,address,uint256) (tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#20)does not index parameter owner\n",
"markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#L19)does not index parameter to\n", "markdown": "ERC20 event [IERC20BadApproval(address,address,uint256)](tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#L20)does not index parameter owner\n",
"first_markdown_element": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#L19", "first_markdown_element": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#L20",
"id": "29c46eb3a4695004959847ae09377729cdf3aa583de95560090b9bd49977c49b", "id": "7d72b56a71ca96db304878f25484c496af1d283a9b777dc788f1473974057025",
"check": "erc20-indexed", "check": "erc20-indexed",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -128,20 +128,20 @@
"elements": [ "elements": [
{ {
"type": "event", "type": "event",
"name": "Approval", "name": "Transfer",
"source_mapping": { "source_mapping": {
"start": 1148, "start": 1090,
"length": 59, "length": 53,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol", "filename_relative": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol", "filename_short": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 19
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 64 "ending_column": 58
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -171,17 +171,17 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "Approval(address,address,uint256)" "signature": "Transfer(address,address,uint256)"
}, },
"additional_fields": { "additional_fields": {
"parameter_name": "owner" "parameter_name": "from"
} }
} }
], ],
"description": "ERC20 event IERC20BadApproval(address,address,uint256) (tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#20)does not index parameter owner\n", "description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#19)does not index parameter from\n",
"markdown": "ERC20 event [IERC20BadApproval(address,address,uint256)](tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#L20)does not index parameter owner\n", "markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#L19)does not index parameter from\n",
"first_markdown_element": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#L20", "first_markdown_element": "tests/detectors/erc20-indexed/0.4.25/erc20_indexed.sol#L19",
"id": "7d72b56a71ca96db304878f25484c496af1d283a9b777dc788f1473974057025", "id": "a86c7a54115f270548e82d71570dc4d2900b622b0f82c6fce137f3a35314af53",
"check": "erc20-indexed", "check": "erc20-indexed",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -50,14 +50,14 @@
"signature": "Transfer(address,address,uint256)" "signature": "Transfer(address,address,uint256)"
}, },
"additional_fields": { "additional_fields": {
"parameter_name": "from" "parameter_name": "to"
} }
} }
], ],
"description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#19)does not index parameter from\n", "description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#19)does not index parameter to\n",
"markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#L19)does not index parameter from\n", "markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#L19)does not index parameter to\n",
"first_markdown_element": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#L19", "first_markdown_element": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#L19",
"id": "a86c7a54115f270548e82d71570dc4d2900b622b0f82c6fce137f3a35314af53", "id": "29c46eb3a4695004959847ae09377729cdf3aa583de95560090b9bd49977c49b",
"check": "erc20-indexed", "check": "erc20-indexed",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -66,20 +66,20 @@
"elements": [ "elements": [
{ {
"type": "event", "type": "event",
"name": "Transfer", "name": "Approval",
"source_mapping": { "source_mapping": {
"start": 1090, "start": 1148,
"length": 53, "length": 59,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol", "filename_relative": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol", "filename_short": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 58 "ending_column": 64
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -109,17 +109,17 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "Transfer(address,address,uint256)" "signature": "Approval(address,address,uint256)"
}, },
"additional_fields": { "additional_fields": {
"parameter_name": "to" "parameter_name": "owner"
} }
} }
], ],
"description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#19)does not index parameter to\n", "description": "ERC20 event IERC20BadApproval(address,address,uint256) (tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#20)does not index parameter owner\n",
"markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#L19)does not index parameter to\n", "markdown": "ERC20 event [IERC20BadApproval(address,address,uint256)](tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#L20)does not index parameter owner\n",
"first_markdown_element": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#L19", "first_markdown_element": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#L20",
"id": "29c46eb3a4695004959847ae09377729cdf3aa583de95560090b9bd49977c49b", "id": "7d72b56a71ca96db304878f25484c496af1d283a9b777dc788f1473974057025",
"check": "erc20-indexed", "check": "erc20-indexed",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -128,20 +128,20 @@
"elements": [ "elements": [
{ {
"type": "event", "type": "event",
"name": "Approval", "name": "Transfer",
"source_mapping": { "source_mapping": {
"start": 1148, "start": 1090,
"length": 59, "length": 53,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol", "filename_relative": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol", "filename_short": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 19
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 64 "ending_column": 58
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -171,17 +171,17 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "Approval(address,address,uint256)" "signature": "Transfer(address,address,uint256)"
}, },
"additional_fields": { "additional_fields": {
"parameter_name": "owner" "parameter_name": "from"
} }
} }
], ],
"description": "ERC20 event IERC20BadApproval(address,address,uint256) (tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#20)does not index parameter owner\n", "description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#19)does not index parameter from\n",
"markdown": "ERC20 event [IERC20BadApproval(address,address,uint256)](tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#L20)does not index parameter owner\n", "markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#L19)does not index parameter from\n",
"first_markdown_element": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#L20", "first_markdown_element": "tests/detectors/erc20-indexed/0.5.16/erc20_indexed.sol#L19",
"id": "7d72b56a71ca96db304878f25484c496af1d283a9b777dc788f1473974057025", "id": "a86c7a54115f270548e82d71570dc4d2900b622b0f82c6fce137f3a35314af53",
"check": "erc20-indexed", "check": "erc20-indexed",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -50,14 +50,14 @@
"signature": "Transfer(address,address,uint256)" "signature": "Transfer(address,address,uint256)"
}, },
"additional_fields": { "additional_fields": {
"parameter_name": "from" "parameter_name": "to"
} }
} }
], ],
"description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#19)does not index parameter from\n", "description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#19)does not index parameter to\n",
"markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#L19)does not index parameter from\n", "markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#L19)does not index parameter to\n",
"first_markdown_element": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#L19", "first_markdown_element": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#L19",
"id": "a86c7a54115f270548e82d71570dc4d2900b622b0f82c6fce137f3a35314af53", "id": "29c46eb3a4695004959847ae09377729cdf3aa583de95560090b9bd49977c49b",
"check": "erc20-indexed", "check": "erc20-indexed",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -66,20 +66,20 @@
"elements": [ "elements": [
{ {
"type": "event", "type": "event",
"name": "Transfer", "name": "Approval",
"source_mapping": { "source_mapping": {
"start": 1204, "start": 1262,
"length": 53, "length": 59,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol", "filename_relative": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol", "filename_short": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 58 "ending_column": 64
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -109,17 +109,17 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "Transfer(address,address,uint256)" "signature": "Approval(address,address,uint256)"
}, },
"additional_fields": { "additional_fields": {
"parameter_name": "to" "parameter_name": "owner"
} }
} }
], ],
"description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#19)does not index parameter to\n", "description": "ERC20 event IERC20BadApproval(address,address,uint256) (tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#20)does not index parameter owner\n",
"markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#L19)does not index parameter to\n", "markdown": "ERC20 event [IERC20BadApproval(address,address,uint256)](tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#L20)does not index parameter owner\n",
"first_markdown_element": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#L19", "first_markdown_element": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#L20",
"id": "29c46eb3a4695004959847ae09377729cdf3aa583de95560090b9bd49977c49b", "id": "7d72b56a71ca96db304878f25484c496af1d283a9b777dc788f1473974057025",
"check": "erc20-indexed", "check": "erc20-indexed",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -128,20 +128,20 @@
"elements": [ "elements": [
{ {
"type": "event", "type": "event",
"name": "Approval", "name": "Transfer",
"source_mapping": { "source_mapping": {
"start": 1262, "start": 1204,
"length": 59, "length": 53,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol", "filename_relative": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol", "filename_short": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 19
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 64 "ending_column": 58
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -171,17 +171,17 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "Approval(address,address,uint256)" "signature": "Transfer(address,address,uint256)"
}, },
"additional_fields": { "additional_fields": {
"parameter_name": "owner" "parameter_name": "from"
} }
} }
], ],
"description": "ERC20 event IERC20BadApproval(address,address,uint256) (tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#20)does not index parameter owner\n", "description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#19)does not index parameter from\n",
"markdown": "ERC20 event [IERC20BadApproval(address,address,uint256)](tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#L20)does not index parameter owner\n", "markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#L19)does not index parameter from\n",
"first_markdown_element": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#L20", "first_markdown_element": "tests/detectors/erc20-indexed/0.6.11/erc20_indexed.sol#L19",
"id": "7d72b56a71ca96db304878f25484c496af1d283a9b777dc788f1473974057025", "id": "a86c7a54115f270548e82d71570dc4d2900b622b0f82c6fce137f3a35314af53",
"check": "erc20-indexed", "check": "erc20-indexed",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -50,14 +50,14 @@
"signature": "Transfer(address,address,uint256)" "signature": "Transfer(address,address,uint256)"
}, },
"additional_fields": { "additional_fields": {
"parameter_name": "from" "parameter_name": "to"
} }
} }
], ],
"description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#19)does not index parameter from\n", "description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#19)does not index parameter to\n",
"markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#L19)does not index parameter from\n", "markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#L19)does not index parameter to\n",
"first_markdown_element": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#L19", "first_markdown_element": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#L19",
"id": "a86c7a54115f270548e82d71570dc4d2900b622b0f82c6fce137f3a35314af53", "id": "29c46eb3a4695004959847ae09377729cdf3aa583de95560090b9bd49977c49b",
"check": "erc20-indexed", "check": "erc20-indexed",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -66,20 +66,20 @@
"elements": [ "elements": [
{ {
"type": "event", "type": "event",
"name": "Transfer", "name": "Approval",
"source_mapping": { "source_mapping": {
"start": 1204, "start": 1262,
"length": 53, "length": 59,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol", "filename_relative": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol", "filename_short": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 58 "ending_column": 64
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -109,17 +109,17 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "Transfer(address,address,uint256)" "signature": "Approval(address,address,uint256)"
}, },
"additional_fields": { "additional_fields": {
"parameter_name": "to" "parameter_name": "owner"
} }
} }
], ],
"description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#19)does not index parameter to\n", "description": "ERC20 event IERC20BadApproval(address,address,uint256) (tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#20)does not index parameter owner\n",
"markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#L19)does not index parameter to\n", "markdown": "ERC20 event [IERC20BadApproval(address,address,uint256)](tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#L20)does not index parameter owner\n",
"first_markdown_element": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#L19", "first_markdown_element": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#L20",
"id": "29c46eb3a4695004959847ae09377729cdf3aa583de95560090b9bd49977c49b", "id": "7d72b56a71ca96db304878f25484c496af1d283a9b777dc788f1473974057025",
"check": "erc20-indexed", "check": "erc20-indexed",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -128,20 +128,20 @@
"elements": [ "elements": [
{ {
"type": "event", "type": "event",
"name": "Approval", "name": "Transfer",
"source_mapping": { "source_mapping": {
"start": 1262, "start": 1204,
"length": 59, "length": 53,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol", "filename_relative": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol", "filename_short": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 19
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 64 "ending_column": 58
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -171,17 +171,17 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "Approval(address,address,uint256)" "signature": "Transfer(address,address,uint256)"
}, },
"additional_fields": { "additional_fields": {
"parameter_name": "owner" "parameter_name": "from"
} }
} }
], ],
"description": "ERC20 event IERC20BadApproval(address,address,uint256) (tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#20)does not index parameter owner\n", "description": "ERC20 event IERC20BadTransfer(address,address,uint256) (tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#19)does not index parameter from\n",
"markdown": "ERC20 event [IERC20BadApproval(address,address,uint256)](tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#L20)does not index parameter owner\n", "markdown": "ERC20 event [IERC20BadTransfer(address,address,uint256)](tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#L19)does not index parameter from\n",
"first_markdown_element": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#L20", "first_markdown_element": "tests/detectors/erc20-indexed/0.7.6/erc20_indexed.sol#L19",
"id": "7d72b56a71ca96db304878f25484c496af1d283a9b777dc788f1473974057025", "id": "a86c7a54115f270548e82d71570dc4d2900b622b0f82c6fce137f3a35314af53",
"check": "erc20-indexed", "check": "erc20-indexed",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -29,20 +29,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "transfer", "name": "approve",
"source_mapping": { "source_mapping": {
"start": 46, "start": 102,
"length": 51, "length": 55,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
4 5
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 56 "ending_column": 60
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -70,14 +70,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "transfer(address,uint256)" "signature": "approve(address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transfer(address,uint256) (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#4)\n", "description": "Token (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.approve(address,uint256) (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#5)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transfer(address,uint256)](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L4)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.approve(address,uint256)](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L5)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10",
"id": "d3df2e48ae6e8a1b05b275de574b480853a0839c272ce889e8a1664ae432698e", "id": "0fced3029cf59cf348a6b79c58dbb032d837fdd5a5f355600edebda1878e9e2e",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -111,20 +111,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "approve", "name": "allowance",
"source_mapping": { "source_mapping": {
"start": 102, "start": 319,
"length": 55, "length": 60,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 60 "ending_column": 65
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -152,14 +152,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "approve(address,uint256)" "signature": "allowance(address,address)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.approve(address,uint256) (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#5)\n", "description": "Token (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.allowance(address,address) (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#9)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.approve(address,uint256)](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L5)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.allowance(address,address)](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L9)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10",
"id": "0fced3029cf59cf348a6b79c58dbb032d837fdd5a5f355600edebda1878e9e2e", "id": "1286abfe21b09e21e1cec8b991f73664e104fa39f7f4190690ece3af45bc0c7a",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -193,20 +193,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "transferFrom", "name": "balanceOf",
"source_mapping": { "source_mapping": {
"start": 162, "start": 273,
"length": 69, "length": 41,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6 8
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 74 "ending_column": 46
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -234,14 +234,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "transferFrom(address,address,uint256)" "signature": "balanceOf(address)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transferFrom(address,address,uint256) (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#6)\n", "description": "Token (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.balanceOf(address) (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#8)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transferFrom(address,address,uint256)](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L6)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.balanceOf(address)](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L8)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10",
"id": "ba13a1588595032984a3fad39610a2414bb8fcb522d1e632d52fa947ff207d73", "id": "758ca2456030a36dbd6115f2ccb1a43f53f1dabd66ed079806df0f6b7b4d21ef",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -275,20 +275,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "totalSupply", "name": "transferFrom",
"source_mapping": { "source_mapping": {
"start": 236, "start": 162,
"length": 32, "length": 69,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 6
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 37 "ending_column": 74
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -316,14 +316,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "totalSupply()" "signature": "transferFrom(address,address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.totalSupply() (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#7)\n", "description": "Token (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transferFrom(address,address,uint256) (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#6)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.totalSupply()](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L7)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transferFrom(address,address,uint256)](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L6)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10",
"id": "c951e429e546af28ac08e241d391e874c1c9c70b0732ccfb63f3bbfb3eaac16e", "id": "ba13a1588595032984a3fad39610a2414bb8fcb522d1e632d52fa947ff207d73",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -357,20 +357,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "balanceOf", "name": "totalSupply",
"source_mapping": { "source_mapping": {
"start": 273, "start": 236,
"length": 41, "length": 32,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 46 "ending_column": 37
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -398,14 +398,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "balanceOf(address)" "signature": "totalSupply()"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.balanceOf(address) (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#8)\n", "description": "Token (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.totalSupply() (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#7)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.balanceOf(address)](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L8)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.totalSupply()](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L7)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10",
"id": "758ca2456030a36dbd6115f2ccb1a43f53f1dabd66ed079806df0f6b7b4d21ef", "id": "c951e429e546af28ac08e241d391e874c1c9c70b0732ccfb63f3bbfb3eaac16e",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -439,20 +439,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "allowance", "name": "transfer",
"source_mapping": { "source_mapping": {
"start": 319, "start": 46,
"length": 60, "length": 51,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9 4
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 65 "ending_column": 56
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -480,14 +480,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "allowance(address,address)" "signature": "transfer(address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.allowance(address,address) (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#9)\n", "description": "Token (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transfer(address,uint256) (tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#4)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.allowance(address,address)](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L9)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transfer(address,uint256)](tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L4)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.4.25/incorrect_erc20_interface.sol#L3-L10",
"id": "1286abfe21b09e21e1cec8b991f73664e104fa39f7f4190690ece3af45bc0c7a", "id": "d3df2e48ae6e8a1b05b275de574b480853a0839c272ce889e8a1664ae432698e",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"

@ -29,20 +29,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "transfer", "name": "approve",
"source_mapping": { "source_mapping": {
"start": 49, "start": 105,
"length": 51, "length": 55,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
4 5
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 56 "ending_column": 60
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -70,14 +70,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "transfer(address,uint256)" "signature": "approve(address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transfer(address,uint256) (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#4)\n", "description": "Token (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.approve(address,uint256) (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#5)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transfer(address,uint256)](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L4)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.approve(address,uint256)](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L5)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10",
"id": "d3df2e48ae6e8a1b05b275de574b480853a0839c272ce889e8a1664ae432698e", "id": "0fced3029cf59cf348a6b79c58dbb032d837fdd5a5f355600edebda1878e9e2e",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -111,20 +111,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "approve", "name": "allowance",
"source_mapping": { "source_mapping": {
"start": 105, "start": 322,
"length": 55, "length": 60,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 60 "ending_column": 65
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -152,14 +152,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "approve(address,uint256)" "signature": "allowance(address,address)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.approve(address,uint256) (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#5)\n", "description": "Token (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.allowance(address,address) (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#9)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.approve(address,uint256)](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L5)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.allowance(address,address)](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L9)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10",
"id": "0fced3029cf59cf348a6b79c58dbb032d837fdd5a5f355600edebda1878e9e2e", "id": "1286abfe21b09e21e1cec8b991f73664e104fa39f7f4190690ece3af45bc0c7a",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -193,20 +193,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "transferFrom", "name": "balanceOf",
"source_mapping": { "source_mapping": {
"start": 165, "start": 276,
"length": 69, "length": 41,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6 8
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 74 "ending_column": 46
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -234,14 +234,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "transferFrom(address,address,uint256)" "signature": "balanceOf(address)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transferFrom(address,address,uint256) (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#6)\n", "description": "Token (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.balanceOf(address) (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#8)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transferFrom(address,address,uint256)](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L6)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.balanceOf(address)](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L8)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10",
"id": "ba13a1588595032984a3fad39610a2414bb8fcb522d1e632d52fa947ff207d73", "id": "758ca2456030a36dbd6115f2ccb1a43f53f1dabd66ed079806df0f6b7b4d21ef",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -275,20 +275,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "totalSupply", "name": "transferFrom",
"source_mapping": { "source_mapping": {
"start": 239, "start": 165,
"length": 32, "length": 69,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 6
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 37 "ending_column": 74
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -316,14 +316,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "totalSupply()" "signature": "transferFrom(address,address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.totalSupply() (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#7)\n", "description": "Token (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transferFrom(address,address,uint256) (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#6)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.totalSupply()](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L7)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transferFrom(address,address,uint256)](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L6)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10",
"id": "c951e429e546af28ac08e241d391e874c1c9c70b0732ccfb63f3bbfb3eaac16e", "id": "ba13a1588595032984a3fad39610a2414bb8fcb522d1e632d52fa947ff207d73",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -357,20 +357,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "balanceOf", "name": "totalSupply",
"source_mapping": { "source_mapping": {
"start": 276, "start": 239,
"length": 41, "length": 32,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 46 "ending_column": 37
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -398,14 +398,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "balanceOf(address)" "signature": "totalSupply()"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.balanceOf(address) (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#8)\n", "description": "Token (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.totalSupply() (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#7)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.balanceOf(address)](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L8)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.totalSupply()](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L7)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10",
"id": "758ca2456030a36dbd6115f2ccb1a43f53f1dabd66ed079806df0f6b7b4d21ef", "id": "c951e429e546af28ac08e241d391e874c1c9c70b0732ccfb63f3bbfb3eaac16e",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -439,20 +439,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "allowance", "name": "transfer",
"source_mapping": { "source_mapping": {
"start": 322, "start": 49,
"length": 60, "length": 51,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9 4
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 65 "ending_column": 56
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -480,14 +480,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "allowance(address,address)" "signature": "transfer(address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.allowance(address,address) (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#9)\n", "description": "Token (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transfer(address,uint256) (tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#4)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.allowance(address,address)](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L9)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transfer(address,uint256)](tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L4)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.5.16/incorrect_erc20_interface.sol#L3-L10",
"id": "1286abfe21b09e21e1cec8b991f73664e104fa39f7f4190690ece3af45bc0c7a", "id": "d3df2e48ae6e8a1b05b275de574b480853a0839c272ce889e8a1664ae432698e",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"

@ -29,20 +29,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "transfer", "name": "approve",
"source_mapping": { "source_mapping": {
"start": 58, "start": 122,
"length": 59, "length": 63,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
4 5
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 64 "ending_column": 68
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -70,14 +70,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "transfer(address,uint256)" "signature": "approve(address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transfer(address,uint256) (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#4)\n", "description": "Token (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.approve(address,uint256) (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#5)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transfer(address,uint256)](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L4)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.approve(address,uint256)](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L5)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10",
"id": "d3df2e48ae6e8a1b05b275de574b480853a0839c272ce889e8a1664ae432698e", "id": "0fced3029cf59cf348a6b79c58dbb032d837fdd5a5f355600edebda1878e9e2e",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -111,20 +111,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "approve", "name": "allowance",
"source_mapping": { "source_mapping": {
"start": 122, "start": 371,
"length": 63, "length": 68,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 68 "ending_column": 73
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -152,14 +152,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "approve(address,uint256)" "signature": "allowance(address,address)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.approve(address,uint256) (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#5)\n", "description": "Token (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.allowance(address,address) (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#9)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.approve(address,uint256)](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L5)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.allowance(address,address)](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L9)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10",
"id": "0fced3029cf59cf348a6b79c58dbb032d837fdd5a5f355600edebda1878e9e2e", "id": "1286abfe21b09e21e1cec8b991f73664e104fa39f7f4190690ece3af45bc0c7a",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -193,20 +193,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "transferFrom", "name": "balanceOf",
"source_mapping": { "source_mapping": {
"start": 190, "start": 317,
"length": 77, "length": 49,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6 8
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 82 "ending_column": 54
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -234,14 +234,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "transferFrom(address,address,uint256)" "signature": "balanceOf(address)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transferFrom(address,address,uint256) (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#6)\n", "description": "Token (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.balanceOf(address) (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#8)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transferFrom(address,address,uint256)](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L6)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.balanceOf(address)](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L8)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10",
"id": "ba13a1588595032984a3fad39610a2414bb8fcb522d1e632d52fa947ff207d73", "id": "758ca2456030a36dbd6115f2ccb1a43f53f1dabd66ed079806df0f6b7b4d21ef",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -275,20 +275,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "totalSupply", "name": "transferFrom",
"source_mapping": { "source_mapping": {
"start": 272, "start": 190,
"length": 40, "length": 77,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 6
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 45 "ending_column": 82
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -316,14 +316,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "totalSupply()" "signature": "transferFrom(address,address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.totalSupply() (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#7)\n", "description": "Token (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transferFrom(address,address,uint256) (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#6)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.totalSupply()](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L7)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transferFrom(address,address,uint256)](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L6)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10",
"id": "c951e429e546af28ac08e241d391e874c1c9c70b0732ccfb63f3bbfb3eaac16e", "id": "ba13a1588595032984a3fad39610a2414bb8fcb522d1e632d52fa947ff207d73",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -357,20 +357,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "balanceOf", "name": "totalSupply",
"source_mapping": { "source_mapping": {
"start": 317, "start": 272,
"length": 49, "length": 40,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 54 "ending_column": 45
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -398,14 +398,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "balanceOf(address)" "signature": "totalSupply()"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.balanceOf(address) (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#8)\n", "description": "Token (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.totalSupply() (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#7)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.balanceOf(address)](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L8)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.totalSupply()](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L7)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10",
"id": "758ca2456030a36dbd6115f2ccb1a43f53f1dabd66ed079806df0f6b7b4d21ef", "id": "c951e429e546af28ac08e241d391e874c1c9c70b0732ccfb63f3bbfb3eaac16e",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -439,20 +439,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "allowance", "name": "transfer",
"source_mapping": { "source_mapping": {
"start": 371, "start": 58,
"length": 68, "length": 59,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9 4
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 73 "ending_column": 64
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -480,14 +480,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "allowance(address,address)" "signature": "transfer(address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.allowance(address,address) (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#9)\n", "description": "Token (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transfer(address,uint256) (tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#4)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.allowance(address,address)](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L9)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transfer(address,uint256)](tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L4)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.6.11/incorrect_erc20_interface.sol#L3-L10",
"id": "1286abfe21b09e21e1cec8b991f73664e104fa39f7f4190690ece3af45bc0c7a", "id": "d3df2e48ae6e8a1b05b275de574b480853a0839c272ce889e8a1664ae432698e",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"

@ -29,20 +29,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "transfer", "name": "approve",
"source_mapping": { "source_mapping": {
"start": 58, "start": 122,
"length": 59, "length": 63,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
4 5
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 64 "ending_column": 68
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -70,14 +70,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "transfer(address,uint256)" "signature": "approve(address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transfer(address,uint256) (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#4)\n", "description": "Token (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.approve(address,uint256) (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#5)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transfer(address,uint256)](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L4)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.approve(address,uint256)](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L5)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10",
"id": "d3df2e48ae6e8a1b05b275de574b480853a0839c272ce889e8a1664ae432698e", "id": "0fced3029cf59cf348a6b79c58dbb032d837fdd5a5f355600edebda1878e9e2e",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -111,20 +111,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "approve", "name": "allowance",
"source_mapping": { "source_mapping": {
"start": 122, "start": 371,
"length": 63, "length": 68,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 68 "ending_column": 73
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -152,14 +152,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "approve(address,uint256)" "signature": "allowance(address,address)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.approve(address,uint256) (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#5)\n", "description": "Token (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.allowance(address,address) (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#9)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.approve(address,uint256)](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L5)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.allowance(address,address)](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L9)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10",
"id": "0fced3029cf59cf348a6b79c58dbb032d837fdd5a5f355600edebda1878e9e2e", "id": "1286abfe21b09e21e1cec8b991f73664e104fa39f7f4190690ece3af45bc0c7a",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -193,20 +193,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "transferFrom", "name": "balanceOf",
"source_mapping": { "source_mapping": {
"start": 190, "start": 317,
"length": 77, "length": 49,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6 8
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 82 "ending_column": 54
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -234,14 +234,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "transferFrom(address,address,uint256)" "signature": "balanceOf(address)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transferFrom(address,address,uint256) (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#6)\n", "description": "Token (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.balanceOf(address) (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#8)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transferFrom(address,address,uint256)](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L6)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.balanceOf(address)](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L8)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10",
"id": "ba13a1588595032984a3fad39610a2414bb8fcb522d1e632d52fa947ff207d73", "id": "758ca2456030a36dbd6115f2ccb1a43f53f1dabd66ed079806df0f6b7b4d21ef",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -275,20 +275,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "totalSupply", "name": "transferFrom",
"source_mapping": { "source_mapping": {
"start": 272, "start": 190,
"length": 40, "length": 77,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 6
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 45 "ending_column": 82
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -316,14 +316,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "totalSupply()" "signature": "transferFrom(address,address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.totalSupply() (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#7)\n", "description": "Token (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transferFrom(address,address,uint256) (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#6)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.totalSupply()](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L7)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transferFrom(address,address,uint256)](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L6)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10",
"id": "c951e429e546af28ac08e241d391e874c1c9c70b0732ccfb63f3bbfb3eaac16e", "id": "ba13a1588595032984a3fad39610a2414bb8fcb522d1e632d52fa947ff207d73",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -357,20 +357,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "balanceOf", "name": "totalSupply",
"source_mapping": { "source_mapping": {
"start": 317, "start": 272,
"length": 49, "length": 40,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 54 "ending_column": 45
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -398,14 +398,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "balanceOf(address)" "signature": "totalSupply()"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.balanceOf(address) (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#8)\n", "description": "Token (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.totalSupply() (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#7)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.balanceOf(address)](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L8)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.totalSupply()](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L7)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10",
"id": "758ca2456030a36dbd6115f2ccb1a43f53f1dabd66ed079806df0f6b7b4d21ef", "id": "c951e429e546af28ac08e241d391e874c1c9c70b0732ccfb63f3bbfb3eaac16e",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -439,20 +439,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "allowance", "name": "transfer",
"source_mapping": { "source_mapping": {
"start": 371, "start": 58,
"length": 68, "length": 59,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol", "filename_relative": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol", "filename_short": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9 4
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 73 "ending_column": 64
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -480,14 +480,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "allowance(address,address)" "signature": "transfer(address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.allowance(address,address) (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#9)\n", "description": "Token (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#3-10) has incorrect ERC20 function interface:Token.transfer(address,uint256) (tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#4)\n",
"markdown": "[Token](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.allowance(address,address)](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L9)\n", "markdown": "[Token](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10) has incorrect ERC20 function interface:[Token.transfer(address,uint256)](tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L4)\n",
"first_markdown_element": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10", "first_markdown_element": "tests/detectors/erc20-interface/0.7.6/incorrect_erc20_interface.sol#L3-L10",
"id": "1286abfe21b09e21e1cec8b991f73664e104fa39f7f4190690ece3af45bc0c7a", "id": "d3df2e48ae6e8a1b05b275de574b480853a0839c272ce889e8a1664ae432698e",
"check": "erc20-interface", "check": "erc20-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"

@ -32,50 +32,58 @@
}, },
{ {
"type": "function", "type": "function",
"name": "supportsInterface", "name": "getApproved",
"source_mapping": { "source_mapping": {
"start": 50, "start": 723,
"length": 56, "length": 48,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
4 14
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 61 "ending_column": 53
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "IERC165", "name": "Token",
"source_mapping": { "source_mapping": {
"start": 26, "start": 109,
"length": 82, "length": 739,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
3, 6,
4, 7,
5 8,
9,
10,
11,
12,
13,
14,
15,
16
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "supportsInterface(bytes4)" "signature": "getApproved(uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:IERC165.supportsInterface(bytes4) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#4)\n", "description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.getApproved(uint256) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#14)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[IERC165.supportsInterface(bytes4)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L4)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.getApproved(uint256)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L14)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16",
"id": "a8593587ca70c51a9ab827843babec3b3eb7f9a08d76eea1e5528e668f7b291d", "id": "2dce4891c7abea0fa8a8a20a8b8482e7e1d46d54bfd750701c604d5dadd8b937",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -112,20 +120,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "balanceOf", "name": "approve",
"source_mapping": { "source_mapping": {
"start": 140, "start": 549,
"length": 44, "length": 78,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 12
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 49 "ending_column": 83
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -156,14 +164,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "balanceOf(address)" "signature": "approve(address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.balanceOf(address) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#7)\n", "description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.approve(address,uint256) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#12)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.balanceOf(address)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L7)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.approve(address,uint256)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L12)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16",
"id": "6fb9d0320e0b63e2c70f9844d5bea2be958e73beb6eaa4ccb2323ead0c7ef991", "id": "439c95972d0e084aff057161164b13ab63f85bee31d80b568b7155e58eac4b5d",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -200,20 +208,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "ownerOf", "name": "safeTransferFrom",
"source_mapping": { "source_mapping": {
"start": 189, "start": 351,
"length": 44, "length": 96,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8 10
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 49 "ending_column": 101
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -244,14 +252,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "ownerOf(uint256)" "signature": "safeTransferFrom(address,address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.ownerOf(uint256) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#8)\n", "description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#10)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.ownerOf(uint256)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L8)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L10)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16",
"id": "7d9235dd4ef8bc29a3b7700597cc1e4efb846377c928e5e50c5f49cb37f288d2", "id": "50ab7b0f39f327ac6deccf3c16b4e6fee1dc249072ac41a4bd485ccf0c12315b",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -288,20 +296,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "safeTransferFrom", "name": "balanceOf",
"source_mapping": { "source_mapping": {
"start": 238, "start": 140,
"length": 108, "length": 44,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 113 "ending_column": 49
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -332,14 +340,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "safeTransferFrom(address,address,uint256,bytes)" "signature": "balanceOf(address)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256,bytes) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#9)\n", "description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.balanceOf(address) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#7)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256,bytes)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L9)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.balanceOf(address)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L7)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16",
"id": "ccec612c4b5db00ab59b766b5dde3f8d3a8c6408ef595ab08bff21628587e2a1", "id": "6fb9d0320e0b63e2c70f9844d5bea2be958e73beb6eaa4ccb2323ead0c7ef991",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -376,20 +384,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "safeTransferFrom", "name": "ownerOf",
"source_mapping": { "source_mapping": {
"start": 351, "start": 189,
"length": 96, "length": 44,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 8
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 101 "ending_column": 49
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -420,14 +428,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "safeTransferFrom(address,address,uint256)" "signature": "ownerOf(uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#10)\n", "description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.ownerOf(uint256) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#8)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L10)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.ownerOf(uint256)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L8)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16",
"id": "50ab7b0f39f327ac6deccf3c16b4e6fee1dc249072ac41a4bd485ccf0c12315b", "id": "7d9235dd4ef8bc29a3b7700597cc1e4efb846377c928e5e50c5f49cb37f288d2",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -552,58 +560,50 @@
}, },
{ {
"type": "function", "type": "function",
"name": "approve", "name": "supportsInterface",
"source_mapping": { "source_mapping": {
"start": 549, "start": 50,
"length": 78, "length": 56,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
12 4
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 83 "ending_column": 61
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "Token", "name": "IERC165",
"source_mapping": { "source_mapping": {
"start": 109, "start": 26,
"length": 739, "length": 82,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6, 3,
7, 4,
8, 5
9,
10,
11,
12,
13,
14,
15,
16
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "approve(address,uint256)" "signature": "supportsInterface(bytes4)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.approve(address,uint256) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#12)\n", "description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:IERC165.supportsInterface(bytes4) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#4)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.approve(address,uint256)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L12)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[IERC165.supportsInterface(bytes4)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L4)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16",
"id": "439c95972d0e084aff057161164b13ab63f85bee31d80b568b7155e58eac4b5d", "id": "a8593587ca70c51a9ab827843babec3b3eb7f9a08d76eea1e5528e668f7b291d",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -728,20 +728,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "getApproved", "name": "safeTransferFrom",
"source_mapping": { "source_mapping": {
"start": 723, "start": 238,
"length": 48, "length": 108,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 53 "ending_column": 113
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -772,14 +772,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "getApproved(uint256)" "signature": "safeTransferFrom(address,address,uint256,bytes)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.getApproved(uint256) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#14)\n", "description": "Token (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256,bytes) (tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#9)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.getApproved(uint256)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L14)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256,bytes)](tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L9)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.4.25/incorrect_erc721_interface.sol#L6-L16",
"id": "2dce4891c7abea0fa8a8a20a8b8482e7e1d46d54bfd750701c604d5dadd8b937", "id": "ccec612c4b5db00ab59b766b5dde3f8d3a8c6408ef595ab08bff21628587e2a1",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"

@ -32,50 +32,58 @@
}, },
{ {
"type": "function", "type": "function",
"name": "supportsInterface", "name": "getApproved",
"source_mapping": { "source_mapping": {
"start": 53, "start": 735,
"length": 56, "length": 48,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
4 14
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 61 "ending_column": 53
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "IERC165", "name": "Token",
"source_mapping": { "source_mapping": {
"start": 29, "start": 112,
"length": 82, "length": 748,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
3, 6,
4, 7,
5 8,
9,
10,
11,
12,
13,
14,
15,
16
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "supportsInterface(bytes4)" "signature": "getApproved(uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:IERC165.supportsInterface(bytes4) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#4)\n", "description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.getApproved(uint256) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#14)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[IERC165.supportsInterface(bytes4)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L4)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.getApproved(uint256)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L14)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16",
"id": "a8593587ca70c51a9ab827843babec3b3eb7f9a08d76eea1e5528e668f7b291d", "id": "2dce4891c7abea0fa8a8a20a8b8482e7e1d46d54bfd750701c604d5dadd8b937",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -112,20 +120,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "balanceOf", "name": "approve",
"source_mapping": { "source_mapping": {
"start": 143, "start": 561,
"length": 44, "length": 78,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 12
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 49 "ending_column": 83
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -156,14 +164,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "balanceOf(address)" "signature": "approve(address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.balanceOf(address) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#7)\n", "description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.approve(address,uint256) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#12)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.balanceOf(address)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L7)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.approve(address,uint256)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L12)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16",
"id": "6fb9d0320e0b63e2c70f9844d5bea2be958e73beb6eaa4ccb2323ead0c7ef991", "id": "439c95972d0e084aff057161164b13ab63f85bee31d80b568b7155e58eac4b5d",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -200,20 +208,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "ownerOf", "name": "safeTransferFrom",
"source_mapping": { "source_mapping": {
"start": 192, "start": 363,
"length": 44, "length": 96,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8 10
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 49 "ending_column": 101
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -244,14 +252,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "ownerOf(uint256)" "signature": "safeTransferFrom(address,address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.ownerOf(uint256) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#8)\n", "description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#10)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.ownerOf(uint256)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L8)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L10)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16",
"id": "7d9235dd4ef8bc29a3b7700597cc1e4efb846377c928e5e50c5f49cb37f288d2", "id": "50ab7b0f39f327ac6deccf3c16b4e6fee1dc249072ac41a4bd485ccf0c12315b",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -288,20 +296,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "safeTransferFrom", "name": "balanceOf",
"source_mapping": { "source_mapping": {
"start": 241, "start": 143,
"length": 117, "length": 44,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 122 "ending_column": 49
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -332,14 +340,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "safeTransferFrom(address,address,uint256,bytes)" "signature": "balanceOf(address)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256,bytes) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#9)\n", "description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.balanceOf(address) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#7)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256,bytes)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L9)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.balanceOf(address)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L7)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16",
"id": "ccec612c4b5db00ab59b766b5dde3f8d3a8c6408ef595ab08bff21628587e2a1", "id": "6fb9d0320e0b63e2c70f9844d5bea2be958e73beb6eaa4ccb2323ead0c7ef991",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -376,20 +384,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "safeTransferFrom", "name": "ownerOf",
"source_mapping": { "source_mapping": {
"start": 363, "start": 192,
"length": 96, "length": 44,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 8
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 101 "ending_column": 49
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -420,14 +428,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "safeTransferFrom(address,address,uint256)" "signature": "ownerOf(uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#10)\n", "description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.ownerOf(uint256) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#8)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L10)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.ownerOf(uint256)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L8)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16",
"id": "50ab7b0f39f327ac6deccf3c16b4e6fee1dc249072ac41a4bd485ccf0c12315b", "id": "7d9235dd4ef8bc29a3b7700597cc1e4efb846377c928e5e50c5f49cb37f288d2",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -552,58 +560,50 @@
}, },
{ {
"type": "function", "type": "function",
"name": "approve", "name": "supportsInterface",
"source_mapping": { "source_mapping": {
"start": 561, "start": 53,
"length": 78, "length": 56,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
12 4
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 83 "ending_column": 61
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "Token", "name": "IERC165",
"source_mapping": { "source_mapping": {
"start": 112, "start": 29,
"length": 748, "length": 82,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6, 3,
7, 4,
8, 5
9,
10,
11,
12,
13,
14,
15,
16
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "approve(address,uint256)" "signature": "supportsInterface(bytes4)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.approve(address,uint256) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#12)\n", "description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:IERC165.supportsInterface(bytes4) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#4)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.approve(address,uint256)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L12)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[IERC165.supportsInterface(bytes4)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L4)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16",
"id": "439c95972d0e084aff057161164b13ab63f85bee31d80b568b7155e58eac4b5d", "id": "a8593587ca70c51a9ab827843babec3b3eb7f9a08d76eea1e5528e668f7b291d",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -728,20 +728,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "getApproved", "name": "safeTransferFrom",
"source_mapping": { "source_mapping": {
"start": 735, "start": 241,
"length": 48, "length": 117,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 53 "ending_column": 122
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -772,14 +772,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "getApproved(uint256)" "signature": "safeTransferFrom(address,address,uint256,bytes)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.getApproved(uint256) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#14)\n", "description": "Token (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256,bytes) (tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#9)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.getApproved(uint256)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L14)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256,bytes)](tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L9)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.5.16/incorrect_erc721_interface.sol#L6-L16",
"id": "2dce4891c7abea0fa8a8a20a8b8482e7e1d46d54bfd750701c604d5dadd8b937", "id": "ccec612c4b5db00ab59b766b5dde3f8d3a8c6408ef595ab08bff21628587e2a1",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"

@ -32,9 +32,9 @@
}, },
{ {
"type": "function", "type": "function",
"name": "supportsInterface", "name": "getApproved",
"source_mapping": { "source_mapping": {
"start": 53, "start": 800,
"length": 56, "length": 56,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
@ -42,7 +42,7 @@
"filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
4 14
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 61 "ending_column": 61
@ -50,32 +50,40 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "IERC165", "name": "Token",
"source_mapping": { "source_mapping": {
"start": 29, "start": 112,
"length": 82, "length": 829,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
3, 6,
4, 7,
5 8,
9,
10,
11,
12,
13,
14,
15,
16
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "supportsInterface(bytes4)" "signature": "getApproved(uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:IERC165.supportsInterface(bytes4) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#4)\n", "description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.getApproved(uint256) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#14)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[IERC165.supportsInterface(bytes4)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L4)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.getApproved(uint256)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L14)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16",
"id": "a8593587ca70c51a9ab827843babec3b3eb7f9a08d76eea1e5528e668f7b291d", "id": "2dce4891c7abea0fa8a8a20a8b8482e7e1d46d54bfd750701c604d5dadd8b937",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -112,20 +120,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "balanceOf", "name": "approve",
"source_mapping": { "source_mapping": {
"start": 152, "start": 610,
"length": 52, "length": 86,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 12
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 57 "ending_column": 91
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -156,14 +164,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "balanceOf(address)" "signature": "approve(address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.balanceOf(address) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#7)\n", "description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.approve(address,uint256) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#12)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.balanceOf(address)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L7)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.approve(address,uint256)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L12)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16",
"id": "6fb9d0320e0b63e2c70f9844d5bea2be958e73beb6eaa4ccb2323ead0c7ef991", "id": "439c95972d0e084aff057161164b13ab63f85bee31d80b568b7155e58eac4b5d",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -200,20 +208,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "ownerOf", "name": "safeTransferFrom",
"source_mapping": { "source_mapping": {
"start": 209, "start": 396,
"length": 52, "length": 104,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8 10
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 57 "ending_column": 109
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -244,14 +252,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "ownerOf(uint256)" "signature": "safeTransferFrom(address,address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.ownerOf(uint256) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#8)\n", "description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#10)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.ownerOf(uint256)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L8)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L10)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16",
"id": "7d9235dd4ef8bc29a3b7700597cc1e4efb846377c928e5e50c5f49cb37f288d2", "id": "50ab7b0f39f327ac6deccf3c16b4e6fee1dc249072ac41a4bd485ccf0c12315b",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -288,20 +296,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "safeTransferFrom", "name": "balanceOf",
"source_mapping": { "source_mapping": {
"start": 266, "start": 152,
"length": 125, "length": 52,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 130 "ending_column": 57
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -332,14 +340,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "safeTransferFrom(address,address,uint256,bytes)" "signature": "balanceOf(address)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256,bytes) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#9)\n", "description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.balanceOf(address) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#7)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256,bytes)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L9)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.balanceOf(address)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L7)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16",
"id": "ccec612c4b5db00ab59b766b5dde3f8d3a8c6408ef595ab08bff21628587e2a1", "id": "6fb9d0320e0b63e2c70f9844d5bea2be958e73beb6eaa4ccb2323ead0c7ef991",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -376,20 +384,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "safeTransferFrom", "name": "ownerOf",
"source_mapping": { "source_mapping": {
"start": 396, "start": 209,
"length": 104, "length": 52,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 8
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 109 "ending_column": 57
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -420,14 +428,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "safeTransferFrom(address,address,uint256)" "signature": "ownerOf(uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#10)\n", "description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.ownerOf(uint256) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#8)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L10)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.ownerOf(uint256)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L8)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16",
"id": "50ab7b0f39f327ac6deccf3c16b4e6fee1dc249072ac41a4bd485ccf0c12315b", "id": "7d9235dd4ef8bc29a3b7700597cc1e4efb846377c928e5e50c5f49cb37f288d2",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -552,58 +560,50 @@
}, },
{ {
"type": "function", "type": "function",
"name": "approve", "name": "supportsInterface",
"source_mapping": { "source_mapping": {
"start": 610, "start": 53,
"length": 86, "length": 56,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
12 4
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 91 "ending_column": 61
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "Token", "name": "IERC165",
"source_mapping": { "source_mapping": {
"start": 112, "start": 29,
"length": 829, "length": 82,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6, 3,
7, 4,
8, 5
9,
10,
11,
12,
13,
14,
15,
16
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "approve(address,uint256)" "signature": "supportsInterface(bytes4)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.approve(address,uint256) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#12)\n", "description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:IERC165.supportsInterface(bytes4) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#4)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.approve(address,uint256)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L12)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[IERC165.supportsInterface(bytes4)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L4)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16",
"id": "439c95972d0e084aff057161164b13ab63f85bee31d80b568b7155e58eac4b5d", "id": "a8593587ca70c51a9ab827843babec3b3eb7f9a08d76eea1e5528e668f7b291d",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -728,20 +728,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "getApproved", "name": "safeTransferFrom",
"source_mapping": { "source_mapping": {
"start": 800, "start": 266,
"length": 56, "length": 125,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 61 "ending_column": 130
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -772,14 +772,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "getApproved(uint256)" "signature": "safeTransferFrom(address,address,uint256,bytes)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.getApproved(uint256) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#14)\n", "description": "Token (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256,bytes) (tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#9)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.getApproved(uint256)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L14)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256,bytes)](tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L9)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.6.11/incorrect_erc721_interface.sol#L6-L16",
"id": "2dce4891c7abea0fa8a8a20a8b8482e7e1d46d54bfd750701c604d5dadd8b937", "id": "ccec612c4b5db00ab59b766b5dde3f8d3a8c6408ef595ab08bff21628587e2a1",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"

@ -32,9 +32,9 @@
}, },
{ {
"type": "function", "type": "function",
"name": "supportsInterface", "name": "getApproved",
"source_mapping": { "source_mapping": {
"start": 53, "start": 800,
"length": 56, "length": 56,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
@ -42,7 +42,7 @@
"filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
4 14
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 61 "ending_column": 61
@ -50,32 +50,40 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "IERC165", "name": "Token",
"source_mapping": { "source_mapping": {
"start": 29, "start": 112,
"length": 82, "length": 829,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
3, 6,
4, 7,
5 8,
9,
10,
11,
12,
13,
14,
15,
16
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "supportsInterface(bytes4)" "signature": "getApproved(uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:IERC165.supportsInterface(bytes4) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#4)\n", "description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.getApproved(uint256) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#14)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[IERC165.supportsInterface(bytes4)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L4)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.getApproved(uint256)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L14)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16",
"id": "a8593587ca70c51a9ab827843babec3b3eb7f9a08d76eea1e5528e668f7b291d", "id": "2dce4891c7abea0fa8a8a20a8b8482e7e1d46d54bfd750701c604d5dadd8b937",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -112,20 +120,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "balanceOf", "name": "approve",
"source_mapping": { "source_mapping": {
"start": 152, "start": 610,
"length": 52, "length": 86,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 12
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 57 "ending_column": 91
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -156,14 +164,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "balanceOf(address)" "signature": "approve(address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.balanceOf(address) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#7)\n", "description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.approve(address,uint256) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#12)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.balanceOf(address)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L7)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.approve(address,uint256)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L12)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16",
"id": "6fb9d0320e0b63e2c70f9844d5bea2be958e73beb6eaa4ccb2323ead0c7ef991", "id": "439c95972d0e084aff057161164b13ab63f85bee31d80b568b7155e58eac4b5d",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -200,20 +208,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "ownerOf", "name": "safeTransferFrom",
"source_mapping": { "source_mapping": {
"start": 209, "start": 396,
"length": 52, "length": 104,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8 10
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 57 "ending_column": 109
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -244,14 +252,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "ownerOf(uint256)" "signature": "safeTransferFrom(address,address,uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.ownerOf(uint256) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#8)\n", "description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#10)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.ownerOf(uint256)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L8)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L10)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16",
"id": "7d9235dd4ef8bc29a3b7700597cc1e4efb846377c928e5e50c5f49cb37f288d2", "id": "50ab7b0f39f327ac6deccf3c16b4e6fee1dc249072ac41a4bd485ccf0c12315b",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -288,20 +296,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "safeTransferFrom", "name": "balanceOf",
"source_mapping": { "source_mapping": {
"start": 266, "start": 152,
"length": 125, "length": 52,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 130 "ending_column": 57
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -332,14 +340,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "safeTransferFrom(address,address,uint256,bytes)" "signature": "balanceOf(address)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256,bytes) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#9)\n", "description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.balanceOf(address) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#7)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256,bytes)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L9)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.balanceOf(address)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L7)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16",
"id": "ccec612c4b5db00ab59b766b5dde3f8d3a8c6408ef595ab08bff21628587e2a1", "id": "6fb9d0320e0b63e2c70f9844d5bea2be958e73beb6eaa4ccb2323ead0c7ef991",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -376,20 +384,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "safeTransferFrom", "name": "ownerOf",
"source_mapping": { "source_mapping": {
"start": 396, "start": 209,
"length": 104, "length": 52,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 8
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 109 "ending_column": 57
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -420,14 +428,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "safeTransferFrom(address,address,uint256)" "signature": "ownerOf(uint256)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#10)\n", "description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.ownerOf(uint256) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#8)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L10)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.ownerOf(uint256)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L8)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16",
"id": "50ab7b0f39f327ac6deccf3c16b4e6fee1dc249072ac41a4bd485ccf0c12315b", "id": "7d9235dd4ef8bc29a3b7700597cc1e4efb846377c928e5e50c5f49cb37f288d2",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -552,58 +560,50 @@
}, },
{ {
"type": "function", "type": "function",
"name": "approve", "name": "supportsInterface",
"source_mapping": { "source_mapping": {
"start": 610, "start": 53,
"length": 86, "length": 56,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
12 4
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 91 "ending_column": 61
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "Token", "name": "IERC165",
"source_mapping": { "source_mapping": {
"start": 112, "start": 29,
"length": 829, "length": 82,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6, 3,
7, 4,
8, 5
9,
10,
11,
12,
13,
14,
15,
16
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "approve(address,uint256)" "signature": "supportsInterface(bytes4)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.approve(address,uint256) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#12)\n", "description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:IERC165.supportsInterface(bytes4) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#4)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.approve(address,uint256)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L12)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[IERC165.supportsInterface(bytes4)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L4)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16",
"id": "439c95972d0e084aff057161164b13ab63f85bee31d80b568b7155e58eac4b5d", "id": "a8593587ca70c51a9ab827843babec3b3eb7f9a08d76eea1e5528e668f7b291d",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
@ -728,20 +728,20 @@
}, },
{ {
"type": "function", "type": "function",
"name": "getApproved", "name": "safeTransferFrom",
"source_mapping": { "source_mapping": {
"start": 800, "start": 266,
"length": 56, "length": 125,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_relative": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol", "filename_short": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 61 "ending_column": 130
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -772,14 +772,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "getApproved(uint256)" "signature": "safeTransferFrom(address,address,uint256,bytes)"
} }
} }
], ],
"description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.getApproved(uint256) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#14)\n", "description": "Token (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#6-16) has incorrect ERC721 function interface:Token.safeTransferFrom(address,address,uint256,bytes) (tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#9)\n",
"markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.getApproved(uint256)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L14)\n", "markdown": "[Token](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16) has incorrect ERC721 function interface:[Token.safeTransferFrom(address,address,uint256,bytes)](tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L9)\n",
"first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16", "first_markdown_element": "tests/detectors/erc721-interface/0.7.6/incorrect_erc721_interface.sol#L6-L16",
"id": "2dce4891c7abea0fa8a8a20a8b8482e7e1d46d54bfd750701c604d5dadd8b937", "id": "ccec612c4b5db00ab59b766b5dde3f8d3a8c6408ef595ab08bff21628587e2a1",
"check": "erc721-interface", "check": "erc721-interface",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"

@ -219,19 +219,20 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad1", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 364, "start": 458,
"length": 90, "length": 127,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 23,
20, 24,
21 25,
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -306,14 +307,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(address)" "signature": "bad2(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = newOwner", "name": "owner = newOwner",
"source_mapping": { "source_mapping": {
"start": 421, "start": 552,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol",
@ -321,7 +322,7 @@
"filename_short": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 25
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 21 "ending_column": 21
@ -329,19 +330,20 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 364, "start": 458,
"length": 90, "length": 127,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 23,
20, 24,
21 25,
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -416,16 +418,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(address)" "signature": "bad2(address)"
} }
} }
} }
} }
], ],
"description": "Bug.bad1(address) (tests/detectors/events-access/0.4.25/missing_events_access_control.sol#19-21) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.4.25/missing_events_access_control.sol#20) \n", "description": "Bug.bad2(address) (tests/detectors/events-access/0.4.25/missing_events_access_control.sol#23-26) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.4.25/missing_events_access_control.sol#25) \n",
"markdown": "[Bug.bad1(address)](tests/detectors/events-access/0.4.25/missing_events_access_control.sol#L19-L21) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.4.25/missing_events_access_control.sol#L20) \n", "markdown": "[Bug.bad2(address)](tests/detectors/events-access/0.4.25/missing_events_access_control.sol#L23-L26) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.4.25/missing_events_access_control.sol#L25) \n",
"first_markdown_element": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol#L19-L21", "first_markdown_element": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol#L23-L26",
"id": "b2bf34ab3d02054c5f803cd517689d1e3d055b46ca612b2457d845d8d4b94731", "id": "9411f6b4b3e6f3833a72789f341adf88796bcb58b4a12a47a6f7117746d09c53",
"check": "events-access", "check": "events-access",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -434,20 +436,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 458, "start": 364,
"length": 127, "length": 90,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 19,
24, 20,
25, 21
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -522,14 +523,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2(address)" "signature": "bad1(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = newOwner", "name": "owner = newOwner",
"source_mapping": { "source_mapping": {
"start": 552, "start": 421,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol",
@ -537,7 +538,7 @@
"filename_short": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 21 "ending_column": 21
@ -545,20 +546,19 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 458, "start": 364,
"length": 127, "length": 90,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 19,
24, 20,
25, 21
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -633,16 +633,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2(address)" "signature": "bad1(address)"
} }
} }
} }
} }
], ],
"description": "Bug.bad2(address) (tests/detectors/events-access/0.4.25/missing_events_access_control.sol#23-26) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.4.25/missing_events_access_control.sol#25) \n", "description": "Bug.bad1(address) (tests/detectors/events-access/0.4.25/missing_events_access_control.sol#19-21) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.4.25/missing_events_access_control.sol#20) \n",
"markdown": "[Bug.bad2(address)](tests/detectors/events-access/0.4.25/missing_events_access_control.sol#L23-L26) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.4.25/missing_events_access_control.sol#L25) \n", "markdown": "[Bug.bad1(address)](tests/detectors/events-access/0.4.25/missing_events_access_control.sol#L19-L21) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.4.25/missing_events_access_control.sol#L20) \n",
"first_markdown_element": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol#L23-L26", "first_markdown_element": "tests/detectors/events-access/0.4.25/missing_events_access_control.sol#L19-L21",
"id": "9411f6b4b3e6f3833a72789f341adf88796bcb58b4a12a47a6f7117746d09c53", "id": "b2bf34ab3d02054c5f803cd517689d1e3d055b46ca612b2457d845d8d4b94731",
"check": "events-access", "check": "events-access",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"

@ -4,19 +4,20 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad0", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 284, "start": 458,
"length": 76, "length": 127,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
15, 23,
16, 24,
17 25,
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -91,42 +92,43 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad2(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = msg.sender", "name": "owner = newOwner",
"source_mapping": { "source_mapping": {
"start": 325, "start": 552,
"length": 18, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16 25
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 23 "ending_column": 21
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 284, "start": 458,
"length": 76, "length": 127,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
15, 23,
16, 24,
17 25,
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -201,16 +203,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad2(address)"
} }
} }
} }
} }
], ],
"description": "Bug.bad0() (tests/detectors/events-access/0.5.16/missing_events_access_control.sol#15-17) should emit an event for: \n\t- owner = msg.sender (tests/detectors/events-access/0.5.16/missing_events_access_control.sol#16) \n", "description": "Bug.bad2(address) (tests/detectors/events-access/0.5.16/missing_events_access_control.sol#23-26) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.5.16/missing_events_access_control.sol#25) \n",
"markdown": "[Bug.bad0()](tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L15-L17) should emit an event for: \n\t- [owner = msg.sender](tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L16) \n", "markdown": "[Bug.bad2(address)](tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L23-L26) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L25) \n",
"first_markdown_element": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L15-L17", "first_markdown_element": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L23-L26",
"id": "99e09713b41d4b164cc0f4a88f48e6d0bd94128636c57b1bee357ac1fda130d7", "id": "1562e590ef85efee605bdbf837a010ad06cdb04cec40ac4a7ca7c8cc25cf4161",
"check": "events-access", "check": "events-access",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -219,19 +221,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad1", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 364, "start": 284,
"length": 90, "length": 76,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 15,
20, 16,
21 17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -306,42 +308,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(address)" "signature": "bad0()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = newOwner", "name": "owner = msg.sender",
"source_mapping": { "source_mapping": {
"start": 421, "start": 325,
"length": 16, "length": 18,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 21 "ending_column": 23
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 364, "start": 284,
"length": 90, "length": 76,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 15,
20, 16,
21 17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -416,16 +418,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(address)" "signature": "bad0()"
} }
} }
} }
} }
], ],
"description": "Bug.bad1(address) (tests/detectors/events-access/0.5.16/missing_events_access_control.sol#19-21) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.5.16/missing_events_access_control.sol#20) \n", "description": "Bug.bad0() (tests/detectors/events-access/0.5.16/missing_events_access_control.sol#15-17) should emit an event for: \n\t- owner = msg.sender (tests/detectors/events-access/0.5.16/missing_events_access_control.sol#16) \n",
"markdown": "[Bug.bad1(address)](tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L19-L21) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L20) \n", "markdown": "[Bug.bad0()](tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L15-L17) should emit an event for: \n\t- [owner = msg.sender](tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L16) \n",
"first_markdown_element": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L19-L21", "first_markdown_element": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L15-L17",
"id": "a8b5423d1085668a105afd674978791ad0b57f1c9ab15b7db682c3dfac7a49b2", "id": "99e09713b41d4b164cc0f4a88f48e6d0bd94128636c57b1bee357ac1fda130d7",
"check": "events-access", "check": "events-access",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -434,20 +436,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 458, "start": 364,
"length": 127, "length": 90,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 19,
24, 20,
25, 21
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -522,14 +523,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2(address)" "signature": "bad1(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = newOwner", "name": "owner = newOwner",
"source_mapping": { "source_mapping": {
"start": 552, "start": 421,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
@ -537,7 +538,7 @@
"filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 21 "ending_column": 21
@ -545,20 +546,19 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 458, "start": 364,
"length": 127, "length": 90,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 19,
24, 20,
25, 21
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -633,16 +633,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2(address)" "signature": "bad1(address)"
} }
} }
} }
} }
], ],
"description": "Bug.bad2(address) (tests/detectors/events-access/0.5.16/missing_events_access_control.sol#23-26) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.5.16/missing_events_access_control.sol#25) \n", "description": "Bug.bad1(address) (tests/detectors/events-access/0.5.16/missing_events_access_control.sol#19-21) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.5.16/missing_events_access_control.sol#20) \n",
"markdown": "[Bug.bad2(address)](tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L23-L26) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L25) \n", "markdown": "[Bug.bad1(address)](tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L19-L21) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L20) \n",
"first_markdown_element": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L23-L26", "first_markdown_element": "tests/detectors/events-access/0.5.16/missing_events_access_control.sol#L19-L21",
"id": "1562e590ef85efee605bdbf837a010ad06cdb04cec40ac4a7ca7c8cc25cf4161", "id": "a8b5423d1085668a105afd674978791ad0b57f1c9ab15b7db682c3dfac7a49b2",
"check": "events-access", "check": "events-access",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"

@ -4,19 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 284, "start": 364,
"length": 76, "length": 90,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
15, 19,
16, 20,
17 21
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -91,42 +91,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad1(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = msg.sender", "name": "owner = newOwner",
"source_mapping": { "source_mapping": {
"start": 325, "start": 421,
"length": 18, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 23 "ending_column": 21
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 284, "start": 364,
"length": 76, "length": 90,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
15, 19,
16, 20,
17 21
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -201,16 +201,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad1(address)"
} }
} }
} }
} }
], ],
"description": "Bug.bad0() (tests/detectors/events-access/0.6.11/missing_events_access_control.sol#15-17) should emit an event for: \n\t- owner = msg.sender (tests/detectors/events-access/0.6.11/missing_events_access_control.sol#16) \n", "description": "Bug.bad1(address) (tests/detectors/events-access/0.6.11/missing_events_access_control.sol#19-21) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.6.11/missing_events_access_control.sol#20) \n",
"markdown": "[Bug.bad0()](tests/detectors/events-access/0.6.11/missing_events_access_control.sol#L15-L17) should emit an event for: \n\t- [owner = msg.sender](tests/detectors/events-access/0.6.11/missing_events_access_control.sol#L16) \n", "markdown": "[Bug.bad1(address)](tests/detectors/events-access/0.6.11/missing_events_access_control.sol#L19-L21) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.6.11/missing_events_access_control.sol#L20) \n",
"first_markdown_element": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol#L15-L17", "first_markdown_element": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol#L19-L21",
"id": "81ef3707d2eed91cd30ba6e7368fa40206ec32eec757bb0af632c4b7885bd92c", "id": "7dd824ee9b2f6100abf2b1e95d84c1b1393a4ab27a06676b2a5d7da164788a00",
"check": "events-access", "check": "events-access",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -219,19 +219,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad1", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 364, "start": 284,
"length": 90, "length": 76,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 15,
20, 16,
21 17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -306,42 +306,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(address)" "signature": "bad0()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = newOwner", "name": "owner = msg.sender",
"source_mapping": { "source_mapping": {
"start": 421, "start": 325,
"length": 16, "length": 18,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 21 "ending_column": 23
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 364, "start": 284,
"length": 90, "length": 76,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 15,
20, 16,
21 17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -416,16 +416,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(address)" "signature": "bad0()"
} }
} }
} }
} }
], ],
"description": "Bug.bad1(address) (tests/detectors/events-access/0.6.11/missing_events_access_control.sol#19-21) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.6.11/missing_events_access_control.sol#20) \n", "description": "Bug.bad0() (tests/detectors/events-access/0.6.11/missing_events_access_control.sol#15-17) should emit an event for: \n\t- owner = msg.sender (tests/detectors/events-access/0.6.11/missing_events_access_control.sol#16) \n",
"markdown": "[Bug.bad1(address)](tests/detectors/events-access/0.6.11/missing_events_access_control.sol#L19-L21) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.6.11/missing_events_access_control.sol#L20) \n", "markdown": "[Bug.bad0()](tests/detectors/events-access/0.6.11/missing_events_access_control.sol#L15-L17) should emit an event for: \n\t- [owner = msg.sender](tests/detectors/events-access/0.6.11/missing_events_access_control.sol#L16) \n",
"first_markdown_element": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol#L19-L21", "first_markdown_element": "tests/detectors/events-access/0.6.11/missing_events_access_control.sol#L15-L17",
"id": "7dd824ee9b2f6100abf2b1e95d84c1b1393a4ab27a06676b2a5d7da164788a00", "id": "81ef3707d2eed91cd30ba6e7368fa40206ec32eec757bb0af632c4b7885bd92c",
"check": "events-access", "check": "events-access",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"

@ -219,19 +219,20 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad1", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 364, "start": 458,
"length": 90, "length": 127,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 23,
20, 24,
21 25,
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -306,14 +307,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(address)" "signature": "bad2(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = newOwner", "name": "owner = newOwner",
"source_mapping": { "source_mapping": {
"start": 421, "start": 552,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol",
@ -321,7 +322,7 @@
"filename_short": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 25
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 21 "ending_column": 21
@ -329,19 +330,20 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1", "name": "bad2",
"source_mapping": { "source_mapping": {
"start": 364, "start": 458,
"length": 90, "length": 127,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 23,
20, 24,
21 25,
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -416,16 +418,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(address)" "signature": "bad2(address)"
} }
} }
} }
} }
], ],
"description": "Bug.bad1(address) (tests/detectors/events-access/0.7.6/missing_events_access_control.sol#19-21) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.7.6/missing_events_access_control.sol#20) \n", "description": "Bug.bad2(address) (tests/detectors/events-access/0.7.6/missing_events_access_control.sol#23-26) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.7.6/missing_events_access_control.sol#25) \n",
"markdown": "[Bug.bad1(address)](tests/detectors/events-access/0.7.6/missing_events_access_control.sol#L19-L21) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.7.6/missing_events_access_control.sol#L20) \n", "markdown": "[Bug.bad2(address)](tests/detectors/events-access/0.7.6/missing_events_access_control.sol#L23-L26) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.7.6/missing_events_access_control.sol#L25) \n",
"first_markdown_element": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol#L19-L21", "first_markdown_element": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol#L23-L26",
"id": "d319284c1ad2023a792ace9e7b2371966f789c5acf5ab90b1cc5935060f855f0", "id": "3b63f24bd57a54fab8af7d3292bd8444c3dc834bf43dfd96be0e06ca0027299c",
"check": "events-access", "check": "events-access",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -434,20 +436,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 458, "start": 364,
"length": 127, "length": 90,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 19,
24, 20,
25, 21
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -522,14 +523,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2(address)" "signature": "bad1(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = newOwner", "name": "owner = newOwner",
"source_mapping": { "source_mapping": {
"start": 552, "start": 421,
"length": 16, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol",
@ -537,7 +538,7 @@
"filename_short": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 21 "ending_column": 21
@ -545,20 +546,19 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 458, "start": 364,
"length": 127, "length": 90,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol", "filename_relative": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol", "filename_short": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 19,
24, 20,
25, 21
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -633,16 +633,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2(address)" "signature": "bad1(address)"
} }
} }
} }
} }
], ],
"description": "Bug.bad2(address) (tests/detectors/events-access/0.7.6/missing_events_access_control.sol#23-26) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.7.6/missing_events_access_control.sol#25) \n", "description": "Bug.bad1(address) (tests/detectors/events-access/0.7.6/missing_events_access_control.sol#19-21) should emit an event for: \n\t- owner = newOwner (tests/detectors/events-access/0.7.6/missing_events_access_control.sol#20) \n",
"markdown": "[Bug.bad2(address)](tests/detectors/events-access/0.7.6/missing_events_access_control.sol#L23-L26) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.7.6/missing_events_access_control.sol#L25) \n", "markdown": "[Bug.bad1(address)](tests/detectors/events-access/0.7.6/missing_events_access_control.sol#L19-L21) should emit an event for: \n\t- [owner = newOwner](tests/detectors/events-access/0.7.6/missing_events_access_control.sol#L20) \n",
"first_markdown_element": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol#L23-L26", "first_markdown_element": "tests/detectors/events-access/0.7.6/missing_events_access_control.sol#L19-L21",
"id": "3b63f24bd57a54fab8af7d3292bd8444c3dc834bf43dfd96be0e06ca0027299c", "id": "d319284c1ad2023a792ace9e7b2371966f789c5acf5ab90b1cc5935060f855f0",
"check": "events-access", "check": "events-access",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"

@ -4,19 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 392, "start": 535,
"length": 71, "length": 72,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol", "filename_relative": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol", "filename_short": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
22, 30,
23, 31,
24 32
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -111,42 +111,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0(uint8)" "signature": "bad1(int16)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "uprice8 = _price", "name": "iprice16 = _price",
"source_mapping": { "source_mapping": {
"start": 442, "start": 585,
"length": 16, "length": 17,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol", "filename_relative": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol", "filename_short": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23 31
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 21 "ending_column": 22
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 392, "start": 535,
"length": 71, "length": 72,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol", "filename_relative": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol", "filename_short": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
22, 30,
23, 31,
24 32
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -241,16 +241,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0(uint8)" "signature": "bad1(int16)"
} }
} }
} }
} }
], ],
"description": "Bug.bad0(uint8) (tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#22-24) should emit an event for: \n\t- uprice8 = _price (tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#23) \n", "description": "Bug.bad1(int16) (tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#30-32) should emit an event for: \n\t- iprice16 = _price (tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#31) \n",
"markdown": "[Bug.bad0(uint8)](tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#L22-L24) should emit an event for: \n\t- [uprice8 = _price](tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#L23) \n", "markdown": "[Bug.bad1(int16)](tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#L30-L32) should emit an event for: \n\t- [iprice16 = _price](tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#L31) \n",
"first_markdown_element": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#L22-L24", "first_markdown_element": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#L30-L32",
"id": "833efa3b1dab85aef7a00a7bf77bfe290cb2933e11eed34150a1e54a9644a093", "id": "22cd7f2678dfbd4185d6254ad55b620bd3b20a406d88d9f53412ca97d9c3bf03",
"check": "events-maths", "check": "events-maths",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -259,19 +259,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad1", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 535, "start": 392,
"length": 72, "length": 71,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol", "filename_relative": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol", "filename_short": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
30, 22,
31, 23,
32 24
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -366,42 +366,42 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(int16)" "signature": "bad0(uint8)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "iprice16 = _price", "name": "uprice8 = _price",
"source_mapping": { "source_mapping": {
"start": 585, "start": 442,
"length": 17, "length": 16,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol", "filename_relative": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol", "filename_short": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
31 23
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 22 "ending_column": 21
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 535, "start": 392,
"length": 72, "length": 71,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol", "filename_relative": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol", "filename_short": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
30, 22,
31, 23,
32 24
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -496,16 +496,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(int16)" "signature": "bad0(uint8)"
} }
} }
} }
} }
], ],
"description": "Bug.bad1(int16) (tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#30-32) should emit an event for: \n\t- iprice16 = _price (tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#31) \n", "description": "Bug.bad0(uint8) (tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#22-24) should emit an event for: \n\t- uprice8 = _price (tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#23) \n",
"markdown": "[Bug.bad1(int16)](tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#L30-L32) should emit an event for: \n\t- [iprice16 = _price](tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#L31) \n", "markdown": "[Bug.bad0(uint8)](tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#L22-L24) should emit an event for: \n\t- [uprice8 = _price](tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#L23) \n",
"first_markdown_element": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#L30-L32", "first_markdown_element": "tests/detectors/events-maths/0.7.6/missing_events_arithmetic.sol#L22-L24",
"id": "22cd7f2678dfbd4185d6254ad55b620bd3b20a406d88d9f53412ca97d9c3bf03", "id": "833efa3b1dab85aef7a00a7bf77bfe290cb2933e11eed34150a1e54a9644a093",
"check": "events-maths", "check": "events-maths",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"

@ -214,64 +214,60 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "funcNotCalled", "name": "parameter_read_ok_for_external",
"source_mapping": { "source_mapping": {
"start": 554, "start": 1420,
"length": 325, "length": 81,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.4.25/external_function.sol", "filename_relative": "tests/detectors/external-function/0.4.25/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.4.25/external_function.sol", "filename_short": "tests/detectors/external-function/0.4.25/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
32, 74,
33, 75,
34, 76
35,
36,
37,
38,
39
], ],
"starting_column": 5, "starting_column": 3,
"ending_column": 6 "ending_column": 4
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "ContractWithFunctionNotCalled2", "name": "FunctionParameterWrite",
"source_mapping": { "source_mapping": {
"start": 473, "start": 1381,
"length": 408, "length": 234,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.4.25/external_function.sol", "filename_relative": "tests/detectors/external-function/0.4.25/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.4.25/external_function.sol", "filename_short": "tests/detectors/external-function/0.4.25/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
31, 72,
32, 73,
33, 74,
34, 75,
35, 76,
36, 77,
37, 78,
38, 79,
39, 80,
40 81,
82
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "funcNotCalled()" "signature": "parameter_read_ok_for_external(uint256)"
} }
} }
], ],
"description": "funcNotCalled() should be declared external:\n\t- ContractWithFunctionNotCalled2.funcNotCalled() (tests/detectors/external-function/0.4.25/external_function.sol#32-39)\n", "description": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- FunctionParameterWrite.parameter_read_ok_for_external(uint256) (tests/detectors/external-function/0.4.25/external_function.sol#74-76)\n",
"markdown": "funcNotCalled() should be declared external:\n\t- [ContractWithFunctionNotCalled2.funcNotCalled()](tests/detectors/external-function/0.4.25/external_function.sol#L32-L39)\n", "markdown": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- [FunctionParameterWrite.parameter_read_ok_for_external(uint256)](tests/detectors/external-function/0.4.25/external_function.sol#L74-L76)\n",
"first_markdown_element": "tests/detectors/external-function/0.4.25/external_function.sol#L32-L39", "first_markdown_element": "tests/detectors/external-function/0.4.25/external_function.sol#L74-L76",
"id": "80a0a3a3954cc6e314079a1d8d96d6739d521ddbcf738e63078d7f210e443562", "id": "3a0a42d128eff9fb04d8f7605bf2d6f7574c2cbbdffa2dcabbae66d7568ecc59",
"check": "external-function", "check": "external-function",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"
@ -280,60 +276,64 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "parameter_read_ok_for_external", "name": "funcNotCalled",
"source_mapping": { "source_mapping": {
"start": 1420, "start": 554,
"length": 81, "length": 325,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.4.25/external_function.sol", "filename_relative": "tests/detectors/external-function/0.4.25/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.4.25/external_function.sol", "filename_short": "tests/detectors/external-function/0.4.25/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
74, 32,
75, 33,
76 34,
35,
36,
37,
38,
39
], ],
"starting_column": 3, "starting_column": 5,
"ending_column": 4 "ending_column": 6
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "FunctionParameterWrite", "name": "ContractWithFunctionNotCalled2",
"source_mapping": { "source_mapping": {
"start": 1381, "start": 473,
"length": 234, "length": 408,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.4.25/external_function.sol", "filename_relative": "tests/detectors/external-function/0.4.25/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.4.25/external_function.sol", "filename_short": "tests/detectors/external-function/0.4.25/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
72, 31,
73, 32,
74, 33,
75, 34,
76, 35,
77, 36,
78, 37,
79, 38,
80, 39,
81, 40
82
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "parameter_read_ok_for_external(uint256)" "signature": "funcNotCalled()"
} }
} }
], ],
"description": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- FunctionParameterWrite.parameter_read_ok_for_external(uint256) (tests/detectors/external-function/0.4.25/external_function.sol#74-76)\n", "description": "funcNotCalled() should be declared external:\n\t- ContractWithFunctionNotCalled2.funcNotCalled() (tests/detectors/external-function/0.4.25/external_function.sol#32-39)\n",
"markdown": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- [FunctionParameterWrite.parameter_read_ok_for_external(uint256)](tests/detectors/external-function/0.4.25/external_function.sol#L74-L76)\n", "markdown": "funcNotCalled() should be declared external:\n\t- [ContractWithFunctionNotCalled2.funcNotCalled()](tests/detectors/external-function/0.4.25/external_function.sol#L32-L39)\n",
"first_markdown_element": "tests/detectors/external-function/0.4.25/external_function.sol#L74-L76", "first_markdown_element": "tests/detectors/external-function/0.4.25/external_function.sol#L32-L39",
"id": "3a0a42d128eff9fb04d8f7605bf2d6f7574c2cbbdffa2dcabbae66d7568ecc59", "id": "80a0a3a3954cc6e314079a1d8d96d6739d521ddbcf738e63078d7f210e443562",
"check": "external-function", "check": "external-function",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"

@ -214,64 +214,60 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "funcNotCalled", "name": "parameter_read_ok_for_external",
"source_mapping": { "source_mapping": {
"start": 554, "start": 1420,
"length": 325, "length": 81,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.5.16/external_function.sol", "filename_relative": "tests/detectors/external-function/0.5.16/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.5.16/external_function.sol", "filename_short": "tests/detectors/external-function/0.5.16/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
32, 74,
33, 75,
34, 76
35,
36,
37,
38,
39
], ],
"starting_column": 5, "starting_column": 3,
"ending_column": 6 "ending_column": 4
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "ContractWithFunctionNotCalled2", "name": "FunctionParameterWrite",
"source_mapping": { "source_mapping": {
"start": 473, "start": 1381,
"length": 408, "length": 234,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.5.16/external_function.sol", "filename_relative": "tests/detectors/external-function/0.5.16/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.5.16/external_function.sol", "filename_short": "tests/detectors/external-function/0.5.16/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
31, 72,
32, 73,
33, 74,
34, 75,
35, 76,
36, 77,
37, 78,
38, 79,
39, 80,
40 81,
82
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "funcNotCalled()" "signature": "parameter_read_ok_for_external(uint256)"
} }
} }
], ],
"description": "funcNotCalled() should be declared external:\n\t- ContractWithFunctionNotCalled2.funcNotCalled() (tests/detectors/external-function/0.5.16/external_function.sol#32-39)\n", "description": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- FunctionParameterWrite.parameter_read_ok_for_external(uint256) (tests/detectors/external-function/0.5.16/external_function.sol#74-76)\n",
"markdown": "funcNotCalled() should be declared external:\n\t- [ContractWithFunctionNotCalled2.funcNotCalled()](tests/detectors/external-function/0.5.16/external_function.sol#L32-L39)\n", "markdown": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- [FunctionParameterWrite.parameter_read_ok_for_external(uint256)](tests/detectors/external-function/0.5.16/external_function.sol#L74-L76)\n",
"first_markdown_element": "tests/detectors/external-function/0.5.16/external_function.sol#L32-L39", "first_markdown_element": "tests/detectors/external-function/0.5.16/external_function.sol#L74-L76",
"id": "80a0a3a3954cc6e314079a1d8d96d6739d521ddbcf738e63078d7f210e443562", "id": "3a0a42d128eff9fb04d8f7605bf2d6f7574c2cbbdffa2dcabbae66d7568ecc59",
"check": "external-function", "check": "external-function",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"
@ -280,60 +276,64 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "parameter_read_ok_for_external", "name": "funcNotCalled",
"source_mapping": { "source_mapping": {
"start": 1420, "start": 554,
"length": 81, "length": 325,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.5.16/external_function.sol", "filename_relative": "tests/detectors/external-function/0.5.16/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.5.16/external_function.sol", "filename_short": "tests/detectors/external-function/0.5.16/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
74, 32,
75, 33,
76 34,
35,
36,
37,
38,
39
], ],
"starting_column": 3, "starting_column": 5,
"ending_column": 4 "ending_column": 6
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "FunctionParameterWrite", "name": "ContractWithFunctionNotCalled2",
"source_mapping": { "source_mapping": {
"start": 1381, "start": 473,
"length": 234, "length": 408,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.5.16/external_function.sol", "filename_relative": "tests/detectors/external-function/0.5.16/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.5.16/external_function.sol", "filename_short": "tests/detectors/external-function/0.5.16/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
72, 31,
73, 32,
74, 33,
75, 34,
76, 35,
77, 36,
78, 37,
79, 38,
80, 39,
81, 40
82
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "parameter_read_ok_for_external(uint256)" "signature": "funcNotCalled()"
} }
} }
], ],
"description": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- FunctionParameterWrite.parameter_read_ok_for_external(uint256) (tests/detectors/external-function/0.5.16/external_function.sol#74-76)\n", "description": "funcNotCalled() should be declared external:\n\t- ContractWithFunctionNotCalled2.funcNotCalled() (tests/detectors/external-function/0.5.16/external_function.sol#32-39)\n",
"markdown": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- [FunctionParameterWrite.parameter_read_ok_for_external(uint256)](tests/detectors/external-function/0.5.16/external_function.sol#L74-L76)\n", "markdown": "funcNotCalled() should be declared external:\n\t- [ContractWithFunctionNotCalled2.funcNotCalled()](tests/detectors/external-function/0.5.16/external_function.sol#L32-L39)\n",
"first_markdown_element": "tests/detectors/external-function/0.5.16/external_function.sol#L74-L76", "first_markdown_element": "tests/detectors/external-function/0.5.16/external_function.sol#L32-L39",
"id": "3a0a42d128eff9fb04d8f7605bf2d6f7574c2cbbdffa2dcabbae66d7568ecc59", "id": "80a0a3a3954cc6e314079a1d8d96d6739d521ddbcf738e63078d7f210e443562",
"check": "external-function", "check": "external-function",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"

@ -214,64 +214,60 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "funcNotCalled", "name": "parameter_read_ok_for_external",
"source_mapping": { "source_mapping": {
"start": 554, "start": 1420,
"length": 325, "length": 81,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.6.11/external_function.sol", "filename_relative": "tests/detectors/external-function/0.6.11/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.6.11/external_function.sol", "filename_short": "tests/detectors/external-function/0.6.11/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
32, 74,
33, 75,
34, 76
35,
36,
37,
38,
39
], ],
"starting_column": 5, "starting_column": 3,
"ending_column": 6 "ending_column": 4
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "ContractWithFunctionNotCalled2", "name": "FunctionParameterWrite",
"source_mapping": { "source_mapping": {
"start": 473, "start": 1381,
"length": 408, "length": 234,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.6.11/external_function.sol", "filename_relative": "tests/detectors/external-function/0.6.11/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.6.11/external_function.sol", "filename_short": "tests/detectors/external-function/0.6.11/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
31, 72,
32, 73,
33, 74,
34, 75,
35, 76,
36, 77,
37, 78,
38, 79,
39, 80,
40 81,
82
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "funcNotCalled()" "signature": "parameter_read_ok_for_external(uint256)"
} }
} }
], ],
"description": "funcNotCalled() should be declared external:\n\t- ContractWithFunctionNotCalled2.funcNotCalled() (tests/detectors/external-function/0.6.11/external_function.sol#32-39)\n", "description": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- FunctionParameterWrite.parameter_read_ok_for_external(uint256) (tests/detectors/external-function/0.6.11/external_function.sol#74-76)\n",
"markdown": "funcNotCalled() should be declared external:\n\t- [ContractWithFunctionNotCalled2.funcNotCalled()](tests/detectors/external-function/0.6.11/external_function.sol#L32-L39)\n", "markdown": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- [FunctionParameterWrite.parameter_read_ok_for_external(uint256)](tests/detectors/external-function/0.6.11/external_function.sol#L74-L76)\n",
"first_markdown_element": "tests/detectors/external-function/0.6.11/external_function.sol#L32-L39", "first_markdown_element": "tests/detectors/external-function/0.6.11/external_function.sol#L74-L76",
"id": "80a0a3a3954cc6e314079a1d8d96d6739d521ddbcf738e63078d7f210e443562", "id": "3a0a42d128eff9fb04d8f7605bf2d6f7574c2cbbdffa2dcabbae66d7568ecc59",
"check": "external-function", "check": "external-function",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"
@ -280,60 +276,64 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "parameter_read_ok_for_external", "name": "funcNotCalled",
"source_mapping": { "source_mapping": {
"start": 1420, "start": 554,
"length": 81, "length": 325,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.6.11/external_function.sol", "filename_relative": "tests/detectors/external-function/0.6.11/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.6.11/external_function.sol", "filename_short": "tests/detectors/external-function/0.6.11/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
74, 32,
75, 33,
76 34,
35,
36,
37,
38,
39
], ],
"starting_column": 3, "starting_column": 5,
"ending_column": 4 "ending_column": 6
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "FunctionParameterWrite", "name": "ContractWithFunctionNotCalled2",
"source_mapping": { "source_mapping": {
"start": 1381, "start": 473,
"length": 234, "length": 408,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.6.11/external_function.sol", "filename_relative": "tests/detectors/external-function/0.6.11/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.6.11/external_function.sol", "filename_short": "tests/detectors/external-function/0.6.11/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
72, 31,
73, 32,
74, 33,
75, 34,
76, 35,
77, 36,
78, 37,
79, 38,
80, 39,
81, 40
82
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "parameter_read_ok_for_external(uint256)" "signature": "funcNotCalled()"
} }
} }
], ],
"description": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- FunctionParameterWrite.parameter_read_ok_for_external(uint256) (tests/detectors/external-function/0.6.11/external_function.sol#74-76)\n", "description": "funcNotCalled() should be declared external:\n\t- ContractWithFunctionNotCalled2.funcNotCalled() (tests/detectors/external-function/0.6.11/external_function.sol#32-39)\n",
"markdown": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- [FunctionParameterWrite.parameter_read_ok_for_external(uint256)](tests/detectors/external-function/0.6.11/external_function.sol#L74-L76)\n", "markdown": "funcNotCalled() should be declared external:\n\t- [ContractWithFunctionNotCalled2.funcNotCalled()](tests/detectors/external-function/0.6.11/external_function.sol#L32-L39)\n",
"first_markdown_element": "tests/detectors/external-function/0.6.11/external_function.sol#L74-L76", "first_markdown_element": "tests/detectors/external-function/0.6.11/external_function.sol#L32-L39",
"id": "3a0a42d128eff9fb04d8f7605bf2d6f7574c2cbbdffa2dcabbae66d7568ecc59", "id": "80a0a3a3954cc6e314079a1d8d96d6739d521ddbcf738e63078d7f210e443562",
"check": "external-function", "check": "external-function",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"

@ -214,64 +214,60 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "funcNotCalled", "name": "parameter_read_ok_for_external",
"source_mapping": { "source_mapping": {
"start": 554, "start": 1420,
"length": 325, "length": 81,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.7.6/external_function.sol", "filename_relative": "tests/detectors/external-function/0.7.6/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.7.6/external_function.sol", "filename_short": "tests/detectors/external-function/0.7.6/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
32, 74,
33, 75,
34, 76
35,
36,
37,
38,
39
], ],
"starting_column": 5, "starting_column": 3,
"ending_column": 6 "ending_column": 4
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "ContractWithFunctionNotCalled2", "name": "FunctionParameterWrite",
"source_mapping": { "source_mapping": {
"start": 473, "start": 1381,
"length": 408, "length": 234,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.7.6/external_function.sol", "filename_relative": "tests/detectors/external-function/0.7.6/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.7.6/external_function.sol", "filename_short": "tests/detectors/external-function/0.7.6/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
31, 72,
32, 73,
33, 74,
34, 75,
35, 76,
36, 77,
37, 78,
38, 79,
39, 80,
40 81,
82
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "funcNotCalled()" "signature": "parameter_read_ok_for_external(uint256)"
} }
} }
], ],
"description": "funcNotCalled() should be declared external:\n\t- ContractWithFunctionNotCalled2.funcNotCalled() (tests/detectors/external-function/0.7.6/external_function.sol#32-39)\n", "description": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- FunctionParameterWrite.parameter_read_ok_for_external(uint256) (tests/detectors/external-function/0.7.6/external_function.sol#74-76)\n",
"markdown": "funcNotCalled() should be declared external:\n\t- [ContractWithFunctionNotCalled2.funcNotCalled()](tests/detectors/external-function/0.7.6/external_function.sol#L32-L39)\n", "markdown": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- [FunctionParameterWrite.parameter_read_ok_for_external(uint256)](tests/detectors/external-function/0.7.6/external_function.sol#L74-L76)\n",
"first_markdown_element": "tests/detectors/external-function/0.7.6/external_function.sol#L32-L39", "first_markdown_element": "tests/detectors/external-function/0.7.6/external_function.sol#L74-L76",
"id": "80a0a3a3954cc6e314079a1d8d96d6739d521ddbcf738e63078d7f210e443562", "id": "3a0a42d128eff9fb04d8f7605bf2d6f7574c2cbbdffa2dcabbae66d7568ecc59",
"check": "external-function", "check": "external-function",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"
@ -280,60 +276,64 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "parameter_read_ok_for_external", "name": "funcNotCalled",
"source_mapping": { "source_mapping": {
"start": 1420, "start": 554,
"length": 81, "length": 325,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.7.6/external_function.sol", "filename_relative": "tests/detectors/external-function/0.7.6/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.7.6/external_function.sol", "filename_short": "tests/detectors/external-function/0.7.6/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
74, 32,
75, 33,
76 34,
35,
36,
37,
38,
39
], ],
"starting_column": 3, "starting_column": 5,
"ending_column": 4 "ending_column": 6
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "FunctionParameterWrite", "name": "ContractWithFunctionNotCalled2",
"source_mapping": { "source_mapping": {
"start": 1381, "start": 473,
"length": 234, "length": 408,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/external-function/0.7.6/external_function.sol", "filename_relative": "tests/detectors/external-function/0.7.6/external_function.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/external-function/0.7.6/external_function.sol", "filename_short": "tests/detectors/external-function/0.7.6/external_function.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
72, 31,
73, 32,
74, 33,
75, 34,
76, 35,
77, 36,
78, 37,
79, 38,
80, 39,
81, 40
82
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "parameter_read_ok_for_external(uint256)" "signature": "funcNotCalled()"
} }
} }
], ],
"description": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- FunctionParameterWrite.parameter_read_ok_for_external(uint256) (tests/detectors/external-function/0.7.6/external_function.sol#74-76)\n", "description": "funcNotCalled() should be declared external:\n\t- ContractWithFunctionNotCalled2.funcNotCalled() (tests/detectors/external-function/0.7.6/external_function.sol#32-39)\n",
"markdown": "parameter_read_ok_for_external(uint256) should be declared external:\n\t- [FunctionParameterWrite.parameter_read_ok_for_external(uint256)](tests/detectors/external-function/0.7.6/external_function.sol#L74-L76)\n", "markdown": "funcNotCalled() should be declared external:\n\t- [ContractWithFunctionNotCalled2.funcNotCalled()](tests/detectors/external-function/0.7.6/external_function.sol#L32-L39)\n",
"first_markdown_element": "tests/detectors/external-function/0.7.6/external_function.sol#L74-L76", "first_markdown_element": "tests/detectors/external-function/0.7.6/external_function.sol#L32-L39",
"id": "3a0a42d128eff9fb04d8f7605bf2d6f7574c2cbbdffa2dcabbae66d7568ecc59", "id": "80a0a3a3954cc6e314079a1d8d96d6739d521ddbcf738e63078d7f210e443562",
"check": "external-function", "check": "external-function",
"impact": "Optimization", "impact": "Optimization",
"confidence": "High" "confidence": "High"

@ -97,20 +97,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "x", "name": "z4",
"source_mapping": { "source_mapping": {
"start": 268, "start": 842,
"length": 21, "length": 23,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 17
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 26 "ending_column": 28
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -178,10 +178,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.x (tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n", "description": "StateVarInitFromFunction.z4 (tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n",
"markdown": "[StateVarInitFromFunction.x](tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n", "markdown": "[StateVarInitFromFunction.z4](tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n",
"first_markdown_element": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L7", "first_markdown_element": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L17",
"id": "adfa394934c8669a556cfa10c364fe526dd1e295a63959e1e88fe84a919ef354", "id": "8b7eb9ab16397c2f23479d2c3043a675ab5e2b1da07e2697631812d6d7b68525",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -190,20 +190,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "y1", "name": "x",
"source_mapping": { "source_mapping": {
"start": 357, "start": 268,
"length": 26, "length": 21,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 31 "ending_column": 26
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -271,10 +271,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.y1 (tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n", "description": "StateVarInitFromFunction.x (tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n",
"markdown": "[StateVarInitFromFunction.y1](tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n", "markdown": "[StateVarInitFromFunction.x](tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n",
"first_markdown_element": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L9", "first_markdown_element": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L7",
"id": "b26f83c06e9aca87637dea02a0f4080fd4226c1ed90c6c2c63da85cb142d67ab", "id": "adfa394934c8669a556cfa10c364fe526dd1e295a63959e1e88fe84a919ef354",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -283,20 +283,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "y2", "name": "y1",
"source_mapping": { "source_mapping": {
"start": 453, "start": 357,
"length": 35, "length": 26,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 40 "ending_column": 31
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -364,10 +364,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.y2 (tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n", "description": "StateVarInitFromFunction.y1 (tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n",
"markdown": "[StateVarInitFromFunction.y2](tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n", "markdown": "[StateVarInitFromFunction.y1](tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n",
"first_markdown_element": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L10", "first_markdown_element": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L9",
"id": "b6e231b9b735794e00b73dddb86b2ba8f7a738d916c99f302fb32b1095c67472", "id": "b26f83c06e9aca87637dea02a0f4080fd4226c1ed90c6c2c63da85cb142d67ab",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -376,20 +376,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "z4", "name": "y2",
"source_mapping": { "source_mapping": {
"start": 842, "start": 453,
"length": 23, "length": 35,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
17 10
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 28 "ending_column": 40
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -457,10 +457,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.z4 (tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n", "description": "StateVarInitFromFunction.y2 (tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n",
"markdown": "[StateVarInitFromFunction.z4](tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n", "markdown": "[StateVarInitFromFunction.y2](tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n",
"first_markdown_element": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L17", "first_markdown_element": "tests/detectors/function-init-state/0.4.25/function_init_state_variables.sol#L10",
"id": "8b7eb9ab16397c2f23479d2c3043a675ab5e2b1da07e2697631812d6d7b68525", "id": "b6e231b9b735794e00b73dddb86b2ba8f7a738d916c99f302fb32b1095c67472",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -97,20 +97,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "x", "name": "z4",
"source_mapping": { "source_mapping": {
"start": 268, "start": 842,
"length": 21, "length": 23,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 17
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 26 "ending_column": 28
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -178,10 +178,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.x (tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n", "description": "StateVarInitFromFunction.z4 (tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n",
"markdown": "[StateVarInitFromFunction.x](tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n", "markdown": "[StateVarInitFromFunction.z4](tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n",
"first_markdown_element": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L7", "first_markdown_element": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L17",
"id": "adfa394934c8669a556cfa10c364fe526dd1e295a63959e1e88fe84a919ef354", "id": "8b7eb9ab16397c2f23479d2c3043a675ab5e2b1da07e2697631812d6d7b68525",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -190,20 +190,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "y1", "name": "x",
"source_mapping": { "source_mapping": {
"start": 357, "start": 268,
"length": 26, "length": 21,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 31 "ending_column": 26
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -271,10 +271,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.y1 (tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n", "description": "StateVarInitFromFunction.x (tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n",
"markdown": "[StateVarInitFromFunction.y1](tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n", "markdown": "[StateVarInitFromFunction.x](tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n",
"first_markdown_element": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L9", "first_markdown_element": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L7",
"id": "b26f83c06e9aca87637dea02a0f4080fd4226c1ed90c6c2c63da85cb142d67ab", "id": "adfa394934c8669a556cfa10c364fe526dd1e295a63959e1e88fe84a919ef354",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -283,20 +283,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "y2", "name": "y1",
"source_mapping": { "source_mapping": {
"start": 453, "start": 357,
"length": 35, "length": 26,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 40 "ending_column": 31
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -364,10 +364,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.y2 (tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n", "description": "StateVarInitFromFunction.y1 (tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n",
"markdown": "[StateVarInitFromFunction.y2](tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n", "markdown": "[StateVarInitFromFunction.y1](tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n",
"first_markdown_element": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L10", "first_markdown_element": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L9",
"id": "b6e231b9b735794e00b73dddb86b2ba8f7a738d916c99f302fb32b1095c67472", "id": "b26f83c06e9aca87637dea02a0f4080fd4226c1ed90c6c2c63da85cb142d67ab",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -376,20 +376,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "z4", "name": "y2",
"source_mapping": { "source_mapping": {
"start": 842, "start": 453,
"length": 23, "length": 35,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
17 10
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 28 "ending_column": 40
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -457,10 +457,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.z4 (tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n", "description": "StateVarInitFromFunction.y2 (tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n",
"markdown": "[StateVarInitFromFunction.z4](tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n", "markdown": "[StateVarInitFromFunction.y2](tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n",
"first_markdown_element": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L17", "first_markdown_element": "tests/detectors/function-init-state/0.5.16/function_init_state_variables.sol#L10",
"id": "8b7eb9ab16397c2f23479d2c3043a675ab5e2b1da07e2697631812d6d7b68525", "id": "b6e231b9b735794e00b73dddb86b2ba8f7a738d916c99f302fb32b1095c67472",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -97,20 +97,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "x", "name": "z4",
"source_mapping": { "source_mapping": {
"start": 268, "start": 842,
"length": 21, "length": 23,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 17
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 26 "ending_column": 28
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -178,10 +178,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.x (tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n", "description": "StateVarInitFromFunction.z4 (tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n",
"markdown": "[StateVarInitFromFunction.x](tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n", "markdown": "[StateVarInitFromFunction.z4](tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n",
"first_markdown_element": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L7", "first_markdown_element": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L17",
"id": "adfa394934c8669a556cfa10c364fe526dd1e295a63959e1e88fe84a919ef354", "id": "8b7eb9ab16397c2f23479d2c3043a675ab5e2b1da07e2697631812d6d7b68525",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -190,20 +190,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "y1", "name": "x",
"source_mapping": { "source_mapping": {
"start": 357, "start": 268,
"length": 26, "length": 21,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 31 "ending_column": 26
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -271,10 +271,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.y1 (tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n", "description": "StateVarInitFromFunction.x (tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n",
"markdown": "[StateVarInitFromFunction.y1](tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n", "markdown": "[StateVarInitFromFunction.x](tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n",
"first_markdown_element": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L9", "first_markdown_element": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L7",
"id": "b26f83c06e9aca87637dea02a0f4080fd4226c1ed90c6c2c63da85cb142d67ab", "id": "adfa394934c8669a556cfa10c364fe526dd1e295a63959e1e88fe84a919ef354",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -283,20 +283,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "y2", "name": "y1",
"source_mapping": { "source_mapping": {
"start": 453, "start": 357,
"length": 35, "length": 26,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 40 "ending_column": 31
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -364,10 +364,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.y2 (tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n", "description": "StateVarInitFromFunction.y1 (tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n",
"markdown": "[StateVarInitFromFunction.y2](tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n", "markdown": "[StateVarInitFromFunction.y1](tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n",
"first_markdown_element": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L10", "first_markdown_element": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L9",
"id": "b6e231b9b735794e00b73dddb86b2ba8f7a738d916c99f302fb32b1095c67472", "id": "b26f83c06e9aca87637dea02a0f4080fd4226c1ed90c6c2c63da85cb142d67ab",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -376,20 +376,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "z4", "name": "y2",
"source_mapping": { "source_mapping": {
"start": 842, "start": 453,
"length": 23, "length": 35,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
17 10
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 28 "ending_column": 40
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -457,10 +457,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.z4 (tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n", "description": "StateVarInitFromFunction.y2 (tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n",
"markdown": "[StateVarInitFromFunction.z4](tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n", "markdown": "[StateVarInitFromFunction.y2](tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n",
"first_markdown_element": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L17", "first_markdown_element": "tests/detectors/function-init-state/0.6.11/function_init_state_variables.sol#L10",
"id": "8b7eb9ab16397c2f23479d2c3043a675ab5e2b1da07e2697631812d6d7b68525", "id": "b6e231b9b735794e00b73dddb86b2ba8f7a738d916c99f302fb32b1095c67472",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -97,20 +97,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "x", "name": "z4",
"source_mapping": { "source_mapping": {
"start": 268, "start": 842,
"length": 21, "length": 23,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 17
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 26 "ending_column": 28
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -178,10 +178,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.x (tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n", "description": "StateVarInitFromFunction.z4 (tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n",
"markdown": "[StateVarInitFromFunction.x](tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n", "markdown": "[StateVarInitFromFunction.z4](tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n",
"first_markdown_element": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L7", "first_markdown_element": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L17",
"id": "adfa394934c8669a556cfa10c364fe526dd1e295a63959e1e88fe84a919ef354", "id": "8b7eb9ab16397c2f23479d2c3043a675ab5e2b1da07e2697631812d6d7b68525",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -190,20 +190,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "y1", "name": "x",
"source_mapping": { "source_mapping": {
"start": 357, "start": 268,
"length": 26, "length": 21,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9 7
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 31 "ending_column": 26
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -271,10 +271,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.y1 (tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n", "description": "StateVarInitFromFunction.x (tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n",
"markdown": "[StateVarInitFromFunction.y1](tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n", "markdown": "[StateVarInitFromFunction.x](tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L7) is set pre-construction with a non-constant function or state variable:\n\t- set()\n",
"first_markdown_element": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L9", "first_markdown_element": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L7",
"id": "b26f83c06e9aca87637dea02a0f4080fd4226c1ed90c6c2c63da85cb142d67ab", "id": "adfa394934c8669a556cfa10c364fe526dd1e295a63959e1e88fe84a919ef354",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -283,20 +283,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "y2", "name": "y1",
"source_mapping": { "source_mapping": {
"start": 453, "start": 357,
"length": 35, "length": 26,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 40 "ending_column": 31
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -364,10 +364,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.y2 (tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n", "description": "StateVarInitFromFunction.y1 (tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n",
"markdown": "[StateVarInitFromFunction.y2](tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n", "markdown": "[StateVarInitFromFunction.y1](tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L9) is set pre-construction with a non-constant function or state variable:\n\t- 5 + get()\n",
"first_markdown_element": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L10", "first_markdown_element": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L9",
"id": "b6e231b9b735794e00b73dddb86b2ba8f7a738d916c99f302fb32b1095c67472", "id": "b26f83c06e9aca87637dea02a0f4080fd4226c1ed90c6c2c63da85cb142d67ab",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -376,20 +376,20 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "z4", "name": "y2",
"source_mapping": { "source_mapping": {
"start": 842, "start": 453,
"length": 23, "length": 35,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol", "filename_relative": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol", "filename_short": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
17 10
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 28 "ending_column": 40
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -457,10 +457,10 @@
} }
} }
], ],
"description": "StateVarInitFromFunction.z4 (tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n", "description": "StateVarInitFromFunction.y2 (tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n",
"markdown": "[StateVarInitFromFunction.z4](tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L17) is set pre-construction with a non-constant function or state variable:\n\t- z3 + 5\n", "markdown": "[StateVarInitFromFunction.y2](tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L10) is set pre-construction with a non-constant function or state variable:\n\t- (10 + (5 + get()))\n",
"first_markdown_element": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L17", "first_markdown_element": "tests/detectors/function-init-state/0.7.6/function_init_state_variables.sol#L10",
"id": "8b7eb9ab16397c2f23479d2c3043a675ab5e2b1da07e2697631812d6d7b68525", "id": "b6e231b9b735794e00b73dddb86b2ba8f7a738d916c99f302fb32b1095c67472",
"check": "function-init-state", "check": "function-init-state",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -4,21 +4,28 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "noResult", "name": "loopsNoResult",
"source_mapping": { "source_mapping": {
"start": 20, "start": 496,
"length": 103, "length": 251,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol", "filename_relative": "tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol", "filename_short": "tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
2, 30,
3, 31,
4, 32,
5, 33,
6 34,
35,
36,
37,
38,
39,
40,
41
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -93,14 +100,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "noResult()" "signature": "loopsNoResult()"
} }
} }
], ],
"description": "Modifier Test.noResult() (tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol#2-6) does not always execute _; or revert", "description": "Modifier Test.loopsNoResult() (tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol#30-41) does not always execute _; or revert",
"markdown": "Modifier [Test.noResult()](tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol#L2-L6) does not always execute _; or revert", "markdown": "Modifier [Test.loopsNoResult()](tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol#L30-L41) does not always execute _; or revert",
"first_markdown_element": "tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol#L2-L6", "first_markdown_element": "tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol#L30-L41",
"id": "e83e0a544940d3ddd9ea8fe0ae0277bec4660926110809cfd28153817969c3a3", "id": "0ba95ef5faf2a00c06d4f83c5159220d1cd06bc346a1287a6634334b7a0c433f",
"check": "incorrect-modifier", "check": "incorrect-modifier",
"impact": "Low", "impact": "Low",
"confidence": "High" "confidence": "High"
@ -214,28 +221,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "loopsNoResult", "name": "noResult",
"source_mapping": { "source_mapping": {
"start": 496, "start": 20,
"length": 251, "length": 103,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol", "filename_relative": "tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol", "filename_short": "tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
30, 2,
31, 3,
32, 4,
33, 5,
34, 6
35,
36,
37,
38,
39,
40,
41
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -310,14 +310,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "loopsNoResult()" "signature": "noResult()"
} }
} }
], ],
"description": "Modifier Test.loopsNoResult() (tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol#30-41) does not always execute _; or revert", "description": "Modifier Test.noResult() (tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol#2-6) does not always execute _; or revert",
"markdown": "Modifier [Test.loopsNoResult()](tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol#L30-L41) does not always execute _; or revert", "markdown": "Modifier [Test.noResult()](tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol#L2-L6) does not always execute _; or revert",
"first_markdown_element": "tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol#L30-L41", "first_markdown_element": "tests/detectors/incorrect-modifier/0.4.25/modifier_default.sol#L2-L6",
"id": "0ba95ef5faf2a00c06d4f83c5159220d1cd06bc346a1287a6634334b7a0c433f", "id": "e83e0a544940d3ddd9ea8fe0ae0277bec4660926110809cfd28153817969c3a3",
"check": "incorrect-modifier", "check": "incorrect-modifier",
"impact": "Low", "impact": "Low",
"confidence": "High" "confidence": "High"

@ -4,21 +4,28 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "noResult", "name": "loopsNoResult",
"source_mapping": { "source_mapping": {
"start": 20, "start": 496,
"length": 103, "length": 251,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol", "filename_relative": "tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol", "filename_short": "tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
2, 30,
3, 31,
4, 32,
5, 33,
6 34,
35,
36,
37,
38,
39,
40,
41
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -93,14 +100,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "noResult()" "signature": "loopsNoResult()"
} }
} }
], ],
"description": "Modifier Test.noResult() (tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol#2-6) does not always execute _; or revert", "description": "Modifier Test.loopsNoResult() (tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol#30-41) does not always execute _; or revert",
"markdown": "Modifier [Test.noResult()](tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol#L2-L6) does not always execute _; or revert", "markdown": "Modifier [Test.loopsNoResult()](tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol#L30-L41) does not always execute _; or revert",
"first_markdown_element": "tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol#L2-L6", "first_markdown_element": "tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol#L30-L41",
"id": "e83e0a544940d3ddd9ea8fe0ae0277bec4660926110809cfd28153817969c3a3", "id": "0ba95ef5faf2a00c06d4f83c5159220d1cd06bc346a1287a6634334b7a0c433f",
"check": "incorrect-modifier", "check": "incorrect-modifier",
"impact": "Low", "impact": "Low",
"confidence": "High" "confidence": "High"
@ -214,28 +221,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "loopsNoResult", "name": "noResult",
"source_mapping": { "source_mapping": {
"start": 496, "start": 20,
"length": 251, "length": 103,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol", "filename_relative": "tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol", "filename_short": "tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
30, 2,
31, 3,
32, 4,
33, 5,
34, 6
35,
36,
37,
38,
39,
40,
41
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -310,14 +310,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "loopsNoResult()" "signature": "noResult()"
} }
} }
], ],
"description": "Modifier Test.loopsNoResult() (tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol#30-41) does not always execute _; or revert", "description": "Modifier Test.noResult() (tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol#2-6) does not always execute _; or revert",
"markdown": "Modifier [Test.loopsNoResult()](tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol#L30-L41) does not always execute _; or revert", "markdown": "Modifier [Test.noResult()](tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol#L2-L6) does not always execute _; or revert",
"first_markdown_element": "tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol#L30-L41", "first_markdown_element": "tests/detectors/incorrect-modifier/0.5.16/modifier_default.sol#L2-L6",
"id": "0ba95ef5faf2a00c06d4f83c5159220d1cd06bc346a1287a6634334b7a0c433f", "id": "e83e0a544940d3ddd9ea8fe0ae0277bec4660926110809cfd28153817969c3a3",
"check": "incorrect-modifier", "check": "incorrect-modifier",
"impact": "Low", "impact": "Low",
"confidence": "High" "confidence": "High"

@ -4,21 +4,28 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "noResult", "name": "loopsNoResult",
"source_mapping": { "source_mapping": {
"start": 20, "start": 496,
"length": 103, "length": 251,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol", "filename_relative": "tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol", "filename_short": "tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
2, 30,
3, 31,
4, 32,
5, 33,
6 34,
35,
36,
37,
38,
39,
40,
41
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -93,14 +100,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "noResult()" "signature": "loopsNoResult()"
} }
} }
], ],
"description": "Modifier Test.noResult() (tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol#2-6) does not always execute _; or revert", "description": "Modifier Test.loopsNoResult() (tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol#30-41) does not always execute _; or revert",
"markdown": "Modifier [Test.noResult()](tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol#L2-L6) does not always execute _; or revert", "markdown": "Modifier [Test.loopsNoResult()](tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol#L30-L41) does not always execute _; or revert",
"first_markdown_element": "tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol#L2-L6", "first_markdown_element": "tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol#L30-L41",
"id": "e83e0a544940d3ddd9ea8fe0ae0277bec4660926110809cfd28153817969c3a3", "id": "0ba95ef5faf2a00c06d4f83c5159220d1cd06bc346a1287a6634334b7a0c433f",
"check": "incorrect-modifier", "check": "incorrect-modifier",
"impact": "Low", "impact": "Low",
"confidence": "High" "confidence": "High"
@ -214,28 +221,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "loopsNoResult", "name": "noResult",
"source_mapping": { "source_mapping": {
"start": 496, "start": 20,
"length": 251, "length": 103,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol", "filename_relative": "tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol", "filename_short": "tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
30, 2,
31, 3,
32, 4,
33, 5,
34, 6
35,
36,
37,
38,
39,
40,
41
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -310,14 +310,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "loopsNoResult()" "signature": "noResult()"
} }
} }
], ],
"description": "Modifier Test.loopsNoResult() (tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol#30-41) does not always execute _; or revert", "description": "Modifier Test.noResult() (tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol#2-6) does not always execute _; or revert",
"markdown": "Modifier [Test.loopsNoResult()](tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol#L30-L41) does not always execute _; or revert", "markdown": "Modifier [Test.noResult()](tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol#L2-L6) does not always execute _; or revert",
"first_markdown_element": "tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol#L30-L41", "first_markdown_element": "tests/detectors/incorrect-modifier/0.6.11/modifier_default.sol#L2-L6",
"id": "0ba95ef5faf2a00c06d4f83c5159220d1cd06bc346a1287a6634334b7a0c433f", "id": "e83e0a544940d3ddd9ea8fe0ae0277bec4660926110809cfd28153817969c3a3",
"check": "incorrect-modifier", "check": "incorrect-modifier",
"impact": "Low", "impact": "Low",
"confidence": "High" "confidence": "High"

@ -4,21 +4,28 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "noResult", "name": "loopsNoResult",
"source_mapping": { "source_mapping": {
"start": 20, "start": 496,
"length": 103, "length": 251,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol", "filename_relative": "tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol", "filename_short": "tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
2, 30,
3, 31,
4, 32,
5, 33,
6 34,
35,
36,
37,
38,
39,
40,
41
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -93,14 +100,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "noResult()" "signature": "loopsNoResult()"
} }
} }
], ],
"description": "Modifier Test.noResult() (tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol#2-6) does not always execute _; or revert", "description": "Modifier Test.loopsNoResult() (tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol#30-41) does not always execute _; or revert",
"markdown": "Modifier [Test.noResult()](tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol#L2-L6) does not always execute _; or revert", "markdown": "Modifier [Test.loopsNoResult()](tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol#L30-L41) does not always execute _; or revert",
"first_markdown_element": "tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol#L2-L6", "first_markdown_element": "tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol#L30-L41",
"id": "e83e0a544940d3ddd9ea8fe0ae0277bec4660926110809cfd28153817969c3a3", "id": "0ba95ef5faf2a00c06d4f83c5159220d1cd06bc346a1287a6634334b7a0c433f",
"check": "incorrect-modifier", "check": "incorrect-modifier",
"impact": "Low", "impact": "Low",
"confidence": "High" "confidence": "High"
@ -214,28 +221,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "loopsNoResult", "name": "noResult",
"source_mapping": { "source_mapping": {
"start": 496, "start": 20,
"length": 251, "length": 103,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol", "filename_relative": "tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol", "filename_short": "tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
30, 2,
31, 3,
32, 4,
33, 5,
34, 6
35,
36,
37,
38,
39,
40,
41
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -310,14 +310,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "loopsNoResult()" "signature": "noResult()"
} }
} }
], ],
"description": "Modifier Test.loopsNoResult() (tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol#30-41) does not always execute _; or revert", "description": "Modifier Test.noResult() (tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol#2-6) does not always execute _; or revert",
"markdown": "Modifier [Test.loopsNoResult()](tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol#L30-L41) does not always execute _; or revert", "markdown": "Modifier [Test.noResult()](tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol#L2-L6) does not always execute _; or revert",
"first_markdown_element": "tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol#L30-L41", "first_markdown_element": "tests/detectors/incorrect-modifier/0.7.6/modifier_default.sol#L2-L6",
"id": "0ba95ef5faf2a00c06d4f83c5159220d1cd06bc346a1287a6634334b7a0c433f", "id": "e83e0a544940d3ddd9ea8fe0ae0277bec4660926110809cfd28153817969c3a3",
"check": "incorrect-modifier", "check": "incorrect-modifier",
"impact": "Low", "impact": "Low",
"confidence": "High" "confidence": "High"

@ -1,68 +1,5 @@
[ [
[ [
{
"elements": [
{
"type": "variable",
"name": "c",
"source_mapping": {
"start": 42,
"length": 13,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol",
"is_dependency": false,
"lines": [
4
],
"starting_column": 3,
"ending_column": 16
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "C",
"source_mapping": {
"start": 0,
"length": 204,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13,
14,
15
],
"starting_column": 1,
"ending_column": 2
}
}
}
}
],
"description": "C.c (tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol#4) uses an dangerous unary operator: (b = + 1)\n",
"markdown": "[C.c](tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol#L4) uses an dangerous unary operator: (b = + 1)\n",
"first_markdown_element": "tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol#L4",
"id": "98d05a4acbe13ff0e6fa795af35dc2002541cc7607f3f4d7ffb356f9d33681bd",
"check": "incorrect-unary",
"impact": "Low",
"confidence": "Medium"
},
{ {
"elements": [ "elements": [
{ {
@ -533,6 +470,69 @@
"check": "incorrect-unary", "check": "incorrect-unary",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
},
{
"elements": [
{
"type": "variable",
"name": "c",
"source_mapping": {
"start": 42,
"length": 13,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol",
"is_dependency": false,
"lines": [
4
],
"starting_column": 3,
"ending_column": 16
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "C",
"source_mapping": {
"start": 0,
"length": 204,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol",
"is_dependency": false,
"lines": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13,
14,
15
],
"starting_column": 1,
"ending_column": 2
}
}
}
}
],
"description": "C.c (tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol#4) uses an dangerous unary operator: (b = + 1)\n",
"markdown": "[C.c](tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol#L4) uses an dangerous unary operator: (b = + 1)\n",
"first_markdown_element": "tests/detectors/incorrect-unary/0.4.25/invalid_unary_expression.sol#L4",
"id": "98d05a4acbe13ff0e6fa795af35dc2002541cc7607f3f4d7ffb356f9d33681bd",
"check": "incorrect-unary",
"impact": "Low",
"confidence": "Medium"
} }
] ]
] ]

@ -1,188 +1,5 @@
[ [
[ [
{
"elements": [
{
"type": "function",
"name": "deleteSt",
"source_mapping": {
"start": 114,
"length": 70,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
9,
10,
11
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 158,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "deleteSt(Lib.MyStruct[1])"
}
},
{
"type": "struct",
"name": "MyStruct",
"source_mapping": {
"start": 47,
"length": 61,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
5,
6,
7
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 158,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
}
}
},
{
"type": "node",
"name": "delete st[0]",
"source_mapping": {
"start": 165,
"length": 12,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
10
],
"starting_column": 9,
"ending_column": 21
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "deleteSt",
"source_mapping": {
"start": 114,
"length": 70,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
9,
10,
11
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 158,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "deleteSt(Lib.MyStruct[1])"
}
}
}
}
],
"description": "Lib.deleteSt(Lib.MyStruct[1]) (tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#9-11) deletes Lib.MyStruct (tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#5-7) which contains a mapping:\n\t-delete st[0] (tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#10)\n",
"markdown": "[Lib.deleteSt(Lib.MyStruct[1])](tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#L9-L11) deletes [Lib.MyStruct](tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#L5-L7) which contains a mapping:\n\t-[delete st[0]](tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#L10)\n",
"first_markdown_element": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#L9-L11",
"id": "8c8313f12eb11c77c9acf1f683fe6d44a79ca1445e0d92cffd79c04a3462d3e9",
"check": "mapping-deletion",
"impact": "Medium",
"confidence": "High"
},
{ {
"elements": [ "elements": [
{ {
@ -422,6 +239,189 @@
"check": "mapping-deletion", "check": "mapping-deletion",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
},
{
"elements": [
{
"type": "function",
"name": "deleteSt",
"source_mapping": {
"start": 114,
"length": 70,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
9,
10,
11
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 158,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "deleteSt(Lib.MyStruct[1])"
}
},
{
"type": "struct",
"name": "MyStruct",
"source_mapping": {
"start": 47,
"length": 61,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
5,
6,
7
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 158,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
}
}
},
{
"type": "node",
"name": "delete st[0]",
"source_mapping": {
"start": 165,
"length": 12,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
10
],
"starting_column": 9,
"ending_column": 21
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "deleteSt",
"source_mapping": {
"start": 114,
"length": 70,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
9,
10,
11
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 158,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "deleteSt(Lib.MyStruct[1])"
}
}
}
}
],
"description": "Lib.deleteSt(Lib.MyStruct[1]) (tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#9-11) deletes Lib.MyStruct (tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#5-7) which contains a mapping:\n\t-delete st[0] (tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#10)\n",
"markdown": "[Lib.deleteSt(Lib.MyStruct[1])](tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#L9-L11) deletes [Lib.MyStruct](tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#L5-L7) which contains a mapping:\n\t-[delete st[0]](tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#L10)\n",
"first_markdown_element": "tests/detectors/mapping-deletion/0.4.25/MappingDeletion.sol#L9-L11",
"id": "8c8313f12eb11c77c9acf1f683fe6d44a79ca1445e0d92cffd79c04a3462d3e9",
"check": "mapping-deletion",
"impact": "Medium",
"confidence": "High"
} }
] ]
] ]

@ -1,188 +1,5 @@
[ [
[ [
{
"elements": [
{
"type": "function",
"name": "deleteSt",
"source_mapping": {
"start": 114,
"length": 80,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
9,
10,
11
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 168,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "deleteSt(Lib.MyStruct[1])"
}
},
{
"type": "struct",
"name": "MyStruct",
"source_mapping": {
"start": 47,
"length": 61,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
5,
6,
7
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 168,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
}
}
},
{
"type": "node",
"name": "delete st[0]",
"source_mapping": {
"start": 175,
"length": 12,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
10
],
"starting_column": 9,
"ending_column": 21
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "deleteSt",
"source_mapping": {
"start": 114,
"length": 80,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
9,
10,
11
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 168,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "deleteSt(Lib.MyStruct[1])"
}
}
}
}
],
"description": "Lib.deleteSt(Lib.MyStruct[1]) (tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#9-11) deletes Lib.MyStruct (tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#5-7) which contains a mapping:\n\t-delete st[0] (tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#10)\n",
"markdown": "[Lib.deleteSt(Lib.MyStruct[1])](tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#L9-L11) deletes [Lib.MyStruct](tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#L5-L7) which contains a mapping:\n\t-[delete st[0]](tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#L10)\n",
"first_markdown_element": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#L9-L11",
"id": "4c08076815986fec8b813cb66a7f7fe7002a5e87179bbd46e59279da2f46e992",
"check": "mapping-deletion",
"impact": "Medium",
"confidence": "High"
},
{ {
"elements": [ "elements": [
{ {
@ -425,6 +242,189 @@
"check": "mapping-deletion", "check": "mapping-deletion",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
},
{
"elements": [
{
"type": "function",
"name": "deleteSt",
"source_mapping": {
"start": 114,
"length": 80,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
9,
10,
11
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 168,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "deleteSt(Lib.MyStruct[1])"
}
},
{
"type": "struct",
"name": "MyStruct",
"source_mapping": {
"start": 47,
"length": 61,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
5,
6,
7
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 168,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
}
}
},
{
"type": "node",
"name": "delete st[0]",
"source_mapping": {
"start": 175,
"length": 12,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
10
],
"starting_column": 9,
"ending_column": 21
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "deleteSt",
"source_mapping": {
"start": 114,
"length": 80,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
9,
10,
11
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 168,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "deleteSt(Lib.MyStruct[1])"
}
}
}
}
],
"description": "Lib.deleteSt(Lib.MyStruct[1]) (tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#9-11) deletes Lib.MyStruct (tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#5-7) which contains a mapping:\n\t-delete st[0] (tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#10)\n",
"markdown": "[Lib.deleteSt(Lib.MyStruct[1])](tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#L9-L11) deletes [Lib.MyStruct](tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#L5-L7) which contains a mapping:\n\t-[delete st[0]](tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#L10)\n",
"first_markdown_element": "tests/detectors/mapping-deletion/0.5.16/MappingDeletion.sol#L9-L11",
"id": "4c08076815986fec8b813cb66a7f7fe7002a5e87179bbd46e59279da2f46e992",
"check": "mapping-deletion",
"impact": "Medium",
"confidence": "High"
} }
] ]
] ]

@ -1,188 +1,5 @@
[ [
[ [
{
"elements": [
{
"type": "function",
"name": "deleteSt",
"source_mapping": {
"start": 114,
"length": 80,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
9,
10,
11
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 168,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "deleteSt(Lib.MyStruct[1])"
}
},
{
"type": "struct",
"name": "MyStruct",
"source_mapping": {
"start": 47,
"length": 61,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
5,
6,
7
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 168,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
}
}
},
{
"type": "node",
"name": "delete st[0]",
"source_mapping": {
"start": 175,
"length": 12,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
10
],
"starting_column": 9,
"ending_column": 21
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "deleteSt",
"source_mapping": {
"start": 114,
"length": 80,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
9,
10,
11
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 168,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "deleteSt(Lib.MyStruct[1])"
}
}
}
}
],
"description": "Lib.deleteSt(Lib.MyStruct[1]) (tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#9-11) deletes Lib.MyStruct (tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#5-7) which contains a mapping:\n\t-delete st[0] (tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#10)\n",
"markdown": "[Lib.deleteSt(Lib.MyStruct[1])](tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#L9-L11) deletes [Lib.MyStruct](tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#L5-L7) which contains a mapping:\n\t-[delete st[0]](tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#L10)\n",
"first_markdown_element": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#L9-L11",
"id": "a6c44f7353505e72d74433eef65af07e90cc95c3797d5b395766255f0ecb91e1",
"check": "mapping-deletion",
"impact": "Medium",
"confidence": "High"
},
{ {
"elements": [ "elements": [
{ {
@ -425,6 +242,189 @@
"check": "mapping-deletion", "check": "mapping-deletion",
"impact": "Medium", "impact": "Medium",
"confidence": "High" "confidence": "High"
},
{
"elements": [
{
"type": "function",
"name": "deleteSt",
"source_mapping": {
"start": 114,
"length": 80,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
9,
10,
11
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 168,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "deleteSt(Lib.MyStruct[1])"
}
},
{
"type": "struct",
"name": "MyStruct",
"source_mapping": {
"start": 47,
"length": 61,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
5,
6,
7
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 168,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
}
}
},
{
"type": "node",
"name": "delete st[0]",
"source_mapping": {
"start": 175,
"length": 12,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
10
],
"starting_column": 9,
"ending_column": 21
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "deleteSt",
"source_mapping": {
"start": 114,
"length": 80,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
9,
10,
11
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "Lib",
"source_mapping": {
"start": 29,
"length": 168,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol",
"is_dependency": false,
"lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "deleteSt(Lib.MyStruct[1])"
}
}
}
}
],
"description": "Lib.deleteSt(Lib.MyStruct[1]) (tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#9-11) deletes Lib.MyStruct (tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#5-7) which contains a mapping:\n\t-delete st[0] (tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#10)\n",
"markdown": "[Lib.deleteSt(Lib.MyStruct[1])](tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#L9-L11) deletes [Lib.MyStruct](tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#L5-L7) which contains a mapping:\n\t-[delete st[0]](tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#L10)\n",
"first_markdown_element": "tests/detectors/mapping-deletion/0.7.6/MappingDeletion.sol#L9-L11",
"id": "a6c44f7353505e72d74433eef65af07e90cc95c3797d5b395766255f0ecb91e1",
"check": "mapping-deletion",
"impact": "Medium",
"confidence": "High"
} }
] ]
] ]

@ -4,37 +4,37 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "new_owner", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 149, "start": 393,
"length": 17, "length": 12,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 19
], ],
"starting_column": 27, "starting_column": 26,
"ending_column": 44 "ending_column": 38
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0_set_owner", "name": "bad2_transfer",
"source_mapping": { "source_mapping": {
"start": 125, "start": 370,
"length": 108, "length": 114,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10, 19,
11, 20,
12 21
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -128,44 +128,44 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0_set_owner(address)" "signature": "bad2_transfer(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = new_owner", "name": "addr.transfer(msg.value)",
"source_mapping": { "source_mapping": {
"start": 188, "start": 427,
"length": 17, "length": 24,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 22 "ending_column": 29
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0_set_owner", "name": "bad2_transfer",
"source_mapping": { "source_mapping": {
"start": 125, "start": 370,
"length": 108, "length": 114,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10, 19,
11, 20,
12 21
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -259,16 +259,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0_set_owner(address)" "signature": "bad2_transfer(address)"
} }
} }
} }
} }
], ],
"description": "C.bad0_set_owner(address).new_owner (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#10) lacks a zero-check on :\n\t\t- owner = new_owner (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#11)\n", "description": "C.bad2_transfer(address).addr (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#19) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#20)\n",
"markdown": "[C.bad0_set_owner(address).new_owner](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L10) lacks a zero-check on :\n\t\t- [owner = new_owner](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L11)\n", "markdown": "[C.bad2_transfer(address).addr](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L19) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L20)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L10", "first_markdown_element": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L19",
"id": "4215a731670a0150f45d8cd682dc81ed85ffd5268cbad6ac9fe8bd044e54f74d", "id": "16629b342aad1ee3e0d3f933781eea91f1cb34b1770f84cb38a5d911e15b3476",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -279,7 +279,7 @@
"type": "variable", "type": "variable",
"name": "addr", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 256, "start": 511,
"length": 12, "length": 12,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
@ -287,28 +287,28 @@
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 23
], ],
"starting_column": 22, "starting_column": 26,
"ending_column": 34 "ending_column": 38
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1_send", "name": "bad3_transfer",
"source_mapping": { "source_mapping": {
"start": 237, "start": 488,
"length": 129, "length": 195,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 23,
15, 24,
16, 25,
17 26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -402,45 +402,45 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1_send(address)" "signature": "bad3_transfer(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr.send(msg.value)", "name": "addr.transfer(msg.value)",
"source_mapping": { "source_mapping": {
"start": 290, "start": 545,
"length": 20, "length": 24,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
15 24
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 25 "ending_column": 29
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1_send", "name": "bad3_transfer",
"source_mapping": { "source_mapping": {
"start": 237, "start": 488,
"length": 129, "length": 195,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 23,
15, 24,
16, 25,
17 26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -534,45 +534,55 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1_send(address)" "signature": "bad3_transfer(address)"
} }
} }
} }
}, }
],
"description": "C.bad3_transfer(address).addr (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#23) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#24)\n",
"markdown": "[C.bad3_transfer(address).addr](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L23) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L24)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L23",
"id": "27318d51c369e1e169a889a6c2678a023a22e1e3a691ab41a429684e338d2d1e",
"check": "missing-zero-check",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "node", "type": "variable",
"name": "addr.send(msg.value)", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 340, "start": 706,
"length": 20, "length": 12,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16 28
], ],
"starting_column": 5, "starting_column": 22,
"ending_column": 25 "ending_column": 34
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1_send", "name": "bad4_call",
"source_mapping": { "source_mapping": {
"start": 237, "start": 687,
"length": 129, "length": 112,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 28,
15, 29,
16, 30
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -666,55 +676,44 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1_send(address)" "signature": "bad4_call(address)"
} }
} }
} }
} },
],
"description": "C.bad1_send(address).addr (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#14) lacks a zero-check on :\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#15)\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#16)\n",
"markdown": "[C.bad1_send(address).addr](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L14) lacks a zero-check on :\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L15)\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L16)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L14",
"id": "dd2af335a7782a70944073bf1cf5dea69845ddcf6a45ea86a9fcf59793b151c8",
"check": "missing-zero-check",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "variable", "type": "node",
"name": "addr", "name": "addr.call.value(msg.value)()",
"source_mapping": { "source_mapping": {
"start": 393, "start": 740,
"length": 12, "length": 30,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19 29
], ],
"starting_column": 26, "starting_column": 5,
"ending_column": 38 "ending_column": 35
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_transfer", "name": "bad4_call",
"source_mapping": { "source_mapping": {
"start": 370, "start": 687,
"length": 114, "length": 112,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 28,
20, 29,
21 30
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -808,44 +807,55 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2_transfer(address)" "signature": "bad4_call(address)"
} }
} }
} }
}, }
],
"description": "C.bad4_call(address).addr (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#28) lacks a zero-check on :\n\t\t- addr.call.value(msg.value)() (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#29)\n",
"markdown": "[C.bad4_call(address).addr](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L28) lacks a zero-check on :\n\t\t- [addr.call.value(msg.value)()](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L29)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L28",
"id": "34b73dbecfa159bc5631cb95ff2343c92792d80f448fc425b7d1bba399108073",
"check": "missing-zero-check",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "node", "type": "variable",
"name": "addr.transfer(msg.value)", "name": "new_owner",
"source_mapping": { "source_mapping": {
"start": 427, "start": 149,
"length": 24, "length": 17,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 10
], ],
"starting_column": 5, "starting_column": 27,
"ending_column": 29 "ending_column": 44
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_transfer", "name": "bad0_set_owner",
"source_mapping": { "source_mapping": {
"start": 370, "start": 125,
"length": 114, "length": 108,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 10,
20, 11,
21 12
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -939,56 +949,44 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2_transfer(address)" "signature": "bad0_set_owner(address)"
} }
} }
} }
} },
],
"description": "C.bad2_transfer(address).addr (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#19) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#20)\n",
"markdown": "[C.bad2_transfer(address).addr](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L19) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L20)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L19",
"id": "16629b342aad1ee3e0d3f933781eea91f1cb34b1770f84cb38a5d911e15b3476",
"check": "missing-zero-check",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "variable", "type": "node",
"name": "addr", "name": "owner = new_owner",
"source_mapping": { "source_mapping": {
"start": 511, "start": 188,
"length": 12, "length": 17,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23 11
], ],
"starting_column": 26, "starting_column": 5,
"ending_column": 38 "ending_column": 22
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_transfer", "name": "bad0_set_owner",
"source_mapping": { "source_mapping": {
"start": 488, "start": 125,
"length": 195, "length": 108,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 10,
24, 11,
25, 12
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1082,45 +1080,56 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_transfer(address)" "signature": "bad0_set_owner(address)"
} }
} }
} }
}, }
],
"description": "C.bad0_set_owner(address).new_owner (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#10) lacks a zero-check on :\n\t\t- owner = new_owner (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#11)\n",
"markdown": "[C.bad0_set_owner(address).new_owner](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L10) lacks a zero-check on :\n\t\t- [owner = new_owner](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L11)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L10",
"id": "4215a731670a0150f45d8cd682dc81ed85ffd5268cbad6ac9fe8bd044e54f74d",
"check": "missing-zero-check",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "node", "type": "variable",
"name": "addr.transfer(msg.value)", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 545, "start": 256,
"length": 24, "length": 12,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
24 14
], ],
"starting_column": 5, "starting_column": 22,
"ending_column": 29 "ending_column": 34
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_transfer", "name": "bad1_send",
"source_mapping": { "source_mapping": {
"start": 488, "start": 237,
"length": 195, "length": 129,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 14,
24, 15,
25, 16,
26 17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1214,55 +1223,45 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_transfer(address)" "signature": "bad1_send(address)"
} }
} }
} }
} },
],
"description": "C.bad3_transfer(address).addr (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#23) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#24)\n",
"markdown": "[C.bad3_transfer(address).addr](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L23) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L24)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L23",
"id": "27318d51c369e1e169a889a6c2678a023a22e1e3a691ab41a429684e338d2d1e",
"check": "missing-zero-check",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "variable", "type": "node",
"name": "addr", "name": "addr.send(msg.value)",
"source_mapping": { "source_mapping": {
"start": 706, "start": 290,
"length": 12, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28 15
], ],
"starting_column": 22, "starting_column": 5,
"ending_column": 34 "ending_column": 25
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad4_call", "name": "bad1_send",
"source_mapping": { "source_mapping": {
"start": 687, "start": 237,
"length": 112, "length": 129,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28, 14,
29, 15,
30 16,
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1356,44 +1355,45 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad4_call(address)" "signature": "bad1_send(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr.call.value(msg.value)()", "name": "addr.send(msg.value)",
"source_mapping": { "source_mapping": {
"start": 740, "start": 340,
"length": 30, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
29 16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 35 "ending_column": 25
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad4_call", "name": "bad1_send",
"source_mapping": { "source_mapping": {
"start": 687, "start": 237,
"length": 112, "length": 129,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28, 14,
29, 15,
30 16,
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1487,16 +1487,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad4_call(address)" "signature": "bad1_send(address)"
} }
} }
} }
} }
], ],
"description": "C.bad4_call(address).addr (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#28) lacks a zero-check on :\n\t\t- addr.call.value(msg.value)() (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#29)\n", "description": "C.bad1_send(address).addr (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#14) lacks a zero-check on :\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#15)\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#16)\n",
"markdown": "[C.bad4_call(address).addr](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L28) lacks a zero-check on :\n\t\t- [addr.call.value(msg.value)()](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L29)\n", "markdown": "[C.bad1_send(address).addr](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L14) lacks a zero-check on :\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L15)\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L16)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L28", "first_markdown_element": "tests/detectors/missing-zero-check/0.4.25/missing_zero_address_validation.sol#L14",
"id": "34b73dbecfa159bc5631cb95ff2343c92792d80f448fc425b7d1bba399108073", "id": "dd2af335a7782a70944073bf1cf5dea69845ddcf6a45ea86a9fcf59793b151c8",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"

@ -4,37 +4,38 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "new_owner", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 149, "start": 256,
"length": 17, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 14
], ],
"starting_column": 27, "starting_column": 22,
"ending_column": 44 "ending_column": 42
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0_set_owner", "name": "bad1_send",
"source_mapping": { "source_mapping": {
"start": 125, "start": 237,
"length": 108, "length": 137,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10, 14,
11, 15,
12 16,
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -128,44 +129,45 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0_set_owner(address)" "signature": "bad1_send(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = new_owner", "name": "addr.send(msg.value)",
"source_mapping": { "source_mapping": {
"start": 188, "start": 298,
"length": 17, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11 15
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 22 "ending_column": 25
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0_set_owner", "name": "bad1_send",
"source_mapping": { "source_mapping": {
"start": 125, "start": 237,
"length": 108, "length": 137,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10, 14,
11, 15,
12 16,
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -259,27 +261,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0_set_owner(address)" "signature": "bad1_send(address)"
} }
} }
} }
} },
],
"description": "C.bad0_set_owner(address).new_owner (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#10) lacks a zero-check on :\n\t\t- owner = new_owner (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#11)\n",
"markdown": "[C.bad0_set_owner(address).new_owner](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L10) lacks a zero-check on :\n\t\t- [owner = new_owner](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L11)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L10",
"id": "ac59285350b35c2b885a6e9efe641474ae51b830fad5856f622fe264096e44cd",
"check": "missing-zero-check",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "variable", "type": "node",
"name": "addr", "name": "addr.send(msg.value)",
"source_mapping": { "source_mapping": {
"start": 256, "start": 348,
"length": 20, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
@ -287,10 +278,10 @@
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 16
], ],
"starting_column": 22, "starting_column": 5,
"ending_column": 42 "ending_column": 25
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -406,12 +397,23 @@
} }
} }
} }
}, }
],
"description": "C.bad1_send(address).addr (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#14) lacks a zero-check on :\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#15)\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#16)\n",
"markdown": "[C.bad1_send(address).addr](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L14) lacks a zero-check on :\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L15)\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L16)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L14",
"id": "3d9ba6630d8f1357ab26196f519d74d6410a8e52994ae341d26a17d466200308",
"check": "missing-zero-check",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "node", "type": "variable",
"name": "addr.send(msg.value)", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 298, "start": 401,
"length": 20, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
@ -419,28 +421,27 @@
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
15 19
], ],
"starting_column": 5, "starting_column": 26,
"ending_column": 25 "ending_column": 46
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1_send", "name": "bad2_transfer",
"source_mapping": { "source_mapping": {
"start": 237, "start": 378,
"length": 137, "length": 122,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 19,
15, 20,
16, 21
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -534,45 +535,44 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1_send(address)" "signature": "bad2_transfer(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr.send(msg.value)", "name": "addr.transfer(msg.value)",
"source_mapping": { "source_mapping": {
"start": 348, "start": 443,
"length": 20, "length": 24,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 25 "ending_column": 29
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1_send", "name": "bad2_transfer",
"source_mapping": { "source_mapping": {
"start": 237, "start": 378,
"length": 137, "length": 122,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 19,
15, 20,
16, 21
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -666,16 +666,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1_send(address)" "signature": "bad2_transfer(address)"
} }
} }
} }
} }
], ],
"description": "C.bad1_send(address).addr (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#14) lacks a zero-check on :\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#15)\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#16)\n", "description": "C.bad2_transfer(address).addr (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#19) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#20)\n",
"markdown": "[C.bad1_send(address).addr](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L14) lacks a zero-check on :\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L15)\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L16)\n", "markdown": "[C.bad2_transfer(address).addr](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L19) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L20)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L14", "first_markdown_element": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L19",
"id": "3d9ba6630d8f1357ab26196f519d74d6410a8e52994ae341d26a17d466200308", "id": "654c703c39420ad30e6624b6a98892faffc5e90820e7aabfd3cd66fe8870b7b8",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -686,7 +686,7 @@
"type": "variable", "type": "variable",
"name": "addr", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 401, "start": 527,
"length": 20, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
@ -694,7 +694,7 @@
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19 23
], ],
"starting_column": 26, "starting_column": 26,
"ending_column": 46 "ending_column": 46
@ -702,19 +702,20 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_transfer", "name": "bad3_transfer",
"source_mapping": { "source_mapping": {
"start": 378, "start": 504,
"length": 122, "length": 203,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 23,
20, 24,
21 25,
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -808,7 +809,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2_transfer(address)" "signature": "bad3_transfer(address)"
} }
} }
} }
@ -817,7 +818,7 @@
"type": "node", "type": "node",
"name": "addr.transfer(msg.value)", "name": "addr.transfer(msg.value)",
"source_mapping": { "source_mapping": {
"start": 443, "start": 569,
"length": 24, "length": 24,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
@ -825,7 +826,7 @@
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 24
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 29 "ending_column": 29
@ -833,19 +834,20 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_transfer", "name": "bad3_transfer",
"source_mapping": { "source_mapping": {
"start": 378, "start": 504,
"length": 122, "length": 203,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 23,
20, 24,
21 25,
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -939,16 +941,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2_transfer(address)" "signature": "bad3_transfer(address)"
} }
} }
} }
} }
], ],
"description": "C.bad2_transfer(address).addr (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#19) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#20)\n", "description": "C.bad3_transfer(address).addr (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#23) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#24)\n",
"markdown": "[C.bad2_transfer(address).addr](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L19) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L20)\n", "markdown": "[C.bad3_transfer(address).addr](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L23) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L24)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L19", "first_markdown_element": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L23",
"id": "654c703c39420ad30e6624b6a98892faffc5e90820e7aabfd3cd66fe8870b7b8", "id": "98f43dd716a11685725ad4c615b07dd773bcf0f1c7710357fa1a5606084dd999",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -959,7 +961,7 @@
"type": "variable", "type": "variable",
"name": "addr", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 527, "start": 730,
"length": 20, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
@ -967,28 +969,27 @@
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23 28
], ],
"starting_column": 26, "starting_column": 22,
"ending_column": 46 "ending_column": 42
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_transfer", "name": "bad4_call",
"source_mapping": { "source_mapping": {
"start": 504, "start": 711,
"length": 203, "length": 120,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 28,
24, 29,
25, 30
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1082,45 +1083,44 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_transfer(address)" "signature": "bad4_call(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr.transfer(msg.value)", "name": "addr.call.value(msg.value)()",
"source_mapping": { "source_mapping": {
"start": 569, "start": 772,
"length": 24, "length": 30,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
24 29
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 29 "ending_column": 35
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_transfer", "name": "bad4_call",
"source_mapping": { "source_mapping": {
"start": 504, "start": 711,
"length": 203, "length": 120,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 28,
24, 29,
25, 30
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1214,16 +1214,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_transfer(address)" "signature": "bad4_call(address)"
} }
} }
} }
} }
], ],
"description": "C.bad3_transfer(address).addr (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#23) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#24)\n", "description": "C.bad4_call(address).addr (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#28) lacks a zero-check on :\n\t\t- addr.call.value(msg.value)() (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#29)\n",
"markdown": "[C.bad3_transfer(address).addr](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L23) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L24)\n", "markdown": "[C.bad4_call(address).addr](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L28) lacks a zero-check on :\n\t\t- [addr.call.value(msg.value)()](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L29)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L23", "first_markdown_element": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L28",
"id": "98f43dd716a11685725ad4c615b07dd773bcf0f1c7710357fa1a5606084dd999", "id": "aa90b9a8002d093f5996492eae0d441bde928e8187fc6d2790f973f6383d6095",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -1232,37 +1232,37 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "addr", "name": "new_owner",
"source_mapping": { "source_mapping": {
"start": 730, "start": 149,
"length": 20, "length": 17,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28 10
], ],
"starting_column": 22, "starting_column": 27,
"ending_column": 42 "ending_column": 44
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad4_call", "name": "bad0_set_owner",
"source_mapping": { "source_mapping": {
"start": 711, "start": 125,
"length": 120, "length": 108,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28, 10,
29, 11,
30 12
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1356,44 +1356,44 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad4_call(address)" "signature": "bad0_set_owner(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr.call.value(msg.value)()", "name": "owner = new_owner",
"source_mapping": { "source_mapping": {
"start": 772, "start": 188,
"length": 30, "length": 17,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
29 11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 35 "ending_column": 22
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad4_call", "name": "bad0_set_owner",
"source_mapping": { "source_mapping": {
"start": 711, "start": 125,
"length": 120, "length": 108,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28, 10,
29, 11,
30 12
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1487,16 +1487,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad4_call(address)" "signature": "bad0_set_owner(address)"
} }
} }
} }
} }
], ],
"description": "C.bad4_call(address).addr (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#28) lacks a zero-check on :\n\t\t- addr.call.value(msg.value)() (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#29)\n", "description": "C.bad0_set_owner(address).new_owner (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#10) lacks a zero-check on :\n\t\t- owner = new_owner (tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#11)\n",
"markdown": "[C.bad4_call(address).addr](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L28) lacks a zero-check on :\n\t\t- [addr.call.value(msg.value)()](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L29)\n", "markdown": "[C.bad0_set_owner(address).new_owner](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L10) lacks a zero-check on :\n\t\t- [owner = new_owner](tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L11)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L28", "first_markdown_element": "tests/detectors/missing-zero-check/0.5.16/missing_zero_address_validation.sol#L10",
"id": "aa90b9a8002d093f5996492eae0d441bde928e8187fc6d2790f973f6383d6095", "id": "ac59285350b35c2b885a6e9efe641474ae51b830fad5856f622fe264096e44cd",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"

@ -4,37 +4,37 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "new_owner", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 149, "start": 730,
"length": 17, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 28
], ],
"starting_column": 27, "starting_column": 22,
"ending_column": 44 "ending_column": 42
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0_set_owner", "name": "bad4_call",
"source_mapping": { "source_mapping": {
"start": 125, "start": 711,
"length": 108, "length": 120,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10, 28,
11, 29,
12 30
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -128,44 +128,44 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0_set_owner(address)" "signature": "bad4_call(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = new_owner", "name": "addr.call.value(msg.value)()",
"source_mapping": { "source_mapping": {
"start": 188, "start": 772,
"length": 17, "length": 30,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11 29
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 22 "ending_column": 35
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0_set_owner", "name": "bad4_call",
"source_mapping": { "source_mapping": {
"start": 125, "start": 711,
"length": 108, "length": 120,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10, 28,
11, 29,
12 30
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -259,16 +259,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0_set_owner(address)" "signature": "bad4_call(address)"
} }
} }
} }
} }
], ],
"description": "C.bad0_set_owner(address).new_owner (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#10) lacks a zero-check on :\n\t\t- owner = new_owner (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#11)\n", "description": "C.bad4_call(address).addr (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#28) lacks a zero-check on :\n\t\t- addr.call.value(msg.value)() (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#29)\n",
"markdown": "[C.bad0_set_owner(address).new_owner](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L10) lacks a zero-check on :\n\t\t- [owner = new_owner](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L11)\n", "markdown": "[C.bad4_call(address).addr](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L28) lacks a zero-check on :\n\t\t- [addr.call.value(msg.value)()](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L29)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L10", "first_markdown_element": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L28",
"id": "1d2f6294ee0cfc4aae290fe04610e1df21d508008e75000ef017463482d78f95", "id": "174a4f81c4e872deda0a31c10f8136b52d60adc89ba9be1548b308a09e225763",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -277,38 +277,37 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "addr", "name": "new_owner",
"source_mapping": { "source_mapping": {
"start": 256, "start": 149,
"length": 20, "length": 17,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 10
], ],
"starting_column": 22, "starting_column": 27,
"ending_column": 42 "ending_column": 44
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1_send", "name": "bad0_set_owner",
"source_mapping": { "source_mapping": {
"start": 237, "start": 125,
"length": 137, "length": 108,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 10,
15, 11,
16, 12
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -402,45 +401,44 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1_send(address)" "signature": "bad0_set_owner(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr.send(msg.value)", "name": "owner = new_owner",
"source_mapping": { "source_mapping": {
"start": 298, "start": 188,
"length": 20, "length": 17,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
15 11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 25 "ending_column": 22
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1_send", "name": "bad0_set_owner",
"source_mapping": { "source_mapping": {
"start": 237, "start": 125,
"length": 137, "length": 108,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 10,
15, 11,
16, 12
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -534,16 +532,27 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1_send(address)" "signature": "bad0_set_owner(address)"
} }
} }
} }
}, }
],
"description": "C.bad0_set_owner(address).new_owner (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#10) lacks a zero-check on :\n\t\t- owner = new_owner (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#11)\n",
"markdown": "[C.bad0_set_owner(address).new_owner](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L10) lacks a zero-check on :\n\t\t- [owner = new_owner](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L11)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L10",
"id": "1d2f6294ee0cfc4aae290fe04610e1df21d508008e75000ef017463482d78f95",
"check": "missing-zero-check",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "node", "type": "variable",
"name": "addr.send(msg.value)", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 348, "start": 256,
"length": 20, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
@ -551,10 +560,10 @@
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16 14
], ],
"starting_column": 5, "starting_column": 22,
"ending_column": 25 "ending_column": 42
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -670,23 +679,12 @@
} }
} }
} }
} },
],
"description": "C.bad1_send(address).addr (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#14) lacks a zero-check on :\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#15)\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#16)\n",
"markdown": "[C.bad1_send(address).addr](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L14) lacks a zero-check on :\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L15)\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L16)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L14",
"id": "21de216080f0f27154e9b3cd2fef7ead38dacc945160b619923c33344d636826",
"check": "missing-zero-check",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "variable", "type": "node",
"name": "addr", "name": "addr.send(msg.value)",
"source_mapping": { "source_mapping": {
"start": 401, "start": 298,
"length": 20, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
@ -694,27 +692,28 @@
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19 15
], ],
"starting_column": 26, "starting_column": 5,
"ending_column": 46 "ending_column": 25
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_transfer", "name": "bad1_send",
"source_mapping": { "source_mapping": {
"start": 378, "start": 237,
"length": 122, "length": 137,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 14,
20, 15,
21 16,
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -808,44 +807,45 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2_transfer(address)" "signature": "bad1_send(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr.transfer(msg.value)", "name": "addr.send(msg.value)",
"source_mapping": { "source_mapping": {
"start": 443, "start": 348,
"length": 24, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 29 "ending_column": 25
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_transfer", "name": "bad1_send",
"source_mapping": { "source_mapping": {
"start": 378, "start": 237,
"length": 122, "length": 137,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 14,
20, 15,
21 16,
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -939,16 +939,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2_transfer(address)" "signature": "bad1_send(address)"
} }
} }
} }
} }
], ],
"description": "C.bad2_transfer(address).addr (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#19) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#20)\n", "description": "C.bad1_send(address).addr (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#14) lacks a zero-check on :\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#15)\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#16)\n",
"markdown": "[C.bad2_transfer(address).addr](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L19) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L20)\n", "markdown": "[C.bad1_send(address).addr](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L14) lacks a zero-check on :\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L15)\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L16)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L19", "first_markdown_element": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L14",
"id": "3d8300f19d40cb2f76fcb587f94e3dfc751319b119bd83af4cd7f962b680feb8", "id": "21de216080f0f27154e9b3cd2fef7ead38dacc945160b619923c33344d636826",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -959,7 +959,7 @@
"type": "variable", "type": "variable",
"name": "addr", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 527, "start": 401,
"length": 20, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
@ -967,7 +967,7 @@
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23 19
], ],
"starting_column": 26, "starting_column": 26,
"ending_column": 46 "ending_column": 46
@ -975,20 +975,19 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_transfer", "name": "bad2_transfer",
"source_mapping": { "source_mapping": {
"start": 504, "start": 378,
"length": 203, "length": 122,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 19,
24, 20,
25, 21
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1082,7 +1081,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_transfer(address)" "signature": "bad2_transfer(address)"
} }
} }
} }
@ -1091,7 +1090,7 @@
"type": "node", "type": "node",
"name": "addr.transfer(msg.value)", "name": "addr.transfer(msg.value)",
"source_mapping": { "source_mapping": {
"start": 569, "start": 443,
"length": 24, "length": 24,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
@ -1099,7 +1098,7 @@
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
24 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 29 "ending_column": 29
@ -1107,20 +1106,19 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_transfer", "name": "bad2_transfer",
"source_mapping": { "source_mapping": {
"start": 504, "start": 378,
"length": 203, "length": 122,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 19,
24, 20,
25, 21
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1214,16 +1212,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_transfer(address)" "signature": "bad2_transfer(address)"
} }
} }
} }
} }
], ],
"description": "C.bad3_transfer(address).addr (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#23) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#24)\n", "description": "C.bad2_transfer(address).addr (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#19) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#20)\n",
"markdown": "[C.bad3_transfer(address).addr](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L23) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L24)\n", "markdown": "[C.bad2_transfer(address).addr](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L19) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L20)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L23", "first_markdown_element": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L19",
"id": "efee9ceff8491c62ed42aab7c70b0a8d9c7731af8ecb304e6deafcc64a20c6f4", "id": "3d8300f19d40cb2f76fcb587f94e3dfc751319b119bd83af4cd7f962b680feb8",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -1234,7 +1232,7 @@
"type": "variable", "type": "variable",
"name": "addr", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 730, "start": 527,
"length": 20, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
@ -1242,27 +1240,28 @@
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28 23
], ],
"starting_column": 22, "starting_column": 26,
"ending_column": 42 "ending_column": 46
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad4_call", "name": "bad3_transfer",
"source_mapping": { "source_mapping": {
"start": 711, "start": 504,
"length": 120, "length": 203,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28, 23,
29, 24,
30 25,
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1356,44 +1355,45 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad4_call(address)" "signature": "bad3_transfer(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr.call.value(msg.value)()", "name": "addr.transfer(msg.value)",
"source_mapping": { "source_mapping": {
"start": 772, "start": 569,
"length": 30, "length": 24,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
29 24
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 35 "ending_column": 29
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad4_call", "name": "bad3_transfer",
"source_mapping": { "source_mapping": {
"start": 711, "start": 504,
"length": 120, "length": 203,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28, 23,
29, 24,
30 25,
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1487,16 +1487,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad4_call(address)" "signature": "bad3_transfer(address)"
} }
} }
} }
} }
], ],
"description": "C.bad4_call(address).addr (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#28) lacks a zero-check on :\n\t\t- addr.call.value(msg.value)() (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#29)\n", "description": "C.bad3_transfer(address).addr (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#23) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#24)\n",
"markdown": "[C.bad4_call(address).addr](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L28) lacks a zero-check on :\n\t\t- [addr.call.value(msg.value)()](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L29)\n", "markdown": "[C.bad3_transfer(address).addr](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L23) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L24)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L28", "first_markdown_element": "tests/detectors/missing-zero-check/0.6.11/missing_zero_address_validation.sol#L23",
"id": "174a4f81c4e872deda0a31c10f8136b52d60adc89ba9be1548b308a09e225763", "id": "efee9ceff8491c62ed42aab7c70b0a8d9c7731af8ecb304e6deafcc64a20c6f4",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"

@ -4,37 +4,38 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "new_owner", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 149, "start": 256,
"length": 17, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10 14
], ],
"starting_column": 27, "starting_column": 22,
"ending_column": 44 "ending_column": 42
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0_set_owner", "name": "bad1_send",
"source_mapping": { "source_mapping": {
"start": 125, "start": 237,
"length": 108, "length": 137,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10, 14,
11, 15,
12 16,
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -128,44 +129,45 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0_set_owner(address)" "signature": "bad1_send(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "owner = new_owner", "name": "addr.send(msg.value)",
"source_mapping": { "source_mapping": {
"start": 188, "start": 298,
"length": 17, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11 15
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 22 "ending_column": 25
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0_set_owner", "name": "bad1_send",
"source_mapping": { "source_mapping": {
"start": 125, "start": 237,
"length": 108, "length": 137,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
10, 14,
11, 15,
12 16,
17
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -259,27 +261,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0_set_owner(address)" "signature": "bad1_send(address)"
} }
} }
} }
} },
],
"description": "C.bad0_set_owner(address).new_owner (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#10) lacks a zero-check on :\n\t\t- owner = new_owner (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#11)\n",
"markdown": "[C.bad0_set_owner(address).new_owner](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L10) lacks a zero-check on :\n\t\t- [owner = new_owner](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L11)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L10",
"id": "2c8db81e6ce5a16bd76db4dd9d27d931037b6b06bacd06afa427e35f4dd22aa6",
"check": "missing-zero-check",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "variable", "type": "node",
"name": "addr", "name": "addr.send(msg.value)",
"source_mapping": { "source_mapping": {
"start": 256, "start": 348,
"length": 20, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
@ -287,10 +278,10 @@
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 16
], ],
"starting_column": 22, "starting_column": 5,
"ending_column": 42 "ending_column": 25
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -406,12 +397,23 @@
} }
} }
} }
}, }
],
"description": "C.bad1_send(address).addr (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#14) lacks a zero-check on :\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#15)\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#16)\n",
"markdown": "[C.bad1_send(address).addr](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L14) lacks a zero-check on :\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L15)\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L16)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L14",
"id": "1a145c4f40c60c9db09f5743139503a60b40be83dda9c57f8c47a400f1bc5b8a",
"check": "missing-zero-check",
"impact": "Low",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "node", "type": "variable",
"name": "addr.send(msg.value)", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 298, "start": 527,
"length": 20, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
@ -419,28 +421,28 @@
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
15 23
], ],
"starting_column": 5, "starting_column": 26,
"ending_column": 25 "ending_column": 46
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1_send", "name": "bad3_transfer",
"source_mapping": { "source_mapping": {
"start": 237, "start": 504,
"length": 137, "length": 203,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 23,
15, 24,
16, 25,
17 26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -534,45 +536,45 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1_send(address)" "signature": "bad3_transfer(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr.send(msg.value)", "name": "addr.transfer(msg.value)",
"source_mapping": { "source_mapping": {
"start": 348, "start": 569,
"length": 20, "length": 24,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16 24
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 25 "ending_column": 29
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1_send", "name": "bad3_transfer",
"source_mapping": { "source_mapping": {
"start": 237, "start": 504,
"length": 137, "length": 203,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 23,
15, 24,
16, 25,
17 26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -666,16 +668,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1_send(address)" "signature": "bad3_transfer(address)"
} }
} }
} }
} }
], ],
"description": "C.bad1_send(address).addr (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#14) lacks a zero-check on :\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#15)\n\t\t- addr.send(msg.value) (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#16)\n", "description": "C.bad3_transfer(address).addr (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#23) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#24)\n",
"markdown": "[C.bad1_send(address).addr](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L14) lacks a zero-check on :\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L15)\n\t\t- [addr.send(msg.value)](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L16)\n", "markdown": "[C.bad3_transfer(address).addr](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L23) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L24)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L14", "first_markdown_element": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L23",
"id": "1a145c4f40c60c9db09f5743139503a60b40be83dda9c57f8c47a400f1bc5b8a", "id": "1cc3cad32b73e31e6d6f214b9a99b19c5bd5633ddf3ab58267a5870051c22a02",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -684,37 +686,37 @@
"elements": [ "elements": [
{ {
"type": "variable", "type": "variable",
"name": "addr", "name": "new_owner",
"source_mapping": { "source_mapping": {
"start": 401, "start": 149,
"length": 20, "length": 17,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19 10
], ],
"starting_column": 26, "starting_column": 27,
"ending_column": 46 "ending_column": 44
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_transfer", "name": "bad0_set_owner",
"source_mapping": { "source_mapping": {
"start": 378, "start": 125,
"length": 122, "length": 108,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 10,
20, 11,
21 12
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -808,44 +810,44 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2_transfer(address)" "signature": "bad0_set_owner(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr.transfer(msg.value)", "name": "owner = new_owner",
"source_mapping": { "source_mapping": {
"start": 443, "start": 188,
"length": 24, "length": 17,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20 11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 29 "ending_column": 22
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_transfer", "name": "bad0_set_owner",
"source_mapping": { "source_mapping": {
"start": 378, "start": 125,
"length": 122, "length": 108,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
19, 10,
20, 11,
21 12
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -939,16 +941,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad2_transfer(address)" "signature": "bad0_set_owner(address)"
} }
} }
} }
} }
], ],
"description": "C.bad2_transfer(address).addr (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#19) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#20)\n", "description": "C.bad0_set_owner(address).new_owner (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#10) lacks a zero-check on :\n\t\t- owner = new_owner (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#11)\n",
"markdown": "[C.bad2_transfer(address).addr](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L19) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L20)\n", "markdown": "[C.bad0_set_owner(address).new_owner](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L10) lacks a zero-check on :\n\t\t- [owner = new_owner](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L11)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L19", "first_markdown_element": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L10",
"id": "f7028c02d7b7a78ef72a33c7b976bcb047206b9c82a9acc39cdf11a5e188208f", "id": "2c8db81e6ce5a16bd76db4dd9d27d931037b6b06bacd06afa427e35f4dd22aa6",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -959,7 +961,7 @@
"type": "variable", "type": "variable",
"name": "addr", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 527, "start": 730,
"length": 20, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
@ -967,28 +969,27 @@
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23 28
], ],
"starting_column": 26, "starting_column": 22,
"ending_column": 46 "ending_column": 42
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_transfer", "name": "bad4_call",
"source_mapping": { "source_mapping": {
"start": 504, "start": 711,
"length": 203, "length": 120,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 28,
24, 29,
25, 30
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1082,45 +1083,44 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_transfer(address)" "signature": "bad4_call(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr.transfer(msg.value)", "name": "addr.call{value: msg.value}()",
"source_mapping": { "source_mapping": {
"start": 569, "start": 772,
"length": 24, "length": 30,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
24 29
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 29 "ending_column": 35
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3_transfer", "name": "bad4_call",
"source_mapping": { "source_mapping": {
"start": 504, "start": 711,
"length": 203, "length": 120,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
23, 28,
24, 29,
25, 30
26
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1214,16 +1214,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad3_transfer(address)" "signature": "bad4_call(address)"
} }
} }
} }
} }
], ],
"description": "C.bad3_transfer(address).addr (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#23) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#24)\n", "description": "C.bad4_call(address).addr (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#28) lacks a zero-check on :\n\t\t- addr.call{value: msg.value}() (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#29)\n",
"markdown": "[C.bad3_transfer(address).addr](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L23) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L24)\n", "markdown": "[C.bad4_call(address).addr](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L28) lacks a zero-check on :\n\t\t- [addr.call{value: msg.value}()](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L29)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L23", "first_markdown_element": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L28",
"id": "1cc3cad32b73e31e6d6f214b9a99b19c5bd5633ddf3ab58267a5870051c22a02", "id": "64e549d94c8869ed8c827ad3ee766cb23d4e8a64bc9b19e06d593fa8942363b4",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"
@ -1234,7 +1234,7 @@
"type": "variable", "type": "variable",
"name": "addr", "name": "addr",
"source_mapping": { "source_mapping": {
"start": 730, "start": 401,
"length": 20, "length": 20,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
@ -1242,27 +1242,27 @@
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28 19
], ],
"starting_column": 22, "starting_column": 26,
"ending_column": 42 "ending_column": 46
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad4_call", "name": "bad2_transfer",
"source_mapping": { "source_mapping": {
"start": 711, "start": 378,
"length": 120, "length": 122,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28, 19,
29, 20,
30 21
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1356,44 +1356,44 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad4_call(address)" "signature": "bad2_transfer(address)"
} }
} }
} }
}, },
{ {
"type": "node", "type": "node",
"name": "addr.call{value: msg.value}()", "name": "addr.transfer(msg.value)",
"source_mapping": { "source_mapping": {
"start": 772, "start": 443,
"length": 30, "length": 24,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
29 20
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 35 "ending_column": 29
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad4_call", "name": "bad2_transfer",
"source_mapping": { "source_mapping": {
"start": 711, "start": 378,
"length": 120, "length": 122,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_relative": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol", "filename_short": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28, 19,
29, 20,
30 21
], ],
"starting_column": 3, "starting_column": 3,
"ending_column": 4 "ending_column": 4
@ -1487,16 +1487,16 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad4_call(address)" "signature": "bad2_transfer(address)"
} }
} }
} }
} }
], ],
"description": "C.bad4_call(address).addr (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#28) lacks a zero-check on :\n\t\t- addr.call{value: msg.value}() (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#29)\n", "description": "C.bad2_transfer(address).addr (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#19) lacks a zero-check on :\n\t\t- addr.transfer(msg.value) (tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#20)\n",
"markdown": "[C.bad4_call(address).addr](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L28) lacks a zero-check on :\n\t\t- [addr.call{value: msg.value}()](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L29)\n", "markdown": "[C.bad2_transfer(address).addr](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L19) lacks a zero-check on :\n\t\t- [addr.transfer(msg.value)](tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L20)\n",
"first_markdown_element": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L28", "first_markdown_element": "tests/detectors/missing-zero-check/0.7.6/missing_zero_address_validation.sol#L19",
"id": "64e549d94c8869ed8c827ad3ee766cb23d4e8a64bc9b19e06d593fa8942363b4", "id": "f7028c02d7b7a78ef72a33c7b976bcb047206b9c82a9acc39cdf11a5e188208f",
"check": "missing-zero-check", "check": "missing-zero-check",
"impact": "Low", "impact": "Low",
"confidence": "Medium" "confidence": "Medium"

@ -4,21 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad", "name": "bad2_internal",
"source_mapping": { "source_mapping": {
"start": 61, "start": 425,
"length": 179, "length": 84,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 17,
6, 18,
7, 19
8,
9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -71,44 +69,42 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad(address[])" "signature": "bad2_internal(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "balances[receivers[i]] += msg.value", "name": "balances[a] += msg.value",
"source_mapping": { "source_mapping": {
"start": 188, "start": 478,
"length": 35, "length": 24,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 18
], ],
"starting_column": 13, "starting_column": 9,
"ending_column": 48 "ending_column": 33
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad", "name": "bad2_internal",
"source_mapping": { "source_mapping": {
"start": 61, "start": 425,
"length": 179, "length": 84,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 17,
6, 18,
7, 19
8,
9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -161,16 +157,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad(address[])" "signature": "bad2_internal(address)"
} }
} }
} }
} }
], ],
"description": "C.bad(address[]) (tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#5-9) use msg.value in a loop: balances[receivers[i]] += msg.value (tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#7)\n", "description": "C.bad2_internal(address) (tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#17-19) use msg.value in a loop: balances[a] += msg.value (tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#18)\n",
"markdown": "[C.bad(address[])](tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#L5-L9) use msg.value in a loop: [balances[receivers[i]] += msg.value](tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#L7)\n", "markdown": "[C.bad2_internal(address)](tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#L17-L19) use msg.value in a loop: [balances[a] += msg.value](tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#L18)\n",
"first_markdown_element": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#L5-L9", "first_markdown_element": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#L17-L19",
"id": "b8e2b147c51a880dc38a635915a0511954ade8ffeab3efd16e389a370e0c0b1b", "id": "84b39e0706b72e42b4cf069a649c5825e35ed842871350cc064c8123396b6f96",
"check": "msg-value-loop", "check": "msg-value-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -179,19 +175,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2_internal", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 425, "start": 61,
"length": 84, "length": 179,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
17, 5,
18, 6,
19 7,
8,
9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -244,42 +242,44 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad2_internal(address)" "signature": "bad(address[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "balances[a] += msg.value", "name": "balances[receivers[i]] += msg.value",
"source_mapping": { "source_mapping": {
"start": 478, "start": 188,
"length": 24, "length": 35,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
18 7
], ],
"starting_column": 9, "starting_column": 13,
"ending_column": 33 "ending_column": 48
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_internal", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 425, "start": 61,
"length": 84, "length": 179,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
17, 5,
18, 6,
19 7,
8,
9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -332,16 +332,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad2_internal(address)" "signature": "bad(address[])"
} }
} }
} }
} }
], ],
"description": "C.bad2_internal(address) (tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#17-19) use msg.value in a loop: balances[a] += msg.value (tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#18)\n", "description": "C.bad(address[]) (tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#5-9) use msg.value in a loop: balances[receivers[i]] += msg.value (tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#7)\n",
"markdown": "[C.bad2_internal(address)](tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#L17-L19) use msg.value in a loop: [balances[a] += msg.value](tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#L18)\n", "markdown": "[C.bad(address[])](tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#L5-L9) use msg.value in a loop: [balances[receivers[i]] += msg.value](tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#L7)\n",
"first_markdown_element": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#L17-L19", "first_markdown_element": "tests/detectors/msg-value-loop/0.6.11/msg_value_loop.sol#L5-L9",
"id": "84b39e0706b72e42b4cf069a649c5825e35ed842871350cc064c8123396b6f96", "id": "b8e2b147c51a880dc38a635915a0511954ade8ffeab3efd16e389a370e0c0b1b",
"check": "msg-value-loop", "check": "msg-value-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -4,21 +4,19 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad", "name": "bad2_internal",
"source_mapping": { "source_mapping": {
"start": 61, "start": 425,
"length": 179, "length": 84,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 17,
6, 18,
7, 19
8,
9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -71,44 +69,42 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad(address[])" "signature": "bad2_internal(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "balances[receivers[i]] += msg.value", "name": "balances[a] += msg.value",
"source_mapping": { "source_mapping": {
"start": 188, "start": 478,
"length": 35, "length": 24,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 18
], ],
"starting_column": 13, "starting_column": 9,
"ending_column": 48 "ending_column": 33
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad", "name": "bad2_internal",
"source_mapping": { "source_mapping": {
"start": 61, "start": 425,
"length": 179, "length": 84,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 17,
6, 18,
7, 19
8,
9
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -161,16 +157,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad(address[])" "signature": "bad2_internal(address)"
} }
} }
} }
} }
], ],
"description": "C.bad(address[]) (tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#5-9) use msg.value in a loop: balances[receivers[i]] += msg.value (tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#7)\n", "description": "C.bad2_internal(address) (tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#17-19) use msg.value in a loop: balances[a] += msg.value (tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#18)\n",
"markdown": "[C.bad(address[])](tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L5-L9) use msg.value in a loop: [balances[receivers[i]] += msg.value](tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L7)\n", "markdown": "[C.bad2_internal(address)](tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L17-L19) use msg.value in a loop: [balances[a] += msg.value](tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L18)\n",
"first_markdown_element": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L5-L9", "first_markdown_element": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L17-L19",
"id": "fd0c2f6abecbecd689c995b2cd3c30c9f1bd3763e34f4d5cb91788604f8ec3da", "id": "0fd3ac1c8051090ec1fe86fa9e1e5f8e7381d8eef3f252fede8dc3bb07e87104",
"check": "msg-value-loop", "check": "msg-value-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -179,19 +175,23 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad2_internal", "name": "bad3",
"source_mapping": { "source_mapping": {
"start": 425, "start": 515,
"length": 84, "length": 245,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
17, 21,
18, 22,
19 23,
24,
25,
26,
27
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -244,42 +244,46 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad2_internal(address)" "signature": "bad3(address[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "balances[a] += msg.value", "name": "balances[receivers[j]] += msg.value",
"source_mapping": { "source_mapping": {
"start": 478, "start": 694,
"length": 24, "length": 35,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
18 24
], ],
"starting_column": 9, "starting_column": 17,
"ending_column": 33 "ending_column": 52
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad2_internal", "name": "bad3",
"source_mapping": { "source_mapping": {
"start": 425, "start": 515,
"length": 84, "length": 245,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
17, 21,
18, 22,
19 23,
24,
25,
26,
27
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -332,16 +336,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad2_internal(address)" "signature": "bad3(address[])"
} }
} }
} }
} }
], ],
"description": "C.bad2_internal(address) (tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#17-19) use msg.value in a loop: balances[a] += msg.value (tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#18)\n", "description": "C.bad3(address[]) (tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#21-27) use msg.value in a loop: balances[receivers[j]] += msg.value (tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#24)\n",
"markdown": "[C.bad2_internal(address)](tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L17-L19) use msg.value in a loop: [balances[a] += msg.value](tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L18)\n", "markdown": "[C.bad3(address[])](tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L21-L27) use msg.value in a loop: [balances[receivers[j]] += msg.value](tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L24)\n",
"first_markdown_element": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L17-L19", "first_markdown_element": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L21-L27",
"id": "0fd3ac1c8051090ec1fe86fa9e1e5f8e7381d8eef3f252fede8dc3bb07e87104", "id": "9a021823637092277317750625e1f63b1b6f4b394a5dd1fdde50088af8d9e805",
"check": "msg-value-loop", "check": "msg-value-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -350,23 +354,21 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad3", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 515, "start": 61,
"length": 245, "length": 179,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
21, 5,
22, 6,
23, 7,
24, 8,
25, 9
26,
27
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -419,14 +421,14 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad3(address[])" "signature": "bad(address[])"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "balances[receivers[j]] += msg.value", "name": "balances[receivers[i]] += msg.value",
"source_mapping": { "source_mapping": {
"start": 694, "start": 188,
"length": 35, "length": 35,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
@ -434,31 +436,29 @@
"filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
24 7
], ],
"starting_column": 17, "starting_column": 13,
"ending_column": 52 "ending_column": 48
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad3", "name": "bad",
"source_mapping": { "source_mapping": {
"start": 515, "start": 61,
"length": 245, "length": 179,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_relative": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol", "filename_short": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
21, 5,
22, 6,
23, 7,
24, 8,
25, 9
26,
27
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -511,16 +511,16 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "bad3(address[])" "signature": "bad(address[])"
} }
} }
} }
} }
], ],
"description": "C.bad3(address[]) (tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#21-27) use msg.value in a loop: balances[receivers[j]] += msg.value (tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#24)\n", "description": "C.bad(address[]) (tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#5-9) use msg.value in a loop: balances[receivers[i]] += msg.value (tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#7)\n",
"markdown": "[C.bad3(address[])](tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L21-L27) use msg.value in a loop: [balances[receivers[j]] += msg.value](tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L24)\n", "markdown": "[C.bad(address[])](tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L5-L9) use msg.value in a loop: [balances[receivers[i]] += msg.value](tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L7)\n",
"first_markdown_element": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L21-L27", "first_markdown_element": "tests/detectors/msg-value-loop/0.7.6/msg_value_loop.sol#L5-L9",
"id": "9a021823637092277317750625e1f63b1b6f4b394a5dd1fdde50088af8d9e805", "id": "fd0c2f6abecbecd689c995b2cd3c30c9f1bd3763e34f4d5cb91788604f8ec3da",
"check": "msg-value-loop", "check": "msg-value-loop",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -126,9 +126,9 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "bool", "name": "uint256",
"source_mapping": { "source_mapping": {
"start": 155, "start": 257,
"length": 4, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
@ -136,7 +136,7 @@
"filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 12
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 13
@ -144,21 +144,22 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "constructor", "name": "test",
"source_mapping": { "source_mapping": {
"start": 110, "start": 209,
"length": 93, "length": 109,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 11,
6, 12,
7, 13,
8, 14,
9 15,
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -197,7 +198,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "constructor()" "signature": "test()"
} }
} }
} }
@ -236,10 +237,10 @@
} }
} }
], ],
"description": "Redundant expression \"bool (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#7)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"uint256 (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#12)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[bool](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L7)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[uint256](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L12)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L7", "first_markdown_element": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L12",
"id": "da776628bba71bca43caf77bb06a7055fe3c0f4f18a30274c5cb508bcb3a27b4", "id": "7423f2beb0d066fc4e193c27dd50b172186e9539b778ab72bf950dbe872df720",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -248,39 +249,40 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "RedundantStatementsContract", "name": "test",
"source_mapping": { "source_mapping": {
"start": 169, "start": 287,
"length": 27, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8 14
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 36 "ending_column": 13
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "constructor", "name": "test",
"source_mapping": { "source_mapping": {
"start": 110, "start": 209,
"length": 93, "length": 109,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 11,
6, 12,
7, 13,
8, 14,
9 15,
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -319,7 +321,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "constructor()" "signature": "test()"
} }
} }
} }
@ -358,10 +360,10 @@
} }
} }
], ],
"description": "Redundant expression \"RedundantStatementsContract (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#8)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"test (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#14)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[RedundantStatementsContract](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L8)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[test](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L14)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L8", "first_markdown_element": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L14",
"id": "cb9ace5d0188d80bdc530d3760b41a1dcf1a4c10151b720e468550bb22be0e74", "id": "c3c9961e4467e57974929ecfaeb34a0923fc257422a7705c9d1b14257cfe0c3a",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -370,40 +372,39 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "uint256", "name": "RedundantStatementsContract",
"source_mapping": { "source_mapping": {
"start": 257, "start": 169,
"length": 4, "length": 27,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
12 8
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 36
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "test", "name": "constructor",
"source_mapping": { "source_mapping": {
"start": 209, "start": 110,
"length": 109, "length": 93,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 5,
12, 6,
13, 7,
14, 8,
15, 9
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -442,7 +443,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "test()" "signature": "constructor()"
} }
} }
} }
@ -481,10 +482,10 @@
} }
} }
], ],
"description": "Redundant expression \"uint256 (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#12)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"RedundantStatementsContract (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#8)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[uint256](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L12)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[RedundantStatementsContract](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L8)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L12", "first_markdown_element": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L8",
"id": "7423f2beb0d066fc4e193c27dd50b172186e9539b778ab72bf950dbe872df720", "id": "cb9ace5d0188d80bdc530d3760b41a1dcf1a4c10151b720e468550bb22be0e74",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -493,40 +494,39 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "assert(bool)", "name": "bool",
"source_mapping": { "source_mapping": {
"start": 271, "start": 155,
"length": 6, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
13 7
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 15 "ending_column": 13
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "test", "name": "constructor",
"source_mapping": { "source_mapping": {
"start": 209, "start": 110,
"length": 109, "length": 93,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 5,
12, 6,
13, 7,
14, 8,
15, 9
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -565,7 +565,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "test()" "signature": "constructor()"
} }
} }
} }
@ -604,10 +604,10 @@
} }
} }
], ],
"description": "Redundant expression \"assert(bool) (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#13)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"bool (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#7)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[assert(bool)](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L13)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[bool](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L7)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L13", "first_markdown_element": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L7",
"id": "e0137cf6a61eb49d07e1a67a7cdfd0cb82cac0402cded9f1cfb85ae1e6e8d3fe", "id": "da776628bba71bca43caf77bb06a7055fe3c0f4f18a30274c5cb508bcb3a27b4",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -616,20 +616,20 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "test", "name": "assert(bool)",
"source_mapping": { "source_mapping": {
"start": 287, "start": 271,
"length": 4, "length": 6,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 13
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 15
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -727,10 +727,10 @@
} }
} }
], ],
"description": "Redundant expression \"test (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#14)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"assert(bool) (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#13)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[test](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L14)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[assert(bool)](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L13)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L14", "first_markdown_element": "tests/detectors/redundant-statements/0.4.25/redundant_statements.sol#L13",
"id": "c3c9961e4467e57974929ecfaeb34a0923fc257422a7705c9d1b14257cfe0c3a", "id": "e0137cf6a61eb49d07e1a67a7cdfd0cb82cac0402cded9f1cfb85ae1e6e8d3fe",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -4,39 +4,40 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "uint256", "name": "assert(bool)",
"source_mapping": { "source_mapping": {
"start": 141, "start": 271,
"length": 4, "length": 6,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6 13
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 15
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "constructor", "name": "test",
"source_mapping": { "source_mapping": {
"start": 110, "start": 209,
"length": 93, "length": 109,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 11,
6, 12,
7, 13,
8, 14,
9 15,
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -75,7 +76,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "constructor()" "signature": "test()"
} }
} }
} }
@ -114,10 +115,10 @@
} }
} }
], ],
"description": "Redundant expression \"uint256 (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#6)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"assert(bool) (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#13)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[uint256](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L6)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[assert(bool)](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L13)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L6", "first_markdown_element": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L13",
"id": "58d73cb2126e8c76752e57c69feeed96ee7db0cc50cf33c0f92679525acc26e9", "id": "342d8ac4c8c6e96ca7ca18f4bb9abed731c08b4c19a4461151ea48fc503be342",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -126,9 +127,9 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "bool", "name": "uint256",
"source_mapping": { "source_mapping": {
"start": 155, "start": 141,
"length": 4, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
@ -136,7 +137,7 @@
"filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 6
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 13
@ -236,10 +237,10 @@
} }
} }
], ],
"description": "Redundant expression \"bool (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#7)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"uint256 (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#6)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[bool](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L7)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[uint256](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L6)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L7", "first_markdown_element": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L6",
"id": "f57f949deb97e88dedd17864427a4941d1395be24db436d3a45945a45c53b919", "id": "58d73cb2126e8c76752e57c69feeed96ee7db0cc50cf33c0f92679525acc26e9",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -248,39 +249,40 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "RedundantStatementsContract", "name": "test",
"source_mapping": { "source_mapping": {
"start": 169, "start": 287,
"length": 27, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8 14
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 36 "ending_column": 13
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "constructor", "name": "test",
"source_mapping": { "source_mapping": {
"start": 110, "start": 209,
"length": 93, "length": 109,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 11,
6, 12,
7, 13,
8, 14,
9 15,
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -319,7 +321,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "constructor()" "signature": "test()"
} }
} }
} }
@ -358,10 +360,10 @@
} }
} }
], ],
"description": "Redundant expression \"RedundantStatementsContract (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#8)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"test (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#14)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[RedundantStatementsContract](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L8)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[test](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L14)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L8", "first_markdown_element": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L14",
"id": "faaa2cdb764d49e4d06709c566d903cc4b222634a27b31bbbb0217a13b84aa62", "id": "b36c497f678f32a5479ead924c310a0c86b398e465f69b0e7365f06befaef172",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -493,40 +495,39 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "assert(bool)", "name": "bool",
"source_mapping": { "source_mapping": {
"start": 271, "start": 155,
"length": 6, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
13 7
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 15 "ending_column": 13
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "test", "name": "constructor",
"source_mapping": { "source_mapping": {
"start": 209, "start": 110,
"length": 109, "length": 93,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 5,
12, 6,
13, 7,
14, 8,
15, 9
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -565,7 +566,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "test()" "signature": "constructor()"
} }
} }
} }
@ -604,10 +605,10 @@
} }
} }
], ],
"description": "Redundant expression \"assert(bool) (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#13)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"bool (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#7)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[assert(bool)](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L13)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[bool](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L7)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L13", "first_markdown_element": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L7",
"id": "342d8ac4c8c6e96ca7ca18f4bb9abed731c08b4c19a4461151ea48fc503be342", "id": "f57f949deb97e88dedd17864427a4941d1395be24db436d3a45945a45c53b919",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -616,40 +617,39 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "test", "name": "RedundantStatementsContract",
"source_mapping": { "source_mapping": {
"start": 287, "start": 169,
"length": 4, "length": 27,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 8
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 36
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "test", "name": "constructor",
"source_mapping": { "source_mapping": {
"start": 209, "start": 110,
"length": 109, "length": 93,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 5,
12, 6,
13, 7,
14, 8,
15, 9
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -688,7 +688,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "test()" "signature": "constructor()"
} }
} }
} }
@ -727,10 +727,10 @@
} }
} }
], ],
"description": "Redundant expression \"test (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#14)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"RedundantStatementsContract (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#8)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[test](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L14)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[RedundantStatementsContract](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L8)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L14", "first_markdown_element": "tests/detectors/redundant-statements/0.5.16/redundant_statements.sol#L8",
"id": "b36c497f678f32a5479ead924c310a0c86b398e465f69b0e7365f06befaef172", "id": "faaa2cdb764d49e4d06709c566d903cc4b222634a27b31bbbb0217a13b84aa62",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -4,20 +4,20 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "uint256", "name": "RedundantStatementsContract",
"source_mapping": { "source_mapping": {
"start": 141, "start": 169,
"length": 4, "length": 27,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6 8
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 36
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -114,10 +114,10 @@
} }
} }
], ],
"description": "Redundant expression \"uint256 (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#6)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"RedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#8)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[uint256](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L6)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L8)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L6", "first_markdown_element": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L8",
"id": "c58083eaf5653fc9616833c617157456ad9088c4638009d9cdfebdc1445671bd", "id": "1ffcec7a83522ce311c8410e5523283b97944a0c27356e3141b26a7f32a022d3",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -126,9 +126,9 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "bool", "name": "test",
"source_mapping": { "source_mapping": {
"start": 155, "start": 287,
"length": 4, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
@ -136,7 +136,7 @@
"filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7 14
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 13
@ -144,21 +144,22 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "constructor", "name": "test",
"source_mapping": { "source_mapping": {
"start": 110, "start": 209,
"length": 93, "length": 109,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 11,
6, 12,
7, 13,
8, 14,
9 15,
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -197,7 +198,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "constructor()" "signature": "test()"
} }
} }
} }
@ -236,10 +237,10 @@
} }
} }
], ],
"description": "Redundant expression \"bool (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#7)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"test (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#14)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[bool](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L7)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[test](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L14)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L7", "first_markdown_element": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L14",
"id": "f0fef441fabe415b9cbc63bfc5a2a5c69f6248ce22d1bd94f73979f928cb7dba", "id": "5223d6cc441a1f923616873898ea34e0ff11a758c38d6b5244b9e9ea6be9bec8",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -248,39 +249,40 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "RedundantStatementsContract", "name": "uint256",
"source_mapping": { "source_mapping": {
"start": 169, "start": 257,
"length": 27, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8 12
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 36 "ending_column": 13
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "constructor", "name": "test",
"source_mapping": { "source_mapping": {
"start": 110, "start": 209,
"length": 93, "length": 109,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 11,
6, 12,
7, 13,
8, 14,
9 15,
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -319,7 +321,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "constructor()" "signature": "test()"
} }
} }
} }
@ -358,10 +360,10 @@
} }
} }
], ],
"description": "Redundant expression \"RedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#8)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"uint256 (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#12)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L8)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[uint256](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L12)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L8", "first_markdown_element": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L12",
"id": "1ffcec7a83522ce311c8410e5523283b97944a0c27356e3141b26a7f32a022d3", "id": "53f741bfdd4465fbdb8799391ca2fa50ac657b72ac9b822c87e2e4ae79d831d8",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -372,7 +374,7 @@
"type": "node", "type": "node",
"name": "uint256", "name": "uint256",
"source_mapping": { "source_mapping": {
"start": 257, "start": 141,
"length": 4, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
@ -380,7 +382,7 @@
"filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
12 6
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 13
@ -388,22 +390,21 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "test", "name": "constructor",
"source_mapping": { "source_mapping": {
"start": 209, "start": 110,
"length": 109, "length": 93,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 5,
12, 6,
13, 7,
14, 8,
15, 9
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -442,7 +443,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "test()" "signature": "constructor()"
} }
} }
} }
@ -481,10 +482,10 @@
} }
} }
], ],
"description": "Redundant expression \"uint256 (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#12)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"uint256 (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#6)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[uint256](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L12)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[uint256](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L6)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L12", "first_markdown_element": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L6",
"id": "53f741bfdd4465fbdb8799391ca2fa50ac657b72ac9b822c87e2e4ae79d831d8", "id": "c58083eaf5653fc9616833c617157456ad9088c4638009d9cdfebdc1445671bd",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -493,40 +494,39 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "assert(bool)", "name": "bool",
"source_mapping": { "source_mapping": {
"start": 271, "start": 155,
"length": 6, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
13 7
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 15 "ending_column": 13
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "test", "name": "constructor",
"source_mapping": { "source_mapping": {
"start": 209, "start": 110,
"length": 109, "length": 93,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 5,
12, 6,
13, 7,
14, 8,
15, 9
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -565,7 +565,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "test()" "signature": "constructor()"
} }
} }
} }
@ -604,10 +604,10 @@
} }
} }
], ],
"description": "Redundant expression \"assert(bool) (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#13)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"bool (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#7)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[assert(bool)](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L13)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[bool](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L7)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L13", "first_markdown_element": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L7",
"id": "f902982db50d530e22b29f35ab1a740f1af29683b0ebb9edd53240721b4f95b9", "id": "f0fef441fabe415b9cbc63bfc5a2a5c69f6248ce22d1bd94f73979f928cb7dba",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -616,20 +616,20 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "test", "name": "assert(bool)",
"source_mapping": { "source_mapping": {
"start": 287, "start": 271,
"length": 4, "length": 6,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 13
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 15
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -727,10 +727,10 @@
} }
} }
], ],
"description": "Redundant expression \"test (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#14)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"assert(bool) (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#13)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[test](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L14)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[assert(bool)](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L13)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L14", "first_markdown_element": "tests/detectors/redundant-statements/0.6.11/redundant_statements.sol#L13",
"id": "5223d6cc441a1f923616873898ea34e0ff11a758c38d6b5244b9e9ea6be9bec8", "id": "f902982db50d530e22b29f35ab1a740f1af29683b0ebb9edd53240721b4f95b9",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -4,9 +4,9 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "uint256", "name": "test",
"source_mapping": { "source_mapping": {
"start": 141, "start": 287,
"length": 4, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
@ -14,7 +14,7 @@
"filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
6 14
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 13
@ -22,21 +22,22 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "constructor", "name": "test",
"source_mapping": { "source_mapping": {
"start": 110, "start": 209,
"length": 93, "length": 109,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 11,
6, 12,
7, 13,
8, 14,
9 15,
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -75,7 +76,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "constructor()" "signature": "test()"
} }
} }
} }
@ -114,10 +115,10 @@
} }
} }
], ],
"description": "Redundant expression \"uint256 (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#6)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"test (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#14)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[uint256](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L6)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[test](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L14)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L6", "first_markdown_element": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L14",
"id": "d16c698a23693dc64165fc886c68f6900a7a2699998f0f3713d875cf49a2af87", "id": "45bb5d6a69015db0e07e6d13107db089e1095da3cf0918f624db12181fac28a1",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -248,39 +249,40 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "RedundantStatementsContract", "name": "assert(bool)",
"source_mapping": { "source_mapping": {
"start": 169, "start": 271,
"length": 27, "length": 6,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8 13
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 36 "ending_column": 15
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "constructor", "name": "test",
"source_mapping": { "source_mapping": {
"start": 110, "start": 209,
"length": 93, "length": 109,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
5, 11,
6, 12,
7, 13,
8, 14,
9 15,
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -319,7 +321,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "constructor()" "signature": "test()"
} }
} }
} }
@ -358,10 +360,10 @@
} }
} }
], ],
"description": "Redundant expression \"RedundantStatementsContract (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#8)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"assert(bool) (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#13)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[RedundantStatementsContract](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L8)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[assert(bool)](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L13)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L8", "first_markdown_element": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L13",
"id": "caf262c2d237789c12de0cf27ef88625491b29a1bc3209ced3a12d2890fc799e", "id": "774a4440b59af9fa94c7552ba0ce21a7835511012dc6257afc3fd4d80a023b28",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -370,40 +372,39 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "uint256", "name": "RedundantStatementsContract",
"source_mapping": { "source_mapping": {
"start": 257, "start": 169,
"length": 4, "length": 27,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
12 8
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 36
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "test", "name": "constructor",
"source_mapping": { "source_mapping": {
"start": 209, "start": 110,
"length": 109, "length": 93,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 5,
12, 6,
13, 7,
14, 8,
15, 9
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -442,7 +443,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "test()" "signature": "constructor()"
} }
} }
} }
@ -481,10 +482,10 @@
} }
} }
], ],
"description": "Redundant expression \"uint256 (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#12)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"RedundantStatementsContract (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#8)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[uint256](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L12)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[RedundantStatementsContract](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L8)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L12", "first_markdown_element": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L8",
"id": "ffe6709dbcfc3342d28833aad5375135da8cc7369bf0649ab1796ff4eae14ca1", "id": "caf262c2d237789c12de0cf27ef88625491b29a1bc3209ced3a12d2890fc799e",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -493,40 +494,39 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "assert(bool)", "name": "uint256",
"source_mapping": { "source_mapping": {
"start": 271, "start": 141,
"length": 6, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
13 6
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 15 "ending_column": 13
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "test", "name": "constructor",
"source_mapping": { "source_mapping": {
"start": 209, "start": 110,
"length": 109, "length": 93,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
11, 5,
12, 6,
13, 7,
14, 8,
15, 9
16
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -565,7 +565,7 @@
"ending_column": 0 "ending_column": 0
} }
}, },
"signature": "test()" "signature": "constructor()"
} }
} }
} }
@ -604,10 +604,10 @@
} }
} }
], ],
"description": "Redundant expression \"assert(bool) (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#13)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"uint256 (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#6)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[assert(bool)](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L13)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[uint256](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L6)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L13", "first_markdown_element": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L6",
"id": "774a4440b59af9fa94c7552ba0ce21a7835511012dc6257afc3fd4d80a023b28", "id": "d16c698a23693dc64165fc886c68f6900a7a2699998f0f3713d875cf49a2af87",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"
@ -616,9 +616,9 @@
"elements": [ "elements": [
{ {
"type": "node", "type": "node",
"name": "test", "name": "uint256",
"source_mapping": { "source_mapping": {
"start": 287, "start": 257,
"length": 4, "length": 4,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_relative": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
@ -626,7 +626,7 @@
"filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol", "filename_short": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14 12
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 13 "ending_column": 13
@ -727,10 +727,10 @@
} }
} }
], ],
"description": "Redundant expression \"test (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#14)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#3-18)\n", "description": "Redundant expression \"uint256 (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#12)\" inRedundantStatementsContract (tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#3-18)\n",
"markdown": "Redundant expression \"[test](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L14)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L3-L18)\n", "markdown": "Redundant expression \"[uint256](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L12)\" in[RedundantStatementsContract](tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L3-L18)\n",
"first_markdown_element": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L14", "first_markdown_element": "tests/detectors/redundant-statements/0.7.6/redundant_statements.sol#L12",
"id": "45bb5d6a69015db0e07e6d13107db089e1095da3cf0918f624db12181fac28a1", "id": "ffe6709dbcfc3342d28833aad5375135da8cc7369bf0649ab1796ff4eae14ca1",
"check": "redundant-statements", "check": "redundant-statements",
"impact": "Informational", "impact": "Informational",
"confidence": "High" "confidence": "High"

@ -4,25 +4,26 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "withdrawBalance", "name": "withdrawBalance_fixed_3",
"source_mapping": { "source_mapping": {
"start": 703, "start": 1839,
"length": 357, "length": 393,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 55,
26, 56,
27, 57,
28, 58,
29, 59,
30, 60,
31, 61,
32, 62,
33 63,
64
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -108,48 +109,49 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "withdrawBalance()" "signature": "withdrawBalance_fixed_3()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "(ret,mem) = msg.sender.call.value(userBalance[msg.sender])()", "name": "(ret,mem) = msg.sender.call.value(amount)()",
"source_mapping": { "source_mapping": {
"start": 882, "start": 2084,
"length": 81, "length": 64,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28 60
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 90 "ending_column": 73
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "withdrawBalance", "name": "withdrawBalance_fixed_3",
"source_mapping": { "source_mapping": {
"start": 703, "start": 1839,
"length": 357, "length": 393,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 55,
26, 56,
27, 57,
28, 58,
29, 59,
30, 60,
31, 61,
32, 62,
33 63,
64
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -235,7 +237,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "withdrawBalance()" "signature": "withdrawBalance_fixed_3()"
} }
} }
}, },
@ -245,43 +247,44 @@
}, },
{ {
"type": "node", "type": "node",
"name": "userBalance[msg.sender] = 0", "name": "userBalance[msg.sender] = amount",
"source_mapping": { "source_mapping": {
"start": 1026, "start": 2183,
"length": 27, "length": 32,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
32 62
], ],
"starting_column": 9, "starting_column": 13,
"ending_column": 36 "ending_column": 45
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "withdrawBalance", "name": "withdrawBalance_fixed_3",
"source_mapping": { "source_mapping": {
"start": 703, "start": 1839,
"length": 357, "length": 393,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 55,
26, 56,
27, 57,
28, 58,
29, 59,
30, 60,
31, 61,
32, 62,
33 63,
64
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -367,7 +370,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "withdrawBalance()" "signature": "withdrawBalance_fixed_3()"
} }
} }
}, },
@ -377,10 +380,10 @@
} }
} }
], ],
"description": "Reentrancy in Reentrancy.withdrawBalance() (tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#25-33):\n\tExternal calls:\n\t- (ret,mem) = msg.sender.call.value(userBalance[msg.sender])() (tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#28)\n\tState variables written after the call(s):\n\t- userBalance[msg.sender] = 0 (tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#32)\n", "description": "Reentrancy in Reentrancy.withdrawBalance_fixed_3() (tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#55-64):\n\tExternal calls:\n\t- (ret,mem) = msg.sender.call.value(amount)() (tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#60)\n\tState variables written after the call(s):\n\t- userBalance[msg.sender] = amount (tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#62)\n",
"markdown": "Reentrancy in [Reentrancy.withdrawBalance()](tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L25-L33):\n\tExternal calls:\n\t- [(ret,mem) = msg.sender.call.value(userBalance[msg.sender])()](tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L28)\n\tState variables written after the call(s):\n\t- [userBalance[msg.sender] = 0](tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L32)\n", "markdown": "Reentrancy in [Reentrancy.withdrawBalance_fixed_3()](tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L55-L64):\n\tExternal calls:\n\t- [(ret,mem) = msg.sender.call.value(amount)()](tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L60)\n\tState variables written after the call(s):\n\t- [userBalance[msg.sender] = amount](tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L62)\n",
"first_markdown_element": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L25-L33", "first_markdown_element": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L55-L64",
"id": "e2dcb62d8ffcc2636bab0fee518b4a79c760f2974c39950214749fc78bebc9de", "id": "b1d5762a3d9738215079d50da4bf0ecdc8eddd575b7f8686bdbfa3d101adf809",
"check": "reentrancy-eth", "check": "reentrancy-eth",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -389,26 +392,25 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "withdrawBalance_fixed_3", "name": "withdrawBalance",
"source_mapping": { "source_mapping": {
"start": 1839, "start": 703,
"length": 393, "length": 357,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
55, 25,
56, 26,
57, 27,
58, 28,
59, 29,
60, 30,
61, 31,
62, 32,
63, 33
64
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -494,49 +496,48 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "withdrawBalance_fixed_3()" "signature": "withdrawBalance()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "(ret,mem) = msg.sender.call.value(amount)()", "name": "(ret,mem) = msg.sender.call.value(userBalance[msg.sender])()",
"source_mapping": { "source_mapping": {
"start": 2084, "start": 882,
"length": 64, "length": 81,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
60 28
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 73 "ending_column": 90
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "withdrawBalance_fixed_3", "name": "withdrawBalance",
"source_mapping": { "source_mapping": {
"start": 1839, "start": 703,
"length": 393, "length": 357,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
55, 25,
56, 26,
57, 27,
58, 28,
59, 29,
60, 30,
61, 31,
62, 32,
63, 33
64
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -622,7 +623,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "withdrawBalance_fixed_3()" "signature": "withdrawBalance()"
} }
} }
}, },
@ -632,44 +633,43 @@
}, },
{ {
"type": "node", "type": "node",
"name": "userBalance[msg.sender] = amount", "name": "userBalance[msg.sender] = 0",
"source_mapping": { "source_mapping": {
"start": 2183, "start": 1026,
"length": 32, "length": 27,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
62 32
], ],
"starting_column": 13, "starting_column": 9,
"ending_column": 45 "ending_column": 36
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "withdrawBalance_fixed_3", "name": "withdrawBalance",
"source_mapping": { "source_mapping": {
"start": 1839, "start": 703,
"length": 393, "length": 357,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
55, 25,
56, 26,
57, 27,
58, 28,
59, 29,
60, 30,
61, 31,
62, 32,
63, 33
64
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -755,7 +755,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "withdrawBalance_fixed_3()" "signature": "withdrawBalance()"
} }
} }
}, },
@ -765,10 +765,10 @@
} }
} }
], ],
"description": "Reentrancy in Reentrancy.withdrawBalance_fixed_3() (tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#55-64):\n\tExternal calls:\n\t- (ret,mem) = msg.sender.call.value(amount)() (tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#60)\n\tState variables written after the call(s):\n\t- userBalance[msg.sender] = amount (tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#62)\n", "description": "Reentrancy in Reentrancy.withdrawBalance() (tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#25-33):\n\tExternal calls:\n\t- (ret,mem) = msg.sender.call.value(userBalance[msg.sender])() (tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#28)\n\tState variables written after the call(s):\n\t- userBalance[msg.sender] = 0 (tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#32)\n",
"markdown": "Reentrancy in [Reentrancy.withdrawBalance_fixed_3()](tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L55-L64):\n\tExternal calls:\n\t- [(ret,mem) = msg.sender.call.value(amount)()](tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L60)\n\tState variables written after the call(s):\n\t- [userBalance[msg.sender] = amount](tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L62)\n", "markdown": "Reentrancy in [Reentrancy.withdrawBalance()](tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L25-L33):\n\tExternal calls:\n\t- [(ret,mem) = msg.sender.call.value(userBalance[msg.sender])()](tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L28)\n\tState variables written after the call(s):\n\t- [userBalance[msg.sender] = 0](tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L32)\n",
"first_markdown_element": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L55-L64", "first_markdown_element": "tests/detectors/reentrancy-eth/0.5.16/reentrancy.sol#L25-L33",
"id": "b1d5762a3d9738215079d50da4bf0ecdc8eddd575b7f8686bdbfa3d101adf809", "id": "e2dcb62d8ffcc2636bab0fee518b4a79c760f2974c39950214749fc78bebc9de",
"check": "reentrancy-eth", "check": "reentrancy-eth",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -4,25 +4,26 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "withdrawBalance", "name": "withdrawBalance_fixed_3",
"source_mapping": { "source_mapping": {
"start": 703, "start": 1839,
"length": 357, "length": 393,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 55,
26, 56,
27, 57,
28, 58,
29, 59,
30, 60,
31, 61,
32, 62,
33 63,
64
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -108,48 +109,49 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "withdrawBalance()" "signature": "withdrawBalance_fixed_3()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "(ret,mem) = msg.sender.call{value: userBalance[msg.sender]}()", "name": "(ret,mem) = msg.sender.call{value: amount}()",
"source_mapping": { "source_mapping": {
"start": 882, "start": 2084,
"length": 81, "length": 64,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
28 60
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 90 "ending_column": 73
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "withdrawBalance", "name": "withdrawBalance_fixed_3",
"source_mapping": { "source_mapping": {
"start": 703, "start": 1839,
"length": 357, "length": 393,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 55,
26, 56,
27, 57,
28, 58,
29, 59,
30, 60,
31, 61,
32, 62,
33 63,
64
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -235,7 +237,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "withdrawBalance()" "signature": "withdrawBalance_fixed_3()"
} }
} }
}, },
@ -245,43 +247,44 @@
}, },
{ {
"type": "node", "type": "node",
"name": "userBalance[msg.sender] = 0", "name": "userBalance[msg.sender] = amount",
"source_mapping": { "source_mapping": {
"start": 1026, "start": 2183,
"length": 27, "length": 32,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
32 62
], ],
"starting_column": 9, "starting_column": 13,
"ending_column": 36 "ending_column": 45
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "withdrawBalance", "name": "withdrawBalance_fixed_3",
"source_mapping": { "source_mapping": {
"start": 703, "start": 1839,
"length": 357, "length": 393,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 55,
26, 56,
27, 57,
28, 58,
29, 59,
30, 60,
31, 61,
32, 62,
33 63,
64
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -367,7 +370,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "withdrawBalance()" "signature": "withdrawBalance_fixed_3()"
} }
} }
}, },
@ -377,10 +380,10 @@
} }
} }
], ],
"description": "Reentrancy in Reentrancy.withdrawBalance() (tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#25-33):\n\tExternal calls:\n\t- (ret,mem) = msg.sender.call{value: userBalance[msg.sender]}() (tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#28)\n\tState variables written after the call(s):\n\t- userBalance[msg.sender] = 0 (tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#32)\n", "description": "Reentrancy in Reentrancy.withdrawBalance_fixed_3() (tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#55-64):\n\tExternal calls:\n\t- (ret,mem) = msg.sender.call{value: amount}() (tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#60)\n\tState variables written after the call(s):\n\t- userBalance[msg.sender] = amount (tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#62)\n",
"markdown": "Reentrancy in [Reentrancy.withdrawBalance()](tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L25-L33):\n\tExternal calls:\n\t- [(ret,mem) = msg.sender.call{value: userBalance[msg.sender]}()](tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L28)\n\tState variables written after the call(s):\n\t- [userBalance[msg.sender] = 0](tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L32)\n", "markdown": "Reentrancy in [Reentrancy.withdrawBalance_fixed_3()](tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L55-L64):\n\tExternal calls:\n\t- [(ret,mem) = msg.sender.call{value: amount}()](tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L60)\n\tState variables written after the call(s):\n\t- [userBalance[msg.sender] = amount](tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L62)\n",
"first_markdown_element": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L25-L33", "first_markdown_element": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L55-L64",
"id": "df77aefe86b51d596b1dba22bde98d85390038724420e61fb18579fd90af852c", "id": "d68cc7cd493eca1fda517423f6f6ad0a5671d0bbea1d80ec0cb403ca66d5d4b8",
"check": "reentrancy-eth", "check": "reentrancy-eth",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"
@ -389,26 +392,25 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "withdrawBalance_fixed_3", "name": "withdrawBalance",
"source_mapping": { "source_mapping": {
"start": 1839, "start": 703,
"length": 393, "length": 357,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
55, 25,
56, 26,
57, 27,
58, 28,
59, 29,
60, 30,
61, 31,
62, 32,
63, 33
64
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -494,49 +496,48 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "withdrawBalance_fixed_3()" "signature": "withdrawBalance()"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "(ret,mem) = msg.sender.call{value: amount}()", "name": "(ret,mem) = msg.sender.call{value: userBalance[msg.sender]}()",
"source_mapping": { "source_mapping": {
"start": 2084, "start": 882,
"length": 64, "length": 81,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
60 28
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 73 "ending_column": 90
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "withdrawBalance_fixed_3", "name": "withdrawBalance",
"source_mapping": { "source_mapping": {
"start": 1839, "start": 703,
"length": 393, "length": 357,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
55, 25,
56, 26,
57, 27,
58, 28,
59, 29,
60, 30,
61, 31,
62, 32,
63, 33
64
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -622,7 +623,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "withdrawBalance_fixed_3()" "signature": "withdrawBalance()"
} }
} }
}, },
@ -632,44 +633,43 @@
}, },
{ {
"type": "node", "type": "node",
"name": "userBalance[msg.sender] = amount", "name": "userBalance[msg.sender] = 0",
"source_mapping": { "source_mapping": {
"start": 2183, "start": 1026,
"length": 32, "length": 27,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
62 32
], ],
"starting_column": 13, "starting_column": 9,
"ending_column": 45 "ending_column": 36
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "withdrawBalance_fixed_3", "name": "withdrawBalance",
"source_mapping": { "source_mapping": {
"start": 1839, "start": 703,
"length": 393, "length": 357,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_relative": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol", "filename_short": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
55, 25,
56, 26,
57, 27,
58, 28,
59, 29,
60, 30,
61, 31,
62, 32,
63, 33
64
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -755,7 +755,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "withdrawBalance_fixed_3()" "signature": "withdrawBalance()"
} }
} }
}, },
@ -765,10 +765,10 @@
} }
} }
], ],
"description": "Reentrancy in Reentrancy.withdrawBalance_fixed_3() (tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#55-64):\n\tExternal calls:\n\t- (ret,mem) = msg.sender.call{value: amount}() (tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#60)\n\tState variables written after the call(s):\n\t- userBalance[msg.sender] = amount (tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#62)\n", "description": "Reentrancy in Reentrancy.withdrawBalance() (tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#25-33):\n\tExternal calls:\n\t- (ret,mem) = msg.sender.call{value: userBalance[msg.sender]}() (tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#28)\n\tState variables written after the call(s):\n\t- userBalance[msg.sender] = 0 (tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#32)\n",
"markdown": "Reentrancy in [Reentrancy.withdrawBalance_fixed_3()](tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L55-L64):\n\tExternal calls:\n\t- [(ret,mem) = msg.sender.call{value: amount}()](tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L60)\n\tState variables written after the call(s):\n\t- [userBalance[msg.sender] = amount](tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L62)\n", "markdown": "Reentrancy in [Reentrancy.withdrawBalance()](tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L25-L33):\n\tExternal calls:\n\t- [(ret,mem) = msg.sender.call{value: userBalance[msg.sender]}()](tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L28)\n\tState variables written after the call(s):\n\t- [userBalance[msg.sender] = 0](tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L32)\n",
"first_markdown_element": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L55-L64", "first_markdown_element": "tests/detectors/reentrancy-eth/0.7.6/reentrancy.sol#L25-L33",
"id": "d68cc7cd493eca1fda517423f6f6ad0a5671d0bbea1d80ec0cb403ca66d5d4b8", "id": "df77aefe86b51d596b1dba22bde98d85390038724420e61fb18579fd90af852c",
"check": "reentrancy-eth", "check": "reentrancy-eth",
"impact": "High", "impact": "High",
"confidence": "Medium" "confidence": "Medium"

@ -4,24 +4,22 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 336, "start": 530,
"length": 188, "length": 161,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16, 25,
17, 26,
18, 27,
19, 28,
20, 29,
21, 30
22,
23
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -83,14 +81,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad1(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "(success) = msg.sender.call()", "name": "(success) = msg.sender.call()",
"source_mapping": { "source_mapping": {
"start": 397, "start": 605,
"length": 37, "length": 37,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
@ -98,7 +96,7 @@
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
18 27
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 46 "ending_column": 46
@ -106,24 +104,22 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 336, "start": 530,
"length": 188, "length": 161,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16, 25,
17, 26,
18, 27,
19, 28,
20, 29,
21, 30
22,
23
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -185,7 +181,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad1(address)"
} }
} }
}, },
@ -195,42 +191,40 @@
}, },
{ {
"type": "node", "type": "node",
"name": "notCalled = false", "name": "bad0()",
"source_mapping": { "source_mapping": {
"start": 500, "start": 678,
"length": 17, "length": 6,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
22 29
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 26 "ending_column": 15
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 336, "start": 530,
"length": 188, "length": 161,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
16, 25,
17, 26,
18, 27,
19, 28,
20, 29,
21, 30
22,
23
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -292,113 +286,19 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad1(address)"
} }
} }
}, },
"additional_fields": { "additional_fields": {
"underlying_type": "variables_written", "underlying_type": "external_calls"
"variable_name": "notCalled"
}
}
],
"description": "Reentrancy in ReentrancyWrite.bad0() (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#16-23):\n\tExternal calls:\n\t- (success) = msg.sender.call() (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#18)\n\tState variables written after the call(s):\n\t- notCalled = false (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#22)\n",
"markdown": "Reentrancy in [ReentrancyWrite.bad0()](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L16-L23):\n\tExternal calls:\n\t- [(success) = msg.sender.call()](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L18)\n\tState variables written after the call(s):\n\t- [notCalled = false](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L22)\n",
"first_markdown_element": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L16-L23",
"id": "c9ba81d76d46579f9e78ac96b1aae43b71f2d4a96d4c47b2fab9831bf0f15a8f",
"check": "reentrancy-no-eth",
"impact": "Medium",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad1",
"source_mapping": {
"start": 530,
"length": 161,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false,
"lines": [
25,
26,
27,
28,
29,
30
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyWrite",
"source_mapping": {
"start": 28,
"length": 859,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.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
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad1(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "(success) = msg.sender.call()", "name": "(success) = msg.sender.call()",
"source_mapping": { "source_mapping": {
"start": 605, "start": 397,
"length": 37, "length": 37,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
@ -406,7 +306,7 @@
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
27 18
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 46 "ending_column": 46
@ -414,22 +314,24 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 530, "start": 336,
"length": 161, "length": 188,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
25, 16,
26, 17,
27, 18,
28, 19,
29, 20,
30 21,
22,
23
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -491,12 +393,12 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(address)" "signature": "bad0()"
} }
} }
}, },
"additional_fields": { "additional_fields": {
"underlying_type": "external_calls" "underlying_type": "external_calls_sending_eth"
} }
}, },
{ {
@ -601,25 +503,26 @@
} }
}, },
"additional_fields": { "additional_fields": {
"underlying_type": "external_calls" "underlying_type": "variables_written",
"variable_name": "notCalled"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "(success) = msg.sender.call()", "name": "notCalled = false",
"source_mapping": { "source_mapping": {
"start": 397, "start": 500,
"length": 37, "length": 17,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
18 22
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 46 "ending_column": 26
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -708,45 +611,143 @@
} }
}, },
"additional_fields": { "additional_fields": {
"underlying_type": "external_calls_sending_eth" "underlying_type": "variables_written",
"variable_name": "notCalled"
} }
}, }
],
"description": "Reentrancy in ReentrancyWrite.bad1(address) (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#25-30):\n\tExternal calls:\n\t- (success) = msg.sender.call() (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#27)\n\t- bad0() (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#29)\n\t\t- (success) = msg.sender.call() (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#18)\n\tState variables written after the call(s):\n\t- bad0() (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#29)\n\t\t- notCalled = false (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#22)\n",
"markdown": "Reentrancy in [ReentrancyWrite.bad1(address)](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L25-L30):\n\tExternal calls:\n\t- [(success) = msg.sender.call()](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L27)\n\t- [bad0()](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L29)\n\t\t- [(success) = msg.sender.call()](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L18)\n\tState variables written after the call(s):\n\t- [bad0()](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L29)\n\t\t- [notCalled = false](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L22)\n",
"first_markdown_element": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L25-L30",
"id": "9fbfafd0d47ce4f4ead524570f382093c186c4e9e5e96ce0067fce3ffb6dc74a",
"check": "reentrancy-no-eth",
"impact": "Medium",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "node", "type": "function",
"name": "bad0()", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 678, "start": 336,
"length": 6, "length": 188,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
29 16,
17,
18,
19,
20,
21,
22,
23
], ],
"starting_column": 9, "starting_column": 5,
"ending_column": 15 "ending_column": 6
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "contract",
"name": "bad1", "name": "ReentrancyWrite",
"source_mapping": { "source_mapping": {
"start": 530, "start": 28,
"length": 161, "length": 859,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13,
14,
15,
16,
17,
18,
19,
20,
21,
22,
23,
24,
25, 25,
26, 26,
27, 27,
28, 28,
29, 29,
30 30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad0()"
}
},
{
"type": "node",
"name": "(success) = msg.sender.call()",
"source_mapping": {
"start": 397,
"length": 37,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false,
"lines": [
18
],
"starting_column": 9,
"ending_column": 46
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad0",
"source_mapping": {
"start": 336,
"length": 188,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol",
"is_dependency": false,
"lines": [
16,
17,
18,
19,
20,
21,
22,
23
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -808,13 +809,12 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(address)" "signature": "bad0()"
} }
} }
}, },
"additional_fields": { "additional_fields": {
"underlying_type": "variables_written", "underlying_type": "external_calls"
"variable_name": "notCalled"
} }
}, },
{ {
@ -926,10 +926,10 @@
} }
} }
], ],
"description": "Reentrancy in ReentrancyWrite.bad1(address) (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#25-30):\n\tExternal calls:\n\t- (success) = msg.sender.call() (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#27)\n\t- bad0() (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#29)\n\t\t- (success) = msg.sender.call() (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#18)\n\tState variables written after the call(s):\n\t- bad0() (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#29)\n\t\t- notCalled = false (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#22)\n", "description": "Reentrancy in ReentrancyWrite.bad0() (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#16-23):\n\tExternal calls:\n\t- (success) = msg.sender.call() (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#18)\n\tState variables written after the call(s):\n\t- notCalled = false (tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#22)\n",
"markdown": "Reentrancy in [ReentrancyWrite.bad1(address)](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L25-L30):\n\tExternal calls:\n\t- [(success) = msg.sender.call()](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L27)\n\t- [bad0()](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L29)\n\t\t- [(success) = msg.sender.call()](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L18)\n\tState variables written after the call(s):\n\t- [bad0()](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L29)\n\t\t- [notCalled = false](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L22)\n", "markdown": "Reentrancy in [ReentrancyWrite.bad0()](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L16-L23):\n\tExternal calls:\n\t- [(success) = msg.sender.call()](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L18)\n\tState variables written after the call(s):\n\t- [notCalled = false](tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L22)\n",
"first_markdown_element": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L25-L30", "first_markdown_element": "tests/detectors/reentrancy-no-eth/0.5.16/reentrancy-write.sol#L16-L23",
"id": "9fbfafd0d47ce4f4ead524570f382093c186c4e9e5e96ce0067fce3ffb6dc74a", "id": "c9ba81d76d46579f9e78ac96b1aae43b71f2d4a96d4c47b2fab9831bf0f15a8f",
"check": "reentrancy-no-eth", "check": "reentrancy-no-eth",
"impact": "Medium", "impact": "Medium",
"confidence": "Medium" "confidence": "Medium"

@ -4,24 +4,22 @@
"elements": [ "elements": [
{ {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 383, "start": 577,
"length": 188, "length": 161,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 29,
21, 30,
22, 31,
23, 32,
24, 33,
25, 34
26,
27
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -83,14 +81,14 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad1(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "(success) = msg.sender.call()", "name": "(success) = msg.sender.call()",
"source_mapping": { "source_mapping": {
"start": 444, "start": 652,
"length": 37, "length": 37,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
@ -98,7 +96,7 @@
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
22 31
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 46 "ending_column": 46
@ -106,24 +104,22 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 383, "start": 577,
"length": 188, "length": 161,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 29,
21, 30,
22, 31,
23, 32,
24, 33,
25, 34
26,
27
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -185,7 +181,7 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad1(address)"
} }
} }
}, },
@ -195,42 +191,40 @@
}, },
{ {
"type": "node", "type": "node",
"name": "notCalled = false", "name": "bad0()",
"source_mapping": { "source_mapping": {
"start": 547, "start": 725,
"length": 17, "length": 6,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26 33
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 26 "ending_column": 15
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad0", "name": "bad1",
"source_mapping": { "source_mapping": {
"start": 383, "start": 577,
"length": 188, "length": 161,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 29,
21, 30,
22, 31,
23, 32,
24, 33,
25, 34
26,
27
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -292,113 +286,19 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad0()" "signature": "bad1(address)"
} }
} }
}, },
"additional_fields": { "additional_fields": {
"underlying_type": "variables_written", "underlying_type": "external_calls"
"variable_name": "notCalled"
}
}
],
"description": "Reentrancy in ReentrancyWrite.bad0() (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#20-27):\n\tExternal calls:\n\t- (success) = msg.sender.call() (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#22)\n\tState variables written after the call(s):\n\t- notCalled = false (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#26)\n",
"markdown": "Reentrancy in [ReentrancyWrite.bad0()](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L20-L27):\n\tExternal calls:\n\t- [(success) = msg.sender.call()](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L22)\n\tState variables written after the call(s):\n\t- [notCalled = false](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L26)\n",
"first_markdown_element": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L20-L27",
"id": "ef995e89d54c7b577af2ca26540e01da65ac0e2466d6d7a58e4d11e9211b12a4",
"check": "reentrancy-no-eth",
"impact": "Medium",
"confidence": "Medium"
},
{
"elements": [
{
"type": "function",
"name": "bad1",
"source_mapping": {
"start": 577,
"length": 161,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false,
"lines": [
29,
30,
31,
32,
33,
34
],
"starting_column": 5,
"ending_column": 6
},
"type_specific_fields": {
"parent": {
"type": "contract",
"name": "ReentrancyWrite",
"source_mapping": {
"start": 82,
"length": 852,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false,
"lines": [
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
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad1(address)"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "(success) = msg.sender.call()", "name": "(success) = msg.sender.call()",
"source_mapping": { "source_mapping": {
"start": 652, "start": 444,
"length": 37, "length": 37,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
@ -406,7 +306,7 @@
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
31 22
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 46 "ending_column": 46
@ -414,22 +314,24 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "function",
"name": "bad1", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 577, "start": 383,
"length": 161, "length": 188,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
29, 20,
30, 21,
31, 22,
32, 23,
33, 24,
34 25,
26,
27
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -491,12 +393,12 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(address)" "signature": "bad0()"
} }
} }
}, },
"additional_fields": { "additional_fields": {
"underlying_type": "external_calls" "underlying_type": "external_calls_sending_eth"
} }
}, },
{ {
@ -601,25 +503,26 @@
} }
}, },
"additional_fields": { "additional_fields": {
"underlying_type": "external_calls" "underlying_type": "variables_written",
"variable_name": "notCalled"
} }
}, },
{ {
"type": "node", "type": "node",
"name": "(success) = msg.sender.call()", "name": "notCalled = false",
"source_mapping": { "source_mapping": {
"start": 444, "start": 547,
"length": 37, "length": 17,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
22 26
], ],
"starting_column": 9, "starting_column": 9,
"ending_column": 46 "ending_column": 26
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
@ -708,45 +611,143 @@
} }
}, },
"additional_fields": { "additional_fields": {
"underlying_type": "external_calls_sending_eth" "underlying_type": "variables_written",
"variable_name": "notCalled"
} }
}, }
],
"description": "Reentrancy in ReentrancyWrite.bad1(address) (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#29-34):\n\tExternal calls:\n\t- (success) = msg.sender.call() (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#31)\n\t- bad0() (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#33)\n\t\t- (success) = msg.sender.call() (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#22)\n\tState variables written after the call(s):\n\t- bad0() (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#33)\n\t\t- notCalled = false (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#26)\n",
"markdown": "Reentrancy in [ReentrancyWrite.bad1(address)](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L29-L34):\n\tExternal calls:\n\t- [(success) = msg.sender.call()](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L31)\n\t- [bad0()](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L33)\n\t\t- [(success) = msg.sender.call()](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L22)\n\tState variables written after the call(s):\n\t- [bad0()](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L33)\n\t\t- [notCalled = false](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L26)\n",
"first_markdown_element": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L29-L34",
"id": "11273f8e5ccbb848ea0de9b7c15e3fb66deb7c061265f88b8aa7646eed935c0e",
"check": "reentrancy-no-eth",
"impact": "Medium",
"confidence": "Medium"
},
{
"elements": [
{ {
"type": "node", "type": "function",
"name": "bad0()", "name": "bad0",
"source_mapping": { "source_mapping": {
"start": 725, "start": 383,
"length": 6, "length": 188,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
33 20,
21,
22,
23,
24,
25,
26,
27
], ],
"starting_column": 9, "starting_column": 5,
"ending_column": 15 "ending_column": 6
}, },
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "function", "type": "contract",
"name": "bad1", "name": "ReentrancyWrite",
"source_mapping": { "source_mapping": {
"start": 577, "start": 82,
"length": 161, "length": 852,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol", "filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
7,
8,
9,
10,
11,
12,
13,
14,
15,
16,
17,
18,
19,
20,
21,
22,
23,
24,
25,
26,
27,
28,
29, 29,
30, 30,
31, 31,
32, 32,
33, 33,
34 34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45
],
"starting_column": 1,
"ending_column": 2
}
},
"signature": "bad0()"
}
},
{
"type": "node",
"name": "(success) = msg.sender.call()",
"source_mapping": {
"start": 444,
"length": 37,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false,
"lines": [
22
],
"starting_column": 9,
"ending_column": 46
},
"type_specific_fields": {
"parent": {
"type": "function",
"name": "bad0",
"source_mapping": {
"start": 383,
"length": 188,
"filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol",
"is_dependency": false,
"lines": [
20,
21,
22,
23,
24,
25,
26,
27
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -808,13 +809,12 @@
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "bad1(address)" "signature": "bad0()"
} }
} }
}, },
"additional_fields": { "additional_fields": {
"underlying_type": "variables_written", "underlying_type": "external_calls"
"variable_name": "notCalled"
} }
}, },
{ {
@ -926,10 +926,10 @@
} }
} }
], ],
"description": "Reentrancy in ReentrancyWrite.bad1(address) (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#29-34):\n\tExternal calls:\n\t- (success) = msg.sender.call() (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#31)\n\t- bad0() (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#33)\n\t\t- (success) = msg.sender.call() (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#22)\n\tState variables written after the call(s):\n\t- bad0() (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#33)\n\t\t- notCalled = false (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#26)\n", "description": "Reentrancy in ReentrancyWrite.bad0() (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#20-27):\n\tExternal calls:\n\t- (success) = msg.sender.call() (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#22)\n\tState variables written after the call(s):\n\t- notCalled = false (tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#26)\n",
"markdown": "Reentrancy in [ReentrancyWrite.bad1(address)](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L29-L34):\n\tExternal calls:\n\t- [(success) = msg.sender.call()](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L31)\n\t- [bad0()](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L33)\n\t\t- [(success) = msg.sender.call()](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L22)\n\tState variables written after the call(s):\n\t- [bad0()](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L33)\n\t\t- [notCalled = false](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L26)\n", "markdown": "Reentrancy in [ReentrancyWrite.bad0()](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L20-L27):\n\tExternal calls:\n\t- [(success) = msg.sender.call()](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L22)\n\tState variables written after the call(s):\n\t- [notCalled = false](tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L26)\n",
"first_markdown_element": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L29-L34", "first_markdown_element": "tests/detectors/reentrancy-no-eth/0.7.6/reentrancy-write.sol#L20-L27",
"id": "11273f8e5ccbb848ea0de9b7c15e3fb66deb7c061265f88b8aa7646eed935c0e", "id": "ef995e89d54c7b577af2ca26540e01da65ac0e2466d6d7a58e4d11e9211b12a4",
"check": "reentrancy-no-eth", "check": "reentrancy-no-eth",
"impact": "Medium", "impact": "Medium",
"confidence": "Medium" "confidence": "Medium"

@ -4,21 +4,21 @@
"elements": [ "elements": [
{ {
"type": "contract", "type": "contract",
"name": "C", "name": "E",
"source_mapping": { "source_mapping": {
"start": 155, "start": 295,
"length": 65, "length": 77,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 26,
15, 27,
16, 28,
17, 29,
18 30
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -26,19 +26,19 @@
}, },
{ {
"type": "function", "type": "function",
"name": "A", "name": "C",
"source_mapping": { "source_mapping": {
"start": 34, "start": 176,
"length": 50, "length": 42,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
3, 15,
4, 16,
5 17
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -46,47 +46,46 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "A", "name": "C",
"source_mapping": { "source_mapping": {
"start": 0, "start": 155,
"length": 86, "length": 65,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
1, 14,
2, 15,
3, 16,
4, 17,
5, 18
6
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "A(uint256)" "signature": "C(uint256)"
} }
}, },
{ {
"type": "contract", "type": "contract",
"name": "C", "name": "E",
"source_mapping": { "source_mapping": {
"start": 155, "start": 295,
"length": 65, "length": 77,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 26,
15, 27,
16, 28,
17, 29,
18 30
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -94,31 +93,31 @@
}, },
{ {
"type": "contract", "type": "contract",
"name": "B", "name": "D",
"source_mapping": { "source_mapping": {
"start": 88, "start": 222,
"length": 65, "length": 71,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8, 20,
9, 21,
10, 22,
11, 23,
12 24
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
} }
], ],
"description": "C (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#14-18) gives base constructor A.A(uint256) (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#3-5) arguments more than once in inheritance hierarchy:\n\t- From C (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#14-18) constructor definition\n\t- From B (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#8-12) constructor definition\n", "description": "E (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#26-30) gives base constructor C.C(uint256) (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#15-17) arguments more than once in inheritance hierarchy:\n\t- From E (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#26-30) constructor definition\n\t- From D (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#20-24) constructor definition\n",
"markdown": "[C](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L14-L18) gives base constructor [A.A(uint256)](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L3-L5) arguments more than once in inheritance hierarchy:\n\t- From [C](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L14-L18) constructor definition\n\t- From [B](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L8-L12) constructor definition\n", "markdown": "[E](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30) gives base constructor [C.C(uint256)](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L15-L17) arguments more than once in inheritance hierarchy:\n\t- From [E](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30) constructor definition\n\t- From [D](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L20-L24) constructor definition\n",
"first_markdown_element": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L14-L18", "first_markdown_element": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30",
"id": "d2847fcb309e0ee45dfb303bf749123bbebee692a080ae6a718a76ef785ae8d2", "id": "085dceba8f0b37580e72952eafe1368bf0d09f10c2f44c0b6ff53ad7e72f92b1",
"check": "reused-constructor", "check": "reused-constructor",
"impact": "Medium", "impact": "Medium",
"confidence": "Medium" "confidence": "Medium"
@ -127,21 +126,21 @@
"elements": [ "elements": [
{ {
"type": "contract", "type": "contract",
"name": "D", "name": "E",
"source_mapping": { "source_mapping": {
"start": 222, "start": 295,
"length": 71, "length": 77,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 26,
21, 27,
22, 28,
23, 29,
24 30
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -238,10 +237,10 @@
} }
} }
], ],
"description": "D (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#20-24) gives base constructor A.A(uint256) (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#3-5) arguments more than once in inheritance hierarchy:\n\t- From C (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#14-18) constructor definition\n\t- From B (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#8-12) constructor definition\n", "description": "E (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#26-30) gives base constructor A.A(uint256) (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#3-5) arguments more than once in inheritance hierarchy:\n\t- From C (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#14-18) constructor definition\n\t- From B (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#8-12) constructor definition\n",
"markdown": "[D](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L20-L24) gives base constructor [A.A(uint256)](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L3-L5) arguments more than once in inheritance hierarchy:\n\t- From [C](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L14-L18) constructor definition\n\t- From [B](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L8-L12) constructor definition\n", "markdown": "[E](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30) gives base constructor [A.A(uint256)](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L3-L5) arguments more than once in inheritance hierarchy:\n\t- From [C](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L14-L18) constructor definition\n\t- From [B](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L8-L12) constructor definition\n",
"first_markdown_element": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L20-L24", "first_markdown_element": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30",
"id": "7436d3215ee6260f9a4b2f4697fa242225ad3f10e30bfbd162679a5e3fa48f10", "id": "14d6bffb3f1849cfebb7156cb797315fd01ac83911a1261650f702792f4db830",
"check": "reused-constructor", "check": "reused-constructor",
"impact": "Medium", "impact": "Medium",
"confidence": "Medium" "confidence": "Medium"
@ -250,41 +249,42 @@
"elements": [ "elements": [
{ {
"type": "contract", "type": "contract",
"name": "E", "name": "F",
"source_mapping": { "source_mapping": {
"start": 295, "start": 375,
"length": 77, "length": 57,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 33,
27, 34,
28, 35,
29, 36,
30 37,
38
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 0
} }
}, },
{ {
"type": "function", "type": "function",
"name": "B", "name": "A",
"source_mapping": { "source_mapping": {
"start": 109, "start": 34,
"length": 42, "length": 50,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
9, 3,
10, 4,
11 5
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -292,78 +292,80 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "B", "name": "A",
"source_mapping": { "source_mapping": {
"start": 88, "start": 0,
"length": 65, "length": 86,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8, 1,
9, 2,
10, 3,
11, 4,
12 5,
6
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "B(uint256)" "signature": "A(uint256)"
} }
}, },
{ {
"type": "contract", "type": "contract",
"name": "E", "name": "F",
"source_mapping": { "source_mapping": {
"start": 295, "start": 375,
"length": 77, "length": 57,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 33,
27, 34,
28, 35,
29, 36,
30 37,
38
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 0
} }
}, },
{ {
"type": "contract", "type": "contract",
"name": "D", "name": "B",
"source_mapping": { "source_mapping": {
"start": 222, "start": 88,
"length": 71, "length": 65,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 8,
21, 9,
22, 10,
23, 11,
24 12
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
} }
], ],
"description": "E (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#26-30) gives base constructor B.B(uint256) (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#9-11) arguments more than once in inheritance hierarchy:\n\t- From E (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#26-30) constructor definition\n\t- From D (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#20-24) constructor definition\n", "description": "F (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#33-38) gives base constructor A.A(uint256) (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#3-5) arguments more than once in inheritance hierarchy:\n\t- From F (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#33-38) constructor definition\n\t- From B (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#8-12) constructor definition\n",
"markdown": "[E](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30) gives base constructor [B.B(uint256)](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L9-L11) arguments more than once in inheritance hierarchy:\n\t- From [E](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30) constructor definition\n\t- From [D](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L20-L24) constructor definition\n", "markdown": "[F](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L33-L38) gives base constructor [A.A(uint256)](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L3-L5) arguments more than once in inheritance hierarchy:\n\t- From [F](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L33-L38) constructor definition\n\t- From [B](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L8-L12) constructor definition\n",
"first_markdown_element": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30", "first_markdown_element": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L33-L38",
"id": "e79d62c434ba85788dd5087e4994bb136be6b9e8a55e8057b0e30c9b0436abdc", "id": "71e08d0e5c44bbc2671e014018a6333bd92db7380a85732bf2d17aa5500f6434",
"check": "reused-constructor", "check": "reused-constructor",
"impact": "Medium", "impact": "Medium",
"confidence": "Medium" "confidence": "Medium"
@ -372,21 +374,21 @@
"elements": [ "elements": [
{ {
"type": "contract", "type": "contract",
"name": "E", "name": "D",
"source_mapping": { "source_mapping": {
"start": 295, "start": 222,
"length": 77, "length": 71,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 20,
27, 21,
28, 22,
29, 23,
30 24
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -394,19 +396,19 @@
}, },
{ {
"type": "function", "type": "function",
"name": "C", "name": "A",
"source_mapping": { "source_mapping": {
"start": 176, "start": 34,
"length": 42, "length": 50,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
15, 3,
16, 4,
17 5
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -414,46 +416,47 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "C", "name": "A",
"source_mapping": { "source_mapping": {
"start": 155, "start": 0,
"length": 65, "length": 86,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
14, 1,
15, 2,
16, 3,
17, 4,
18 5,
6
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "C(uint256)" "signature": "A(uint256)"
} }
}, },
{ {
"type": "contract", "type": "contract",
"name": "E", "name": "C",
"source_mapping": { "source_mapping": {
"start": 295, "start": 155,
"length": 77, "length": 65,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 14,
27, 15,
28, 16,
29, 17,
30 18
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -461,31 +464,31 @@
}, },
{ {
"type": "contract", "type": "contract",
"name": "D", "name": "B",
"source_mapping": { "source_mapping": {
"start": 222, "start": 88,
"length": 71, "length": 65,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
20, 8,
21, 9,
22, 10,
23, 11,
24 12
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
} }
], ],
"description": "E (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#26-30) gives base constructor C.C(uint256) (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#15-17) arguments more than once in inheritance hierarchy:\n\t- From E (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#26-30) constructor definition\n\t- From D (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#20-24) constructor definition\n", "description": "D (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#20-24) gives base constructor A.A(uint256) (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#3-5) arguments more than once in inheritance hierarchy:\n\t- From C (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#14-18) constructor definition\n\t- From B (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#8-12) constructor definition\n",
"markdown": "[E](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30) gives base constructor [C.C(uint256)](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L15-L17) arguments more than once in inheritance hierarchy:\n\t- From [E](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30) constructor definition\n\t- From [D](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L20-L24) constructor definition\n", "markdown": "[D](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L20-L24) gives base constructor [A.A(uint256)](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L3-L5) arguments more than once in inheritance hierarchy:\n\t- From [C](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L14-L18) constructor definition\n\t- From [B](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L8-L12) constructor definition\n",
"first_markdown_element": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30", "first_markdown_element": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L20-L24",
"id": "085dceba8f0b37580e72952eafe1368bf0d09f10c2f44c0b6ff53ad7e72f92b1", "id": "7436d3215ee6260f9a4b2f4697fa242225ad3f10e30bfbd162679a5e3fa48f10",
"check": "reused-constructor", "check": "reused-constructor",
"impact": "Medium", "impact": "Medium",
"confidence": "Medium" "confidence": "Medium"
@ -494,21 +497,21 @@
"elements": [ "elements": [
{ {
"type": "contract", "type": "contract",
"name": "E", "name": "C",
"source_mapping": { "source_mapping": {
"start": 295, "start": 155,
"length": 77, "length": 65,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
26, 14,
27, 15,
28, 16,
29, 17,
30 18
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
@ -605,10 +608,10 @@
} }
} }
], ],
"description": "E (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#26-30) gives base constructor A.A(uint256) (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#3-5) arguments more than once in inheritance hierarchy:\n\t- From C (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#14-18) constructor definition\n\t- From B (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#8-12) constructor definition\n", "description": "C (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#14-18) gives base constructor A.A(uint256) (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#3-5) arguments more than once in inheritance hierarchy:\n\t- From C (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#14-18) constructor definition\n\t- From B (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#8-12) constructor definition\n",
"markdown": "[E](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30) gives base constructor [A.A(uint256)](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L3-L5) arguments more than once in inheritance hierarchy:\n\t- From [C](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L14-L18) constructor definition\n\t- From [B](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L8-L12) constructor definition\n", "markdown": "[C](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L14-L18) gives base constructor [A.A(uint256)](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L3-L5) arguments more than once in inheritance hierarchy:\n\t- From [C](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L14-L18) constructor definition\n\t- From [B](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L8-L12) constructor definition\n",
"first_markdown_element": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30", "first_markdown_element": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L14-L18",
"id": "14d6bffb3f1849cfebb7156cb797315fd01ac83911a1261650f702792f4db830", "id": "d2847fcb309e0ee45dfb303bf749123bbebee692a080ae6a718a76ef785ae8d2",
"check": "reused-constructor", "check": "reused-constructor",
"impact": "Medium", "impact": "Medium",
"confidence": "Medium" "confidence": "Medium"
@ -617,42 +620,41 @@
"elements": [ "elements": [
{ {
"type": "contract", "type": "contract",
"name": "F", "name": "E",
"source_mapping": { "source_mapping": {
"start": 375, "start": 295,
"length": 57, "length": 77,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
33, 26,
34, 27,
35, 28,
36, 29,
37, 30
38
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 0 "ending_column": 2
} }
}, },
{ {
"type": "function", "type": "function",
"name": "A", "name": "B",
"source_mapping": { "source_mapping": {
"start": 34, "start": 109,
"length": 50, "length": 42,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
3, 9,
4, 10,
5 11
], ],
"starting_column": 5, "starting_column": 5,
"ending_column": 6 "ending_column": 6
@ -660,80 +662,78 @@
"type_specific_fields": { "type_specific_fields": {
"parent": { "parent": {
"type": "contract", "type": "contract",
"name": "A", "name": "B",
"source_mapping": { "source_mapping": {
"start": 0, "start": 88,
"length": 86, "length": 65,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
1, 8,
2, 9,
3, 10,
4, 11,
5, 12
6
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
}, },
"signature": "A(uint256)" "signature": "B(uint256)"
} }
}, },
{ {
"type": "contract", "type": "contract",
"name": "F", "name": "E",
"source_mapping": { "source_mapping": {
"start": 375, "start": 295,
"length": 57, "length": 77,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
33, 26,
34, 27,
35, 28,
36, 29,
37, 30
38
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 0 "ending_column": 2
} }
}, },
{ {
"type": "contract", "type": "contract",
"name": "B", "name": "D",
"source_mapping": { "source_mapping": {
"start": 88, "start": 222,
"length": 65, "length": 71,
"filename_used": "/GENERIC_PATH", "filename_used": "/GENERIC_PATH",
"filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_relative": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"filename_absolute": "/GENERIC_PATH", "filename_absolute": "/GENERIC_PATH",
"filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol", "filename_short": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol",
"is_dependency": false, "is_dependency": false,
"lines": [ "lines": [
8, 20,
9, 21,
10, 22,
11, 23,
12 24
], ],
"starting_column": 1, "starting_column": 1,
"ending_column": 2 "ending_column": 2
} }
} }
], ],
"description": "F (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#33-38) gives base constructor A.A(uint256) (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#3-5) arguments more than once in inheritance hierarchy:\n\t- From F (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#33-38) constructor definition\n\t- From B (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#8-12) constructor definition\n", "description": "E (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#26-30) gives base constructor B.B(uint256) (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#9-11) arguments more than once in inheritance hierarchy:\n\t- From E (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#26-30) constructor definition\n\t- From D (tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#20-24) constructor definition\n",
"markdown": "[F](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L33-L38) gives base constructor [A.A(uint256)](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L3-L5) arguments more than once in inheritance hierarchy:\n\t- From [F](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L33-L38) constructor definition\n\t- From [B](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L8-L12) constructor definition\n", "markdown": "[E](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30) gives base constructor [B.B(uint256)](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L9-L11) arguments more than once in inheritance hierarchy:\n\t- From [E](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30) constructor definition\n\t- From [D](tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L20-L24) constructor definition\n",
"first_markdown_element": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L33-L38", "first_markdown_element": "tests/detectors/reused-constructor/0.4.21/reused_base_constructor.sol#L26-L30",
"id": "71e08d0e5c44bbc2671e014018a6333bd92db7380a85732bf2d17aa5500f6434", "id": "e79d62c434ba85788dd5087e4994bb136be6b9e8a55e8057b0e30c9b0436abdc",
"check": "reused-constructor", "check": "reused-constructor",
"impact": "Medium", "impact": "Medium",
"confidence": "Medium" "confidence": "Medium"

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save