Monday, April 04, 2011

NextReports Server - Single Sign On

NextReports Server allows integration with all your applications through Single Sign On using CAS.

To make this possible, NextReports defines a process which first brings the users into the content repository. A simple xml configuration will define synchronization process. You must specify your data source and your queries to get users names and users attributes (which allows to map any fields you may have to NextServer repository):
<bean id="syncService" class="com.asf.nextserver.security.DatabaseExternalUsersService">
        <property name="dataSource" ref="syncDataSource"/>
        <property name="userNamesQuery">
            <value>SELECT USER_NAME FROM USERS</value>          
        </property>       
        <property name="userQuery">
            <value>SELECT * FROM USERS WHERE USER_NAME = ?</value>
        </property>
        <property name="mapping">
            <map>
                <!--  required -->
                <entry key="user.username" value="USER_NAME"/>
                .......
            </map>
        </property>
</bean> 

To define your CAS , a validation ticket must be written which will inform about cas login and cas logout urls:
<bean id="tValidator" class="com.asf.nextserver.web.security.cas.CasServiceTicketValidator">
        <constructor-arg index="0" value="https://myurl:myport/cas"/>
        <property name="loginUrl" value="https://myurl:myport/cas/login"/>
        <property name="logoutUrl" value="https://myurl:myport/cas/logout"/>
</bean> 

No comments: