Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagegroovy
titleReset superuser with Groovy
session = MgnlContext.getJCRSession('users')
superuser = session.getNode('/system/superuser') 
superuser.pswd = info.magnolia.cms.security.SecurityUtil.getBCrypt('superuser') 
session.save()

As with the jsp tsp script you need to stop Magnolia and uncomment the filters sections in web.xml (see again refer again to Groovy Rescue App).