Hi there,

Having found the need to be able to configure JAAS for my Camel Jetty
component I made some changes on my system to JettyHttpComponent and
JettyHttpEndpoint. These changes allow you to submit a Jetty Handler e.g. a
security handler by referring to a handler bean in the Jetty URI e.g.:


        jetty:http://0.0.0.0:9080/MyService?handlers=securityHandler


In my spring config, securityHandler is then defined as:


        <!-- Jetty Security handling -->
        <bean id="userRealm"
class="org.mortbay.jetty.plus.jaas.JAASUserRealm">
                <property name="name" value="tracker-users" />
                <property name="loginModuleName" value="ldaploginmodule" 
/>
                <property name="roleClassNames"
value="com.classactionpl.jaas.UserGroup" />
        </bean>
        <bean id="constraint" 
class="org.mortbay.jetty.security.Constraint">
                <property name="name" value="BASIC" />
                <property name="roles" value="tracker-users" />
                <property name="authenticate" value="true" />
        </bean>
        <bean id="constraintMapping"
class="org.mortbay.jetty.security.ConstraintMapping">
                <property name="constraint" ref="constraint" />
                <property name="pathSpec" value="/*" />
        </bean>
        <bean id="securityHandler"
class="org.mortbay.jetty.security.SecurityHandler">
                <property name="userRealm" ref="userRealm" />
                <property name="constraintMappings" ref="constraintMapping" 
/>
        </bean>


Would there be general interest in this capability? If so then I'm happy to
raise a JIRA and contribute the code. I've actually got everything above
working.

Kind regards,
Christopher
-- 
View this message in context: 
http://www.nabble.com/HTTPS---help-required-tp20932280p23270820.html
Sent from the Camel - Users (activemq) mailing list archive at Nabble.com.

Reply via email to