Search code examples
jbosshornetqjboss-cli

Verify HornetQ user name & password using JSOSS CLI


I have added Hornetq user using add-uesr.sh script.

I want to write a script to verify hornetq username and password entered by someone is correct or not (before configuring any other components like JMS queues etc).

Does JBOSS CLI provide a way to check the validity of authentication details?

Thank you!


Solution

  • You will not be able to use the JBoss CLI.

    I suggest using a Hornteq JMS Client, just extend an example program and pass in username and password via command line paramters or property files. You could also check the correct queues and topics are available to the given user. You can also use the JBoss CLI in Java to check a message is delivered to a queue or topic etc. Make sure your program uses the correct exit code for success or failure.