Plugins You can find out about all the publicly available Grails plugins.

Shiro User Interface

  • Tags: ui, frontend, security
  • Latest: 1.0-beta4
  • Last Updated: 18 August 2011
  • Grails version: 1.3.7
  • Authors: Yellowsnow
1 vote
compile "org.grails.plugins:shiro-ui:1.0-beta4"

 Source  Issues


A basic Shiro User Interface


grails install-plugin shiro-ui


This plugin tries to provide a basic user interface for shiro plugin. It depends on the excellent Apache shiro and Mail plugins.

The ShiroDBRealm is used in this plugin, this assumes users, roles and permissions are stored in the database.


grails install-plugin shiro-ui

Feature summary

  • User and Role management frontends with basic permission configuration : ${appName}/shiroUser/ and ${appName}/shiroRole/
  • Password recovery via email : ${appName}/auth/lostPassword
  • Password update : ${appName}/auth/updatePassword
  • User creation by priviliged user with temporary password sent by email (password update is requested on log on)
During installation, all templates (controllers, domain classes and views) are directly copied to the project.

Admin user creation

Admin user creation can be done in the Bootstrap :

import org.apache.shiro.crypto.hash.Sha256Hash

class BootStrap {

def init = { servletContext ->

def adminRole = ShiroRole.findByName("Administrator")


adminRole = new ShiroRole(name: 'Administrator')



def admin = ShiroUser.findByUsername('admin')


admin = new ShiroUser(firstName:"Administator",lastName:"User",

username: 'admin', passwordHash: new Sha256Hash("changeit").toHex(),email:'[email protected]')




def destroy = {



Plugin RoadMap

  • Allow custom permissions such as "book:buy,sell:1,2"
  • External mail templates (now hardcoded in controller)
  • Script to manually install templates
  • User sign-up with admin approval