# Users, Roles and Permissions

**URL:** <https://www.ruby-forum.com/t/users-roles-and-permissions/174618>\
**Category:** Rails\
**Created:** [August 29, 2009, 10:12pm UTC](https://www.ruby-forum.com/t/users-roles-and-permissions/174618 "2009-08-29T22:12:08Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Arne\_De\_Herdt](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/b9bd4f/32.png) [@Arne\_De\_Herdt](https://www.ruby-forum.com/u/Arne_De_Herdt)\
**Post date:** [August 29, 2009, 10:12pm UTC](https://www.ruby-forum.com/t/users-roles-and-permissions/174618/1 "2009-08-29T22:12:08Z")

</div>

Hello,

I’m currently working on a text-based roleplay browser game, and i’m  
trying  
to figure out what the best approach would be in order to create a  
system  
that allows me to assign roles to a user, and permissions based upon the  
role a user has.  
I’ve been thinking about creating a model User, which has\_many :roles,  
and  
with the Role model which has\_many :permissions.  
The Permission Model would then just be a set of boolean that signal  
what he  
can/can’t do.

I’m aware that there is the authorizable plugin, which delivers a nice  
system, but I’m just trying to build something on my own to get the  
feeling  
for rails & ruby again. I believe that the above mentioned system would  
work, but I’m a bit curious on the dynamic side of it. What I’d actually  
like to know, if it is possible to store the controller & actions  
automaticly as properties of the Permission object, or if this has to be  
done manually for each one I create?

ALso, I’m relatively new to the entire RoR concept, although I already  
had a  
first working experience with it, so I’m open to ideas & suggestions as  
well.

–  
Arne De Herdt  
Blog: [http://risusmumblings.blogspot.com/](http://risusmumblings.blogspot.com/)

---

<div class="post-metadata">

**Author:** ![Arne\_De\_Herdt](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/b9bd4f/32.png) [@Arne\_De\_Herdt](https://www.ruby-forum.com/u/Arne_De_Herdt)\
**Post date:** [August 31, 2009, 12:50pm UTC](https://www.ruby-forum.com/t/users-roles-and-permissions/174618/2 "2009-08-31T12:50:15Z")

</div>

Why not try “Hobo”, a rails extension. It includes a pretty decent  
permission based system using roles… that u can set declaratively for  
your  
application. Hobo also include a host of other realy cool features.

> **[Venostech.com](https://www.venostech.com/)**
>
> Venostech.com

---

<div class="post-metadata">

**Author:** ![Arne\_De\_Herdt](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/b9bd4f/32.png) [@Arne\_De\_Herdt](https://www.ruby-forum.com/u/Arne_De_Herdt)\
**Post date:** [August 31, 2009, 2:36pm UTC](https://www.ruby-forum.com/t/users-roles-and-permissions/174618/3 "2009-08-31T14:36:49Z")

</div>

I’m aware of Hobo etc.  
The idea behind this whole question line is more theoretical then  
coding/practical implementation.

I’m just trying to figure out from analasys point of view what the best  
approach would be to implement a dynamic system for roles/permissions on  
users.

–  
Arne

2009/8/31 Kristian M. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)

> Why not try “Hobo”, a rails extension. It includes a pretty decent  
> permission based system using roles… that u can set declaratively for your  
> application. Hobo also include a host of other realy cool features.
> 
> [http://hobocentral.net/](http://hobocentral.net/)
> 
> >

–  
Arne De Herdt  
Blog: [http://risusmumblings.blogspot.com/](http://risusmumblings.blogspot.com/)
