Details

    • Type: New Feature New Feature
    • Status: Open
    • Priority: Critical Critical
    • Resolution: Unresolved
    • Affects Version/s: 1.2.0, 1.2.1
    • Fix Version/s: 1.3.0
    • Component/s: Integration: JEE
    • Labels:
      None

      Description

      As there is a spring or guice integration, a CDI integration could be welcomed.

      1. SHIRO-337-3.patch
        25 kB
        Harald Wellmann
      2. SHIRO-337-2.patch
        23 kB
        Romain Manni-Bucau
      3. SHIRO-337.patch
        22 kB
        Romain Manni-Bucau

        Issue Links

          Activity

          Hide
          Jason Wagner added a comment -

          I would concur. At the very least a prominent link to it in the documentation would be appreciated. It would have prevented me from implementing duplicate capabilities.

          Show
          Jason Wagner added a comment - I would concur. At the very least a prominent link to it in the documentation would be appreciated. It would have prevented me from implementing duplicate capabilities.
          Hide
          Romain Manni-Bucau added a comment -

          Les Hazlewood what's blocking to get it included? pax config is nice, interceptor is quite common to all versions (reusing existing aop base of shiro) and shiro handlers (session, subject, security manager) too

          Show
          Romain Manni-Bucau added a comment - Les Hazlewood what's blocking to get it included? pax config is nice, interceptor is quite common to all versions (reusing existing aop base of shiro) and shiro handlers (session, subject, security manager) too
          Hide
          Harald Wellmann added a comment -

          This patch and other unreleased community contributions have been released in an independent extension project Pax Shiro.

          Docs:
          http://team.ops4j.org/wiki/display/PAXSHIRO/

          Sources:
          https://github.com/ops4j/org.ops4j.pax.shiro

          Show
          Harald Wellmann added a comment - This patch and other unreleased community contributions have been released in an independent extension project Pax Shiro. Docs: http://team.ops4j.org/wiki/display/PAXSHIRO/ Sources: https://github.com/ops4j/org.ops4j.pax.shiro
          Hide
          Jason Wagner added a comment - - edited

          Not having come across this ticket, I started an implementation of a seperate module for CDI support. Link at https://github.com/TensorWrench/shiro-jee. Will check out what features are in the patch and see what makes sense to carry over.

          Show
          Jason Wagner added a comment - - edited Not having come across this ticket, I started an implementation of a seperate module for CDI support. Link at https://github.com/TensorWrench/shiro-jee . Will check out what features are in the patch and see what makes sense to carry over.
          Hide
          Romain Manni-Bucau added a comment -

          any news?

          Show
          Romain Manni-Bucau added a comment - any news?
          Hide
          Les Hazlewood added a comment -

          We'll do our best to have this included in 1.3. I'm trying to knock down bugs this week to allow that to be possible.

          Show
          Les Hazlewood added a comment - We'll do our best to have this included in 1.3. I'm trying to knock down bugs this week to allow that to be possible.
          Hide
          Juan Manuel CABRERA added a comment -

          Would be a great helper in our project too !

          Show
          Juan Manuel CABRERA added a comment - Would be a great helper in our project too !
          Hide
          Thibault Tigeon added a comment -

          Is it possible to have this functionality in the next release?
          It would be nice

          Thibault

          Show
          Thibault Tigeon added a comment - Is it possible to have this functionality in the next release? It would be nice Thibault
          Hide
          Christian Müller added a comment -

          Harald, thanks for sharing your solution and the hint. I will have a look tomorrow on your suggestion with my colleague, who is working on it.
          I hope your patch will find a way to the source code repo soon...

          Show
          Christian Müller added a comment - Harald, thanks for sharing your solution and the hint. I will have a look tomorrow on your suggestion with my colleague, who is working on it. I hope your patch will find a way to the source code repo soon...
          Hide
          Harald Wellmann added a comment -

          Attached is an improved version of the patch which adds an interceptor binding @ShiroSecured, as JBoss/Weld complained about a missing binding. I also added some more unit tests.

          See also https://github.com/hwellmann/shiro.

          Show
          Harald Wellmann added a comment - Attached is an improved version of the patch which adds an interceptor binding @ShiroSecured, as JBoss/Weld complained about a missing binding. I also added some more unit tests. See also https://github.com/hwellmann/shiro .
          Hide
          Harald Wellmann added a comment -

          Christian, I don't think this patch is related to your problem. I'm also using Shiro with CDI on JBoss AS 7.1.3 with a custom FooRealm extending AuthorizingRealm, and I don't see this error. I suppose the difference is that my realm is @Dependent (and thus does not require a proxy) whereas yours is @ApplicationScoped.

          Show
          Harald Wellmann added a comment - Christian, I don't think this patch is related to your problem. I'm also using Shiro with CDI on JBoss AS 7.1.3 with a custom FooRealm extending AuthorizingRealm, and I don't see this error. I suppose the difference is that my realm is @Dependent (and thus does not require a proxy) whereas yours is @ApplicationScoped.
          Hide
          Christian Müller added a comment - - edited

          We have issues running Shiro inside of JBoss 7. Anything we can do to get this (one year old) patch applied? Anybody faced the same issue and found a workaround?

          Our stack trace (using Shiro 1.2.1):

          14:56:08,519 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-4) MSC00001: Failed to start service jboss.deployment.unit."xxx-gui.war".WeldService: org.jboss.msc.service.StartException in service jboss.deployment.unit."xxx-gui.war".WeldService: org.jboss.weld.exceptions.UnproxyableResolutionException: WELD-001437 Normal scoped bean class org.apache.shiro.realm.AuthenticatingRealm is not proxyable because the type is final or it contains a final method public final void org.apache.shiro.realm.AuthenticatingRealm.init() - Managed Bean [class net.atos.xa.rm.app.realm.RMRealm] with qualifiers [@Any @Default].
                          at org.jboss.as.weld.services.WeldService.start(WeldService.java:83)
                          at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
                          at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
                          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [rt.jar:1.7.0]
                          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [rt.jar:1.7.0]
                          at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0]
          
          

          Thanks in advance,
          Christian

          Show
          Christian Müller added a comment - - edited We have issues running Shiro inside of JBoss 7. Anything we can do to get this (one year old) patch applied? Anybody faced the same issue and found a workaround? Our stack trace (using Shiro 1.2.1): 14:56:08,519 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-4) MSC00001: Failed to start service jboss.deployment.unit."xxx-gui.war".WeldService: org.jboss.msc.service.StartException in service jboss.deployment.unit."xxx-gui.war".WeldService: org.jboss.weld.exceptions.UnproxyableResolutionException: WELD-001437 Normal scoped bean class org.apache.shiro.realm.AuthenticatingRealm is not proxyable because the type is final or it contains a final method public final void org.apache.shiro.realm.AuthenticatingRealm.init() - Managed Bean [class net.atos.xa.rm.app.realm.RMRealm] with qualifiers [@Any @Default]. at org.jboss.as.weld.services.WeldService.start(WeldService.java:83) at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA.jar:1.0.2.GA] at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA.jar:1.0.2.GA] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [rt.jar:1.7.0] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [rt.jar:1.7.0] at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0] Thanks in advance, Christian
          Hide
          Thibault Tigeon added a comment -

          Would it be possible to have this patch in the next release?

          Show
          Thibault Tigeon added a comment - Would it be possible to have this patch in the next release?
          Hide
          Romain Manni-Bucau added a comment -

          deltaspike will be great but doing a single module based on deltaspike means each application using cdi + shiro will need deltaspike which could not be the case (even if in JEE projects it will (almost always) be )

          i think both modules can make sense

          tought?

          Show
          Romain Manni-Bucau added a comment - deltaspike will be great but doing a single module based on deltaspike means each application using cdi + shiro will need deltaspike which could not be the case (even if in JEE projects it will (almost always) be ) i think both modules can make sense tought?
          Hide
          Jason Porter added a comment -

          Something that may be interesting for all parties is Shiro integration with DeltaSpike: https://cwiki.apache.org/confluence/display/DeltaSpike/Index Of course basic CDI integration within Shiro would be awesome and probably help in creating a full blown module within DeltaSpike.

          Show
          Jason Porter added a comment - Something that may be interesting for all parties is Shiro integration with DeltaSpike: https://cwiki.apache.org/confluence/display/DeltaSpike/Index Of course basic CDI integration within Shiro would be awesome and probably help in creating a full blown module within DeltaSpike.
          Hide
          Romain Manni-Bucau added a comment -

          an update which manage in a better way exception handling

          Show
          Romain Manni-Bucau added a comment - an update which manage in a better way exception handling
          Hide
          Thibault Tigeon added a comment -

          +1

          Show
          Thibault Tigeon added a comment - +1
          Hide
          Romain Manni-Bucau added a comment -

          a patch proposal

          Show
          Romain Manni-Bucau added a comment - a patch proposal

            People

            • Assignee:
              Unassigned
              Reporter:
              Romain Manni-Bucau
            • Votes:
              20 Vote for this issue
              Watchers:
              22 Start watching this issue

              Dates

              • Created:
                Updated:

                Development