Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

A Guice-ready security framework?

Has anybody seen a framework which is either written to work with Guice or a library that integrates an existing security system (ie: Acegi) with Guice?

I have found the following thus far...

http://code.google.com/p/warp-security/ (I think this abandonware)

http://code.google.com/p/warp-security/ (no documentation)

like image 823
benstpierre Avatar asked Nov 26 '09 21:11

benstpierre


2 Answers

Apache Shiro 1.2 and later has native support for Guice applications:

http://shiro.apache.org/guice.html

HTH!

like image 65
Les Hazlewood Avatar answered Oct 05 '22 20:10

Les Hazlewood


For whatever it's worth (being quite a late answer), I've had success integrating Apache Shiro with Guice. Last time I checked, Acegi was too deeply dependent on Spring to be usable in a pure Guice solution. Shiro's documentation is a little lacking, but the API is pretty straight-forward and easy to use, if don't mind a little digging.


In case it's of any interest, I've posted a Gist of the simplest example I could find. Two caveats:

  1. It's written against a pre-release version of Shiro 1.0
  2. The Active Directory realm we're using is a somewhat modified version from the main Shiro source, using some ideas from the Active Directory plugin for Jenkins (then Hudson).

Hopefully, it's enough to get you started...

like image 42
ig0774 Avatar answered Oct 05 '22 21:10

ig0774