Rails first calls your ApplicationController, before the local ... so you can do something like this (using your example):
In your application controller, you will have a before_filter and the corresponding method that is called:
before_filter :authenticate def authenticate
In the controller for the type of resource you are working with ...
You can override / override authenticate
def authenticate
You can even choose NOT to use authenticate callback for some methods
skip_before_filter :authenticate, :only => :my_method_without_auth
source share