deegree 2.3 (2010/04/09 10:10 build-4-official)

org.deegree.security.owsrequestvalidator
Class RequestValidator

java.lang.Object
  extended by org.deegree.security.owsrequestvalidator.RequestValidator
Direct Known Subclasses:
AbstractCSWRequestValidator, AbstractWFSRequestValidator, AbstractWMSRequestValidator, GetCapabilitiesRequestValidator, GetFeatureInfoRequestValidator

public abstract class RequestValidator
extends Object

basic class for validating OWS requests

Version:
$Revision: 18195 $, $Date: 2009-06-18 17:55:39 +0200 (Do, 18. Jun 2009) $
Author:
Andreas Poth , last edited by: $Author: mschneider $

Field Summary
protected  GeneralPolicyValidator gpv
           
protected  Policy policy
           
protected  SecurityConfig securityConfig
           
protected  boolean userCoupled
           
 
Constructor Summary
RequestValidator(Policy policy)
           
 
Method Summary
 Policy getPolicy()
           
protected  void handleUserCoupledRules(User user, Feature feature, String secObjName, String secObjType, RightType rightType)
          handles the validation of user coupled parameters of a request
 void setPolicy(Policy policy)
           
protected  void validateExceptions(Condition condition, String exceptions)
          checks if the passed exceptions format is valid against the exceptions formats defined in the policy.
abstract  void validateRequest(OGCWebServiceRequest request, User user)
          validates if the passed request itself and its content is valid against the conditions defined in the policies assigned to a OWSPolicyValidator
protected  void validateVersion(Condition condition, String version)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

policy

protected Policy policy

gpv

protected GeneralPolicyValidator gpv

userCoupled

protected boolean userCoupled

securityConfig

protected SecurityConfig securityConfig
Constructor Detail

RequestValidator

public RequestValidator(Policy policy)
Parameters:
policy -
Method Detail

getPolicy

public Policy getPolicy()
Returns:
Returns the policy.

setPolicy

public void setPolicy(Policy policy)
Parameters:
policy - The policy to set.

validateRequest

public abstract void validateRequest(OGCWebServiceRequest request,
                                     User user)
                              throws InvalidParameterValueException,
                                     UnauthorizedException
validates if the passed request itself and its content is valid against the conditions defined in the policies assigned to a OWSPolicyValidator

Parameters:
request -
user -
Throws:
InvalidParameterValueException
UnauthorizedException

validateVersion

protected void validateVersion(Condition condition,
                               String version)
                        throws InvalidParameterValueException
Parameters:
condition -
version -
Throws:
InvalidParameterValueException

validateExceptions

protected void validateExceptions(Condition condition,
                                  String exceptions)
                           throws InvalidParameterValueException
checks if the passed exceptions format is valid against the exceptions formats defined in the policy. If user != null the valid exceptions formats will be read from the user/rights repository

Parameters:
condition - condition containing the definition of the valid exceptions
exceptions -
Throws:
InvalidParameterValueException

handleUserCoupledRules

protected void handleUserCoupledRules(User user,
                                      Feature feature,
                                      String secObjName,
                                      String secObjType,
                                      RightType rightType)
                               throws UnauthorizedException,
                                      InvalidParameterValueException
handles the validation of user coupled parameters of a request

Parameters:
user -
feature -
secObjName -
secObjType -
rightType -
Throws:
UnauthorizedException
InvalidParameterValueException

deegree 2.3 (2010/04/09 10:10 build-4-official)

an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org