6 Replies Latest reply: May 27, 2010 1:34 PM by Anil Saldhana RSS

Making basic PicketBox authentication sample working in JBoss AS 6.0

Sergey Beryozkin Newbie

Hi

 

I'm trying to update some existing JBossWS authentication code to use PicketBox API, as shown at [1]. I'm working with JBoss AS trunk.

 

Specifically, $JBossAS/server/default/conf/login-config.xml contains application policy definitions for various domains, such as JBossWS, etc.

I'm trying to do the code like this (just omitting try/catch/finally for brewity):

 

// to be configured

String configFile = "conf/login-config.xml";
SecurityFactory.prepare();
PicketBoxConfiguration idtrustConfig = new PicketBoxConfiguration();
idtrustConfig.load(configFile);

 

this throws ConfigurationStreamNullException during the test.

 

Initial question : what is the correct way to specify the name of the configuration file (login-config.xml) shipped with JBoss AS ?

 

cheers, Sergey

 

P.S. By the way, only picketbox-bare-3.0.0.Beta5 (no picketbox-bare-3.0.0.Beta6) is available in Maven repos

 

[1] https://community.jboss.org/wiki/PicketBoxAuthentication