Spring Extensions

com.myjeeva.spring.security.util
Class SecureUriMapperImpl

java.lang.Object
  extended by com.myjeeva.spring.security.util.SecureUriMapperImpl
All Implemented Interfaces:
SecureUriMapper

public class SecureUriMapperImpl
extends Object
implements SecureUriMapper

Concrete implementation of SecureUriMapper that obtains URI/URL's pass key from the application context.

So getPassKey(String) method applies the Ant-style path patterns for verification.

Since:
v1.0.1
Author:
Jeevanandam ([email protected])

Constructor Summary
SecureUriMapperImpl()
          Constructor
 
Method Summary
 String getPassKey(String uri)
          getting a pass key for given URI/URL
 Map getUriMappings()
          Returns the respective URI/URL name mapping specified via setUriMappings(Map)
 void setUriMappings(Map inputUriMappings)
          Set to map the pass key and Ant-style path patterns In a Spring XML ApplicationContext, a definition would look something like this:
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SecureUriMapperImpl

public SecureUriMapperImpl()
Constructor

Method Detail

getUriMappings

public Map getUriMappings()
Returns the respective URI/URL name mapping specified via setUriMappings(Map)


setUriMappings

public void setUriMappings(Map inputUriMappings)
Set to map the pass key and Ant-style path patterns In a Spring XML ApplicationContext, a definition would look something like this:
  <property name="uriMappings">
      <map>
          <entry key="tg54f54h59e"><value>/data/secure/*</value></entry>
          <entry key="34ti94l2qo"><value>/protected/*</value></entry>
      </map>
 </property>

Parameters:
inputUriMappings - - A Map consisting of String keys and String values, where for each entry the key is the string representation of an password, and the value is the string representation of the corresponding Ant-style path patterns; where filter will intercept.
Throws:
IllegalArgumentException - if input map does not consist of String keys and values.

getPassKey

public String getPassKey(String uri)
getting a pass key for given URI/URL

Specified by:
getPassKey in interface SecureUriMapper
Parameters:
uri - a String object.
Returns:
pass key if success or null if no match

Spring Extensions

Copyright © 2010-2012 www.myjeeva.com, All rights reserved.

The copyright of the pages and contents on this website is with myjeeva.com and the content is licensed under Creative Commons Attribution-Share Alike 3.0 Unported License. Libraries and code snippets on myjeeva.com has license information.