Search code examples
.htaccessadminjboss7.x

Jboss Admin Console - blocked by .htaccess?


I installed a clean jboss 7.1.Final Server.

after running it, I made an sh add_user.sh in the bin folder

I chose a) for Management User

I entered:
Realm (ManagementRealm) : joerg
Username : joerg
Password : superpassword
Re-enter Password : superpassword

when I entered then http://localhost:9990/console/ it was forwarded to http://localhost:9990/console/App.html

the problem is, that if I go to the URL http://localhost:9990/console/App.html I can't log in, because i get the typical HTTP-Basic Authentication promt for username and password (looks like there is a .htaccess but i never made one)

If I try
login: joerg
password: superpassword
it is not working

(on the shell the username and password works with the jboss diagnostic reporter jdr.sh)


Solution

  • In your example, you will need to enter the ManagementRealm as the realm that your primary user account will resolve to. Your example would be:

    Realm (ManagementRealm) : ManagementRealm
    Username : joerg
    Password : superpassword
    Re-enter Password : superpassword
    

    From the official documentation, this is explained as follows:

    It is important to leave the name of the realm as 'ManagementRealm' as this needs to match the name used in the server's configuration, for the remaining fields enter the new username, password and password confirmation.

    Provided there are no errors in the values entered you will then be asked to confirm that you want to add the user, the user will be written to the properties files used for authentication and a confirmation message will be displayed.

    With JBoss Application Server 7.1.x being so customisable, you can build your own realm configurations as required, but for the initial instance, make sure you use the ManagementRealm.