weavejester/ring-anti-forgery — pull request #15 by babysnakes (2013-05-13 15:24:21+00:00)
Title: Making ring-anti-forgery more customizable

Hi

This is my shot at making ring-anti-forgery more customizable. The only default behavior I changed is that the wrapper checks PUT/DELETE requests as well as POST requests.

The following customizations are offered:

* A custom response (so it's possible to return a json response or nicer html).
* An alternative function to extract the token from the request (e.g. AngularJS uses a different method to handle tokens - it adds them to the request headers).

I don't know much about clojure and I know even less about security. I did my best at figuring out what the code is doing and I changed as little as I could to add these customizations. I hope I didn't introduce some security issue.

There is a small project I'm writing to learn clojure that is using this fork. It's available [here](http://github.com/babysnakes/ayler).

One last thing, If you accept this pull request you need to remove the note at the beginning of the readme file :smile:

Thanks in advance

Haim