Extends Rails applications and APIs to comply with AngularJS CSRF protection