com.atlassian.confluence.web.filter.validateparam
Class ParamNameWhitelistStrategy

java.lang.Object
  extended by com.atlassian.confluence.web.filter.validateparam.ParamNameWhitelistStrategy
All Implemented Interfaces:
RequestParamCleaningWhitelistStrategy

public class ParamNameWhitelistStrategy
extends Object
implements RequestParamCleaningWhitelistStrategy

A simple whitelist cleaning strategy that accepts a set of parameter names, and permits any parameters whose name is in that set.


Constructor Summary
ParamNameWhitelistStrategy()
           
 
Method Summary
 Set<String> getParamNames()
           
 boolean isWhiteListed(String path, String paramName)
          Checks whether a parameter is white-listed by its name.
 void setParamNames(Set<String> paramNames)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ParamNameWhitelistStrategy

public ParamNameWhitelistStrategy()
Method Detail

isWhiteListed

public boolean isWhiteListed(String path,
                             String paramName)
Checks whether a parameter is white-listed by its name.

Specified by:
isWhiteListed in interface RequestParamCleaningWhitelistStrategy
Parameters:
path - ignored
paramName - the name of the parameter to check
Returns:
true if the parameter name is in the white-list.

getParamNames

public Set<String> getParamNames()

setParamNames

public void setParamNames(Set<String> paramNames)


Copyright © 2003-2012 Atlassian. All Rights Reserved.