Compojure/Noir using Spring Security for auth & auth?
开发者_开发问答Caveat: I'm coming from a PHP background, with a few Java/Tomcat skills that are rusty and out-of-date.
I've been using Sandbar with Compojure to secure my web app, but I hear it's relatively simple to use Spring Security to handle basic user authentication and role-based access restrictions. I've been through the Spring Security tutorials, but I can't quite make the translation to Clojure code. Does anyone have a sample web app or even just a few pointers that would show me how to drop in Spring Security for my auth & auth? Links to existing docs are welcome too.
Thanks.
You can follow this example which integrates Spring and Spring Security into a Compojure application running on Jetty. All the source code for a working example can be found on github.
精彩评论