Jump to content

External Authntication


yashdeep

Recommended Posts

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Yash,

 

I'm trying to do the same thing with the open source version.  My understanding (so far) is that you will need to implement the interface UserAuthorityService in order to provide authentication against your own database tables.  Can anyone more knowledgeable than I confirm/deny this?  Anyway,  I'll keep you posted as I make progress.

 

-LeoD

Link to comment
Share on other sites

In looking into this issue. I think you can use the spring securities 'userDetailService' that can authenticate users against a jdbc datasource. Using this you would not be required to implement your own userauthority. As soon as I get this working I will post my configuration here for review.

 

BTW) the link to spring securities authentication services is here:

 

http://static.springframework.org/spring-security/site/reference/html/authentication-common-auth-services.html

Link to comment
Share on other sites

  • 2 months later...

I got this to work by modifying applicationContext-security.xml. I have added the contents of this file here in hopes that it helps someone else out:

 

<?xml version="1.0" encoding="UTF-8"?>

 

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xmlns:util="http://www.springframework.org/schema/util"

xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd

http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-2.0.xsd">

 

CONVERT_URL_TO_LOWERCASE_BEFORE_COMPARISON

PATTERN_TYPE_APACHE_ANT

/xmla=httpSessionContextIntegrationFilter,basicProcessingFilter,JIAuthenticationSynchronizer,anonymousProcessingFilter,basicAuthExceptionTranslationFilter,filterInvocationInterceptor

/services/**=httpSessionContextIntegrationFilter,portletAuthenticationProcessingFilter,basicProcessingFilter,passwordExpirationProcessingFilter,JIAuthenticationSynchronizer,anonymousProcessingFilter,basicAuthExceptionTranslationFilter,filterInvocationInterceptor

/**=httpSessionContextIntegrationFilter,userPreferencesFilter,authenticationProcessingFilter,userPreferencesFilter,basicProcessingFilter,requestParameterAuthenticationFilter,JIAuthenticationSynchronizer,anonymousProcessingFilter,exceptionTranslationFilter,filterInvocationInterceptor,switchUserProcessingFilter

 

 

 

 

false

false

0xC8 0x43 0x29 0x49 0xAE 0x25 0x2F 0xA1 0xC1 0xF2 0xC8 0xD9 0x31 0x01 0x2C 0x52 0x54 0x0B 0x5E 0xEA 0x9E 0x37 0xA8 0x61

DESede

DESede/CBC/PKCS5Padding

 

Select userName as login, password,enabled=1 FROM tblUser WHERE userName=?

SELECT login,authority,enabled=1 FROM authorities WHERE login = ?

foobar

anonymousUser,ROLE_ANONYMOUS

 

foobar

 

 

 

 

 

 

 

 

en

fr

it

de

ro

ja

zh_TW

 

86400

 

 

 

 

 

 

Protected Area

 

 

/login.html?error=1

/loginsuccess.html

/j_acegi_security_check

 

/loginerror.html

/j_acegi_switch_user

 

/login.html

false

 

 

 

false

 

 

 

 

CONVERT_URL_TO_LOWERCASE_BEFORE_COMPARISON

PATTERN_TYPE_APACHE_ANT

/login.html=ROLE_ANONYMOUS,ROLE_USER,ROLE_ADMINISTRATOR

/logout.html=ROLE_ANONYMOUS,ROLE_USER,ROLE_ADMINISTRATOR,IS_AUTHENTICATED_FULLY

/loginerror.html=ROLE_ANONYMOUS,ROLE_USER,ROLE_ADMINISTRATOR

/exituser.html=ROLE_ANONYMOUS,ROLE_USER,ROLE_ADMINISTRATOR,IS_AUTHENTICATED_FULLY

/home.html=ROLE_USER,ROLE_ADMINISTRATOR

/flow.html=ROLE_USER,ROLE_ADMINISTRATOR

/loginsuccess.html=ROLE_USER,ROLE_ADMINISTRATOR

/listolapviews.html=ROLE_USER,ROLE_ADMINISTRATOR

/fillparams.html=ROLE_USER,ROLE_ADMINISTRATOR

/j_acegi_switch_user*=ROLE_ADMINISTRATOR

/fileview/**=ROLE_USER,ROLE_ADMINISTRATOR

/olap/**=ROLE_USER,ROLE_ADMINISTRATOR

/xmla=ROLE_USER,ROLE_ADMINISTRATOR

/services/**=ROLE_USER,ROLE_ADMINISTRATOR

/reportimage/**=ROLE_USER,ROLE_ADMINISTRATOR

/jrpxml/**=ROLE_USER,ROLE_ADMINISTRATOR

 

 

/*.html=ROLE_ADMINISTRATOR

/*.jsp=ROLE_ADMINISTRATOR

 

 

class="org.acegisecurity.ui.switchuser.SwitchUserProcessingFilter">

/j_acegi_switch_user

/j_acegi_exit_user

/home.html

 

 

org.acegisecurity.acl.basic.SimpleAclEntry.ADMINISTRATION

 

org.acegisecurity.acl.basic.SimpleAclEntry.READ_WRITE

 

org.acegisecurity.acl.basic.SimpleAclEntry.READ

 

org.acegisecurity.acl.basic.SimpleAclEntry.DELETE

 

ACL_USER_ADMIN

com.jaspersoft.jasperserver.api.metadata.common.domain.Resource

 

ACL_USER_READ

java.lang.String

 

ACL_USER_UPDATE

com.jaspersoft.jasperserver.api.metadata.common.domain.Resource

 

ACL_USER_DELETE

java.lang.String

 

 

true

 

 

 

 

class="org.acegisecurity.intercept.method.aopalliance.MethodSecurityInterceptor">

 

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.getResource=ACL_USER_READ

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.getFolder=ACL_USER_READ

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.loadResourcesList=AFTER_ACL_COLLECTION_READ

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.loadClientResources=AFTER_ACL_COLLECTION_READ

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.getAllFolders=AFTER_ACL_COLLECTION_READ

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.getSubFolders=AFTER_ACL_COLLECTION_READ

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.saveFolder=ACL_USER_ADMIN,ACL_USER_UPDATE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.saveResource=ACL_USER_ADMIN,ACL_USER_UPDATE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.deleteResource=ACL_USER_DELETE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.deleteFolder=ACL_USER_DELETE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.delete=ACL_USER_DELETE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.moveFolder=ACL_USER_MOVE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.moveResource=ACL_USER_MOVE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.copyResource=ACL_USER_COPY

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.copyFolder=ACL_USER_COPY

 

 

 

 

 

 

class="org.acegisecurity.afterinvocation.BasicAclEntryAfterInvocationCollectionFilteringProvider">

 

 

 

AFTER_ACL_COLLECTION_UPDATE

 

 

 

 

repoAdminFlow=ROLE_ADMINISTRATOR

userListFlow=ROLE_ADMINISTRATOR

roleListFlow=ROLE_ADMINISTRATOR

reportUnitFlow=ROLE_ADMINISTRATOR

olapUnitFlow=ROLE_ADMINISTRATOR

olapClientConnectionFlow=ROLE_ADMINISTRATOR

mondrianXmlaSourceFlow=ROLE_ADMINISTRATOR

editFolderFlow=ROLE_ADMINISTRATOR

fileResourceFlow=ROLE_ADMINISTRATOR

dataTypeFlow=ROLE_ADMINISTRATOR

listOfValuesFlow=ROLE_ADMINISTRATOR

queryFlow=ROLE_ADMINISTRATOR

reportDataSourceFlow=ROLE_ADMINISTRATOR

inputControlsFlow=ROLE_ADMINISTRATOR

objectPermissionToRoleFlow=ROLE_ADMINISTRATOR

userEditFlow=ROLE_ADMINISTRATOR

roleEditFlow=ROLE_ADMINISTRATOR

queryReferenceFlow=ROLE_ADMINISTRATOR

objectPermissionToUserFlow=ROLE_ADMINISTRATOR

repositoryExplorerFlow=ROLE_USER,ROLE_ADMINISTRATOR

*=ROLE_USER,ROLE_ADMINISTRATOR

 

true

 

org.springframework.webflow.executor.FlowExecutor.launch=FLOW_ACCESS

 

class="com.jaspersoft.jasperserver.api.metadata.user.service.impl.CheckMethodSecurityInterceptor">

 

 

 

 

class="org.springframework.aop.framework.ProxyFactoryBean">

com.jaspersoft.jasperserver.api.metadata.common.service.impl.hibernate.HibernateRepositoryService

 

class="com.jaspersoft.jasperserver.api.metadata.common.service.impl.RepositoryServiceSecurityChecker">

 

class="org.acegisecurity.intercept.method.aopalliance.MethodSecurityInterceptor">

 

 

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.getResource=ACL_USER_UPDATE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.getFolder=ACL_USER_UPDATE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.loadResourcesList=AFTER_ACL_COLLECTION_UPDATE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.loadClientResources=AFTER_ACL_COLLECTION_UPDATE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.getAllFolders=AFTER_ACL_COLLECTION_UPDATE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.getSubFolders=AFTER_ACL_COLLECTION_UPDATE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.saveFolder=ACL_USER_UPDATE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.saveResource=ACL_USER_UPDATE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.deleteResource=ACL_USER_DELETE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.deleteFolder=ACL_USER_DELETE

com.jaspersoft.jasperserver.api.metadata.common.service.RepositoryService.delete=ACL_USER_DELETE

 

class="org.springframework.aop.framework.ProxyFactoryBean">

com.jaspersoft.jasperserver.api.metadata.common.service.impl.hibernate.HibernateRepositoryService

 

 

 

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...