com.tinkerpop.rexster.filter
Class DefaultSecurityFilter

java.lang.Object
  extended by org.glassfish.grizzly.filterchain.BaseFilter
      extended by com.tinkerpop.rexster.filter.AbstractSecurityFilter
          extended by com.tinkerpop.rexster.filter.DefaultSecurityFilter
All Implemented Interfaces:
com.sun.jersey.spi.container.ContainerRequestFilter, org.glassfish.grizzly.filterchain.Filter

public class DefaultSecurityFilter
extends AbstractSecurityFilter

Provides authentication for Rexster for all services: RexPro, REST, and Dog House.

Utilizes a simple list of usernames and passwords in rexster.xml. Example:

default rexster rexster


Nested Class Summary
 
Nested classes/interfaces inherited from class com.tinkerpop.rexster.filter.AbstractSecurityFilter
AbstractSecurityFilter.Authorizer, AbstractSecurityFilter.User
 
Field Summary
 
Fields inherited from class com.tinkerpop.rexster.filter.AbstractSecurityFilter
httpServletRequest, servletConfig, uriInfo
 
Constructor Summary
DefaultSecurityFilter()
           
 
Method Summary
 boolean authenticate(String username, String password)
          Checks the users map to determine if the username and password supplied is one of the ones available..
 void configure(org.apache.commons.configuration.XMLConfiguration configuration)
          Reads the configuration from rexster.xml and converts it to a map of usernames and passwords.
 String getName()
          The name of the security filter.
 
Methods inherited from class com.tinkerpop.rexster.filter.AbstractSecurityFilter
filter, handleRead
 
Methods inherited from class org.glassfish.grizzly.filterchain.BaseFilter
createContext, exceptionOccurred, getFilterChain, getIndex, handleAccept, handleClose, handleConnect, handleEvent, handleWrite, onAdded, onFilterChainChanged, onRemoved
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultSecurityFilter

public DefaultSecurityFilter()
Method Detail

authenticate

public boolean authenticate(String username,
                            String password)
Checks the users map to determine if the username and password supplied is one of the ones available..

Specified by:
authenticate in class AbstractSecurityFilter

configure

public void configure(org.apache.commons.configuration.XMLConfiguration configuration)
Reads the configuration from rexster.xml and converts it to a map of usernames and passwords.

Specified by:
configure in class AbstractSecurityFilter

getName

public String getName()
Description copied from class: AbstractSecurityFilter
The name of the security filter.

Specified by:
getName in class AbstractSecurityFilter


Copyright © 2009-2012. All Rights Reserved.