Sure,
you can do something like this
SimpleAuthenticationPlugin authentication = new
SimpleAuthenticationPlugin();
List <AuthenticationUser> users = new ArrayList <AuthenticationUser> =
users.add(new AuthenticationUser("admin",
"password",
"admins,publishers,consumers"));
users.add(new AuthenticationUser("publisher",
"password",
"publishers,consumers"));
users.add(new AuthenticationUser("consumer",
"password",
"consumers"));
users.add(new AuthenticationUser("guest",
"password",
"guests"));
authentication.setUsers(users);
broker.setPlugins(new BrokerPlugin[]{authentication});
Cheers
--
Dejan Bosanac
Open Source Integration - http://fusesource.com/
ActiveMQ in Action - http://www.manning.com/snyder/
Blog - http://www.nighttale.net
On Tue, Jan 20, 2009 at 3:15 PM, Henri Gomez <[email protected]> wrote:
> Hi to all,
>
> I read the security plugin information in
> http://activemq.apache.org/security.html.
>
> I wonder if we could add an authentication/authorisation plugin
> programaticaly, ie on BrokerService.
>
> Regards.
>