Class IncompleteOperationError


  • public class IncompleteOperationError
    extends AbstractError

    This class defines-IncompleteOperationError:

    Found when the usage of an object may be incomplete. If there are multiple paths, and at least one path introduces an incomplete operation, the analysis indicates that there is a potential path with missing calls.

    For example a Cipher object may be initialized but never been used for encryption or decryption, this may render the code dead. This error heavily depends on the computed call graph (CHA by default).

    • Constructor Detail

      • IncompleteOperationError

        public IncompleteOperationError​(IAnalysisSeed seed,
                                        boomerang.scene.Statement errorStmt,
                                        CrySLRule rule,
                                        Collection<CrySLMethod> expectedMethodsToBeCalled)
        Create an IncompleteOperationError, if there is only one dataflow path, where the incomplete operation occurs.
        Parameters:
        seed - the seed for the incomplete operation
        errorStmt - the statement of the last usage of the seed
        rule - the CrySL rule for the seed
        expectedMethodsToBeCalled - the methods that are expected to be called
      • IncompleteOperationError

        public IncompleteOperationError​(IAnalysisSeed seed,
                                        boomerang.scene.Statement errorStmt,
                                        CrySLRule rule,
                                        Collection<CrySLMethod> expectedMethodsToBeCalled,
                                        boolean multiplePaths)
        Create an IncompleteOperationError, if there is at least one dataflow path, where an incomplete operation occurs.
        Parameters:
        seed - the seed for the incomplete operation
        errorStmt - the statement of the last usage of the seed
        rule - the CrySL rule for the seed
        expectedMethodsToBeCalled - the methods that are expected to be called
        multiplePaths - set to true, if there are multiple paths (default: false)