Class ThreeLevelsTaint

  • All Implemented Interfaces:
    it.unive.lisa.analysis.BaseLattice<ThreeLevelsTaint>, it.unive.lisa.analysis.Lattice<ThreeLevelsTaint>, it.unive.lisa.analysis.nonrelational.NonRelationalDomain<ThreeLevelsTaint,​it.unive.lisa.symbolic.value.ValueExpression,​it.unive.lisa.analysis.nonrelational.value.ValueEnvironment<ThreeLevelsTaint>>, it.unive.lisa.analysis.nonrelational.NonRelationalElement<ThreeLevelsTaint,​it.unive.lisa.symbolic.value.ValueExpression,​it.unive.lisa.analysis.nonrelational.value.ValueEnvironment<ThreeLevelsTaint>>, it.unive.lisa.analysis.nonrelational.value.BaseNonRelationalValueDomain<ThreeLevelsTaint>, it.unive.lisa.analysis.nonrelational.value.NonRelationalValueDomain<ThreeLevelsTaint>, it.unive.lisa.analysis.SemanticEvaluator, it.unive.lisa.util.representation.StructuredObject

    public class ThreeLevelsTaint
    extends BaseTaint<ThreeLevelsTaint>
    A BaseTaint implementation with three level of taintedness: clean, tainted and top. As such, this class distinguishes values that are always clean, always tainted, or tainted in at least one execution path.
    • Constructor Detail

      • ThreeLevelsTaint

        public ThreeLevelsTaint()
        Builds a new instance of taint.
    • Method Detail

      • isAlwaysTainted

        public boolean isAlwaysTainted()
        Description copied from class: BaseTaint
        Yields true if this instance represents information that is definitely tainted across all execution paths.
        Specified by:
        isAlwaysTainted in class BaseTaint<ThreeLevelsTaint>
        Returns:
        true if that condition holds
      • isPossiblyTainted

        public boolean isPossiblyTainted()
        Description copied from class: BaseTaint
        Yields true if this instance represents information that is definitely tainted in at least one execution path.
        Specified by:
        isPossiblyTainted in class BaseTaint<ThreeLevelsTaint>
        Returns:
        true if that condition holds
      • representation

        public it.unive.lisa.util.representation.StructuredRepresentation representation()
      • evalBinaryExpression

        public ThreeLevelsTaint evalBinaryExpression​(it.unive.lisa.symbolic.value.operator.binary.BinaryOperator operator,
                                                     ThreeLevelsTaint left,
                                                     ThreeLevelsTaint right,
                                                     it.unive.lisa.program.cfg.ProgramPoint pp,
                                                     it.unive.lisa.analysis.SemanticOracle oracle)
                                              throws it.unive.lisa.analysis.SemanticException
        Specified by:
        evalBinaryExpression in interface it.unive.lisa.analysis.nonrelational.value.BaseNonRelationalValueDomain<ThreeLevelsTaint>
        Overrides:
        evalBinaryExpression in class BaseTaint<ThreeLevelsTaint>
        Throws:
        it.unive.lisa.analysis.SemanticException
      • lubAux

        public ThreeLevelsTaint lubAux​(ThreeLevelsTaint other)
                                throws it.unive.lisa.analysis.SemanticException
        Throws:
        it.unive.lisa.analysis.SemanticException
      • wideningAux

        public ThreeLevelsTaint wideningAux​(ThreeLevelsTaint other)
                                     throws it.unive.lisa.analysis.SemanticException
        Throws:
        it.unive.lisa.analysis.SemanticException
      • lessOrEqualAux

        public boolean lessOrEqualAux​(ThreeLevelsTaint other)
                               throws it.unive.lisa.analysis.SemanticException
        Throws:
        it.unive.lisa.analysis.SemanticException
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface it.unive.lisa.analysis.BaseLattice<ThreeLevelsTaint>
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object obj)
        Specified by:
        equals in interface it.unive.lisa.analysis.BaseLattice<ThreeLevelsTaint>
        Overrides:
        equals in class java.lang.Object
      • toString

        public java.lang.String toString()
        Specified by:
        toString in interface it.unive.lisa.analysis.BaseLattice<ThreeLevelsTaint>
        Overrides:
        toString in class java.lang.Object