Page tree
Skip to end of metadata
Go to start of metadata
Your Rating: Results: 1 Star2 Star3 Star4 Star5 Star 114 rates

If you deploy the magnolia war on a geronimo server you will have to setup authentication/a security realm on geronimo to be able to login to AdminCentral. Here's how:

  1. login to your geronimo console
  2. choose "Security Realms" in the menu and click on "Add new security realm" and follow the wizard
  3. Step 1
    Name of Security Realm: magnolia
    Realm Type: other
  4. Step 2
    Login Module JAR: choose the war from the list where you have deployed magnolia (e.g.: default/magnolia-bundled-webapp-4.2.3/1266074207292/war)
    1. Login Module 1
      1. Login Domain Name: magnolia
      2. Login module class: info.magnolia.jaas.sp.jcr.JCRAuthenticationModule
      3. Control Flag: requisite
      4. leave all other fields on the default values
    2. Login Module 2
      1. Login Domain Name: magnolia-authorization
      2. Login module class: info.magnolia.jaas.sp.jcr.JCRAuthorizationModule
      3. Control Flag: required
      4. leave all other fields on the default values
  5. Click on the Deploy button

You are now ready to login to the AdminCentral using the default username:superuser & password:superuser

Possible errors for incorrect security realm setups

To catch those who are struggling setting up the correct realm via Google, a list of possible errors you might run into;

Correct realm name but wrong authentication & authorization classes

When you setup a security realm correctly called "magnolia" which doesn't use the magnolia authentication & authorization classes you will see the following errors in your log files;

info.magnolia.cms.security.SystemUserManager      : Failed to login as anonymous user
javax.security.auth.login.FailedLoginException at org.apache.geronimo.security.realm.providers.PropertiesFileLoginModule.login(PropertiesFileLoginModule.java:205)

&

info.magnolia.cms.security.DummyUser              : Initializing dummy user - Anonymous
info.magnolia.cms.security.DummyUser              : This area and/or instance is not secured
Servlet.service() for servlet default threw exception
java.util.NoSuchElementException at java.util.HashMap$HashIterator.nextEntry(HashMap.java:796)

No realm at all

When you don't setup a security realm at all you will see the following errors in your log files;

ERROR info.magnolia.cms.security.SecuritySupportBase    : Can't login due to:
javax.security.auth.login.LoginException: No LoginModules configured for magnolia
at javax.security.auth.login.LoginContext.init(LoginContext.java:256)

  • No labels