Professional Documents
Culture Documents
Start Guide
Liferay Portal 6.2 EE
Introduction
Roles are a very powerful feature in Liferay Portal. They allow you to take advantage of the
fine-grained permissioning system and control what users or groups of users have access to
resources in large and very small scopes. This guide will help you get started in creating and
applying the basics of Liferay roles.
WHAT EXACTLY IS A ROLE?
A role is a collection of permissions. A role can be applied to a user or group of users. It can even
be applied to a Site or an Organization.
IS A ROLE EQUIVALENT WITH A GROUP?
No, because a role can exist and not have any users associated with it at all. A role is a collection
of permissions. A role can be applied to a group of users, affecting every user that belongs to,
or becomes a member of, that user group.
ARE THERE DIFFERENT TYPES OF ROLES?
Yes, they differ in scope. There are site roles, organization roles, and regular roles. Regular roles
have the largest scope and are applied portal-wide.
WHAT ROLES COME OUT OF THE BOX?
Administrator
Owner
Guest
User
Power User
Site Administrator
Site Owner
Site Member
Organization Administrator
Organization Owner
Organization User
You can also create custom roles very easily through the Roles administration in the Control Panel.
www.liferay.com
Creating A Role
Lets create a regular role and define its permissions.
CHOOSE THE TYPE AND THE NAME
Navigate to the Control Panel and click on Roles. Use the Add button to create a Regular role.
A Regular role is a role that has a portal-wide scope.
Name the role, and save.
www.liferay.com
www.liferay.com
www.liferay.com
www.liferay.com
Click Save. You now have a role with access to the Liferay WCM in the Control Panel, as well as the
ability to do the above Actions that have been checked.
www.liferay.com
Applying A Role
Now that we have created a role and defined its permissions, we can apply this role to a user.
ASSIGN MEMBERS TO THIS ROLE
Go to the Roles section on the Control Panel, find the role that you created and click on
Assign Members.
www.liferay.com
To remove this access, you can go back to the Roles section to either unassign the user from that
role in the Assign Members section, or the Role can be modified using the Define Permissions
section and removing (unchecking) the resources added earlier.
ROLE SCOPE
We have created a role with Regular scope. It is also possible to create roles that are scoped to a
Liferay Organization and to a Liferay Site. This is particularly helpful when the Liferay Portal Omni
Admin finds it useful to delegate different users to be the administrator for an Organization or Site.
www.liferay.com
Roles in Action
In addition to defining permissions for a role, you can limit access to different resources from the
resource itself.
APPLY THE ROLE TO A RESOURCE
Perhaps you have deployed and/or placed a portlet on a page and wish to limit its access.
Lets create some web content and limit the View access to only the newly created Role.
Click on the Permissions tab and use the permissions and roles matrix to remove and give
View access. Make sure to remove View access from the Guest role and Site Member Role,
and to grant View access to the role you created earlier, then save.
www.liferay.com
However, when you log in with the user that has the previously created role, it is visible.
In addition to portlets, you can also limit access to pages, buttons, and anything else in Liferay
Portal that has been designated as a resource and has a permissions configuration icon (the gear).
10
www.liferay.com
ORGANIZATION
COMMUNITY
User
Pages
Roles
Teams
Roles
User Groups
User
Pages
Teams
11
www.liferay.com
Additional Resources
The definitive resources on Liferay Portal, including the configurations discussed in this guide, are:
Liferay Portal User Guide (online):
http://www.liferay.com/documentation/liferay-portal/6.2/user-guide
Mastering Liferay Fundamentals (course):
http://www.liferay.com/services/training/topics/fundamentals
Administering Liferay Systems (course):
http://www.liferay.com/services/training/topics/system-admin
Liferay Roles (online):
http://www.liferay.com/documentation/liferay-portal/6.2/user-guide/-/ai/roles-and-permissionsliferay-portal-6-2-user-guide-16-en
Summary
In this guide, we outlined some quick ways to create and apply Liferay Roles after downloading
a Liferay Portal bundle. This is by no means a complete guide, but the best practices presented
here can help you start out on the right foot and avoid some common pitfalls.
Disclaimer
Liferay can only give you initial recommendations based on best practices and the experience
of professionals working with Liferay customers. Ultimately, it is your responsibility as system
architects and business analysts to come up with the scenarios that your system will need to
address and to run the appropriate tests on your system before production deployment, so that
you can identify significant circumstances and other unforeseen system and network issues.
Please use these settings at your own risk.
Moving Forward
Get a Free Demo
A Liferay team member is available to give you an in-depth look into the Liferay Portal features
and solutions that are helping enterprises worldwide realize their goals. Our customers include
top companies across industries such as Allianz, Cisco Systems, Dominos Pizza, Rolex and Toyota.
Request a free demo today at www.liferay.com/top-5-things-62/request-a-demo.
12
www.liferay.com
140625