org.codehaus.activemq.security.jassjacc
Class JassJaccSecurityAdapter

java.lang.Object
  extended byorg.codehaus.activemq.security.jassjacc.JassJaccSecurityAdapter
All Implemented Interfaces:
SecurityAdapter

public class JassJaccSecurityAdapter
extends Object
implements SecurityAdapter

Implements SecurityAdapter that uses JASS to authenticate and JACC to authorize the user operations.

Version:
$Revision: 1.2 $

Constructor Summary
JassJaccSecurityAdapter(String jassConfiguration)
           
 
Method Summary
 void authorizeConnection(BrokerClient client, ConnectionInfo info)
          Authenticates the connection and authorizes it for use with this Message Broker
 void authorizeConsumer(BrokerClient client, ConsumerInfo info)
          Authorizes that the consumer can start with the given consumer information
 void authorizeProducer(BrokerClient client, ProducerInfo info)
          Authorizes that the prodcuer can start with the given producer information.
 void authorizeSendMessage(BrokerClient client, ActiveMQMessage message)
          Authorizes on a per message basis whether or not the client is allowed to send the given message.
protected  AccessControlContext getAccessControlContext(BrokerClient client)
           
protected static String getBrokerName(BrokerClient client)
           
static void secure(BrokerSecurityConfig brokerSecurity)
          Creates a JACC PolicyConfiguration for the broker security.
static void secure(DestinationSecurityConfig destinationSecurity)
          Creates a JACC PolicyConfiguration for the broker security.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JassJaccSecurityAdapter

public JassJaccSecurityAdapter(String jassConfiguration)
Parameters:
jassConfiguration -
Method Detail

getAccessControlContext

protected AccessControlContext getAccessControlContext(BrokerClient client)

getBrokerName

protected static String getBrokerName(BrokerClient client)

authorizeConnection

public void authorizeConnection(BrokerClient client,
                                ConnectionInfo info)
                         throws JMSException
Description copied from interface: SecurityAdapter
Authenticates the connection and authorizes it for use with this Message Broker

Specified by:
authorizeConnection in interface SecurityAdapter
Throws:
JMSException - if the connection is not allowed for any reason

authorizeConsumer

public void authorizeConsumer(BrokerClient client,
                              ConsumerInfo info)
                       throws JMSException
Description copied from interface: SecurityAdapter
Authorizes that the consumer can start with the given consumer information

Specified by:
authorizeConsumer in interface SecurityAdapter
Throws:
JMSException - if the connection is not allowed for any reason

authorizeProducer

public void authorizeProducer(BrokerClient client,
                              ProducerInfo info)
                       throws JMSException
Description copied from interface: SecurityAdapter
Authorizes that the prodcuer can start with the given producer information. Note that the destination information may not be present at the start of the producer.

Specified by:
authorizeProducer in interface SecurityAdapter
Throws:
JMSException - if the connection is not allowed for any reason

authorizeSendMessage

public void authorizeSendMessage(BrokerClient client,
                                 ActiveMQMessage message)
                          throws JMSException
Description copied from interface: SecurityAdapter
Authorizes on a per message basis whether or not the client is allowed to send the given message. The client may not have been authorized yet for this destination as a destination may not have been specified on the previous call to SecurityAdapter.authorizeProducer(org.codehaus.activemq.broker.BrokerClient, org.codehaus.activemq.message.ProducerInfo)

Specified by:
authorizeSendMessage in interface SecurityAdapter
Throws:
JMSException

secure

public static void secure(BrokerSecurityConfig brokerSecurity)
Creates a JACC PolicyConfiguration for the broker security.

Parameters:
brokerSecurity -

secure

public static void secure(DestinationSecurityConfig destinationSecurity)
Creates a JACC PolicyConfiguration for the broker security.



Copyright © 2004-2005 Protique, Ltd.. All Rights Reserved.