Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Pundit - Ruby on Rails Police Department

Pundit - Ruby on Rails Police Department

The presentation is a quick guide to Pundit - Ruby on Rails solution for building a simple, robust and scaleable authorization system for your web application. It covers both the idea behind the gem and an easy way how to use it in your project.

Author: Piotr Kochowicz, web developer at Binar::Apps (http://binarapps.com)

Avatar for Piotr Kochowicz

Piotr Kochowicz

November 18, 2015
Tweet

More Decks by Piotr Kochowicz

Other Decks in Programming

Transcript

  1. POLICY Defined for an object Accesses a user and an

    object Contains Scope class and authorization methods inherits from ApplicationPolicy
  2. APPLICATION CONTROLLER Ensures policies are used Handles authorization exception Additional

    exception info exception.policy exception.query exception.record