Class FollowFlow


  • public class FollowFlow
    extends java.lang.Object
    FollowFlow follows the program's code flow either forward or backward from an initial address set. It adds the flow addresses to the initial address set by flowing "from" the initial addresses in the forward direction or by flowing "to" the initial addresses when used in the backward direction. The flow can be limited by indicating the flow types (i.e. unconditional call, computed jump, etc.) that we do NOT want to follow.
    • Constructor Detail

      • FollowFlow

        public FollowFlow​(Program program,
                          AddressSet addressSet,
                          FlowType[] doNotFollow)
        Constructor
        Parameters:
        program - the program whose flow we are following.
        addressSet - the initial addresses that should be flowed from or flowed to.
        doNotFollow - array of flow types that are not to be followed. null or empty array indicates follow all flows. The following are valid flow types for the doNotFollow array:
        FlowType.COMPUTED_CALL
        FlowType.CONDITIONAL_CALL
        FlowType.UNCONDITIONAL_CALL
        FlowType.COMPUTED_JUMP
        FlowType.CONDITIONAL_JUMP
        FlowType.UNCONDITIONAL_JUMP
        FlowType.INDIRECTION
      • FollowFlow

        public FollowFlow​(Program program,
                          AddressSet addressSet,
                          FlowType[] doNotFollow,
                          boolean followIntoFunctions)
        Constructor
        Parameters:
        program - the program whose flow we are following.
        addressSet - the initial addresses that should be flowed from or flowed to.
        doNotFollow - array of flow types that are not to be followed. null or empty array indicates follow all flows. The following are valid flow types for the doNotFollow array:
        FlowType.COMPUTED_CALL
        FlowType.CONDITIONAL_CALL
        FlowType.UNCONDITIONAL_CALL
        FlowType.COMPUTED_JUMP
        FlowType.CONDITIONAL_JUMP
        FlowType.UNCONDITIONAL_JUMP
        FlowType.INDIRECTION
        followIntoFunctions - true if flows into (or back from) defined functions should be followed.
    • Method Detail

      • getFlowAddressSet

        public AddressSet getFlowAddressSet​(TaskMonitor monitor)
        Determines the address set that flows from the addresses in this FollowFlow object's initialAddresses set. The address set is determined by what addresses were provided when the FollowFlow was constructed and the type of flow requested. This method follows flows in the forward direction.
        Parameters:
        monitor - a cancellable task monitor, may be null
        Returns:
        the resulting address set.
      • getFlowToAddressSet

        public AddressSet getFlowToAddressSet​(TaskMonitor monitor)
        Determines the address set that flows to the addresses in this FollowFlow object's initialAddresses set. The address set is determined by what addresses were provided when the FollowFlow was constructed and the type of flow requested. The constructor indicated the flow types not to be followed. All others will be traversed in the backwards direction to determine the addresses that are flowing to those in the initial set.
        Parameters:
        monitor - a cancellable task monitor, may be null
        Returns:
        the resulting address set.