Interface IPolicyDecisionPoint

All Superinterfaces:
IMyDataComponent

public interface IPolicyDecisionPoint extends IMyDataComponent
The PolicyDecisionPoint draws decisions based on the currently deployed policies.
Author:
Fraunhofer IESE
  • Method Details

    • addToBlacklist

      boolean addToBlacklist(Set<SolutionId> ids) throws IOException
      Adds a solution the to blacklist.
      Parameters:
      ids - the ids
      Returns:
      true, if successful
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • clearAllCaches

      boolean clearAllCaches(@Nullable SolutionId solutionId) throws IOException
      Clears all caches of the PDP (response and connector caches) about data related to the specified solution or any if solutionId==null.
      Parameters:
      solutionId - can be null to clear any data from the caches
      Returns:
      true, if cache was cleaned
      Throws:
      IOException - if there occurs a connection problem.
    • decisionRequest

      Notifies the PDP about a certain event. Based on the event, the policies are evaluated and decision is drawn.
      Parameters:
      event - the occurred event
      Returns:
      the AuthorizationDecision with respect to the event and deployed policies
      Throws:
      IOException - if there occurs a connection problem.
      EvaluationUndecidableException - if PDP can't evaluate the event due to internal ambiguity.
    • decisionRequests

      List<AuthorizationDecision> decisionRequests(List<Event> events) throws IOException
      Notifies the PDP about multiple events. Based on the events, the policies are evaluated and decision is drawn.
      Parameters:
      events - the occurred events
      Returns:
      the AuthorizationDecisions with respect to the event and deployed policies
      Throws:
      IOException - if there occurs a connection problem.
    • deploy

      boolean deploy(Policy policy, ZoneId zoneIdOfSolution) throws IOException, ConflictingPolicyException
      Deploys a policy.
      Parameters:
      policy - the policy to deploy
      zoneIdOfSolution - zoneId of solution
      Returns:
      true if the policy is deployed, false otherwise
      Throws:
      IOException - if there occurs a connection problem.
      ConflictingPolicyException - if multiple policy with same component_id are found in PMP
    • evaluate

      boolean evaluate(Event event) throws IOException
      Evaluate an event.
      Parameters:
      event - the event
      Returns:
      true, if successful
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • evaluate

      boolean evaluate(Set<Event> events) throws IOException
      Evaluate multiple events.
      Parameters:
      events - the events
      Returns:
      true, if successful
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • listDeployedPolicies

      Set<String> listDeployedPolicies() throws IOException
      Provides a list of currently deployed policy names.
      Returns:
      list of currently deployed policy names
      Throws:
      IOException - if there occurs a connection problem.
    • removeFromBlacklist

      boolean removeFromBlacklist(Set<SolutionId> ids) throws IOException
      Removes a solution from the blacklist.
      Parameters:
      ids - the ids
      Returns:
      true, if successful
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • revokePolicy

      boolean revokePolicy(PolicyId policyId) throws IOException, ResourceUpdateException
      Revokes a policy.
      Parameters:
      policyId - the name of the policy to be revoked
      Returns:
      true if the policy is revoked, false otherwise
      Throws:
      IOException - if there occurs a connection problem.
      ResourceUpdateException - fails to revoke the policy
    • isInFailureMode

      boolean isInFailureMode()
    • setFailureMode

      void setFailureMode(boolean active) throws IOException
      Sets the failure mode.
      Parameters:
      active - the new failure mode
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • updatePolicy

      boolean updatePolicy(Policy policy, ZoneId zoneIdOfSolution) throws IOException, ResourceUpdateException
      Updates a policy.
      Parameters:
      policy - the policy to be updated
      zoneIdOfSolution - zoneId of solution
      Returns:
      true if the policy is updated, false otherwise
      Throws:
      IOException - if there occurs a connection problem.
      ResourceUpdateException - fails to update the policy
      DOMException
      IllegalArgumentException
    • updatePolicyAndId

      boolean updatePolicyAndId(Policy policyWithNewId, ZoneId zoneIdOfSolution, PolicyId oldPolicyId) throws IOException, ResourceUpdateException
      Update policyId
      Parameters:
      policyWithNewId - the policy with the new id
      zoneIdOfSolution - zoneId of solution
      oldPolicyId - the previous policy id
      Returns:
      true, if successful
      Throws:
      IOException - Signals that an I/O exception has occurred.
      ResourceUpdateException - the policy update exception
    • isWhitelistModeEnabled

      boolean isWhitelistModeEnabled()
      Whitelist mode
      Returns:
      true if whitelist mode is enabled, false is blacklist mode