Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » scout » Rap login problem(Rap and DataSourceSecurityFilter)
Rap login problem [message #1354439] Wed, 14 May 2014 04:56 Go to next message
Bertin Kiekebosch is currently offline Bertin Kiekebosch
Messages: 300
Registered: August 2011
Senior Member
Hi,

I have an Scout (Kepler sr2) appllication with an SWT client. It uses DataSourceSecurityFilter for authorisation and that works fine.

Now they asked me to make it available through the web so I want to use RAP client for this but I cannot make the security work. I tried every hint I could find in the forum and in the documentation but it does not work.

When I start the app, I get an Login Dialog. (One from the browser, not from RAP) When correct credentials are entered I get an error.

Any ideas?


Browser error message:
HTTP ERROR: 500

Problem accessing /web. Reason:

    Server Error


Logging from my Eclipse Console:
!ENTRY org.eclipse.scout.rt.ui.rap 4 0 2014-05-14 10:31:59.869
!MESSAGE org.eclipse.scout.rt.ui.rap.login.internal.InternalNetAuthenticator.getPasswordAuthentication(InternalNetAuthenticator.java:74) http://localhost:8080/scarabee/ajax
!STACK 0
java.lang.NullPointerException
	at org.eclipse.scout.rt.ui.rap.login.internal.InternalNetAuthenticator.showModalDialog(InternalNetAuthenticator.java:102)
	at org.eclipse.scout.rt.ui.rap.login.internal.InternalNetAuthenticator.getPasswordAuthentication(InternalNetAuthenticator.java:71)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.scout.net.internal.InternalEclipseAuthenticator.reflectPasswordAuthentication(InternalEclipseAuthenticator.java:77)
	at org.eclipse.scout.net.internal.InternalEclipseAuthenticator.getPasswordAuthentication(InternalEclipseAuthenticator.java:44)
	at org.eclipse.scout.net.EclipseAuthenticator.getPasswordAuthentication(EclipseAuthenticator.java:31)
	at java.net.Authenticator.requestPasswordAuthentication(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection$1.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at sun.net.www.protocol.http.HttpURLConnection.privilegedRequestPasswordAuthentication(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection.getServerAuthentication(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
	at java.net.HttpURLConnection.getResponseCode(Unknown Source)
	at org.eclipse.scout.rt.client.servicetunnel.http.internal.HttpBackgroundJob.runStatus(HttpBackgroundJob.java:79)
	at org.eclipse.scout.rt.client.ClientJob.runTransactionWrapper(ClientJob.java:172)
	at org.eclipse.scout.rt.client.ClientJob.run(ClientJob.java:159)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)

!ENTRY org.eclipse.scout.rt.client 4 0 2014-05-14 10:31:59.869
!MESSAGE org.eclipse.scout.rt.client.AbstractClientSession.startSession(AbstractClientSession.java:264) load session
!STACK 0
java.lang.reflect.UndeclaredThrowableException
	at $Proxy9.getAllCodeTypeClasses(Unknown Source)
	at org.eclipse.scout.rt.client.services.common.code.CodeServiceClientProxy.getAllCodeTypeClasses(CodeServiceClientProxy.java:342)
	at org.eclipse.scout.rt.client.services.common.code.CodeServiceClientProxy.getAllCodeTypes(CodeServiceClientProxy.java:363)
	at org.eclipse.scout.rt.shared.services.common.code.CODES.getAllCodeTypes(CODES.java:64)
	at nl.rid.scarabee.client.ClientSession.execLoadSession(ClientSession.java:48)
	at org.eclipse.scout.rt.client.AbstractClientSession.startSession(AbstractClientSession.java:259)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService$1.runVoid(ClientSessionRegistryService.java:64)
	at org.eclipse.scout.rt.client.ClientJob.runStatus(ClientJob.java:189)
	at org.eclipse.scout.rt.client.ClientJob.runTransactionWrapper(ClientJob.java:172)
	at org.eclipse.scout.rt.client.ClientJob.run(ClientJob.java:159)
	at org.eclipse.scout.commons.job.JobEx.runNow(JobEx.java:50)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService.createAndStartClientSession(ClientSessionRegistryService.java:68)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService.newClientSession(ClientSessionRegistryService.java:49)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.init(AbstractRwtEnvironment.java:341)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.ensureInitialized(AbstractRwtEnvironment.java:289)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createApplicationContent(AbstractStandaloneRwtEnvironment.java:158)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createUI(AbstractStandaloneRwtEnvironment.java:107)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.createUI(RWTLifeCycle.java:177)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle$UIThreadController.run(RWTLifeCycle.java:289)
	at java.lang.Thread.run(Unknown Source)
	at org.eclipse.rwt.internal.lifecycle.UIThread.run(UIThread.java:102)
Caused by: ProcessingException[ProcessingStatus[ERROR code=0 Calling ICodeService.getAllCodeTypeClasses() org.eclipse.scout.rt.shared.servicetunnel.HttpException: 401 - UNAUTHORIZED]]
	at org.eclipse.scout.rt.client.servicetunnel.AbstractServiceTunnel.invokeService(AbstractServiceTunnel.java:163)
	at org.eclipse.scout.rt.client.servicetunnel.http.internal.InternalHttpServiceTunnel.invokeService(InternalHttpServiceTunnel.java:175)
	at org.eclipse.scout.rt.client.servicetunnel.http.HttpServiceTunnel.invokeService(HttpServiceTunnel.java:115)
	at org.eclipse.scout.rt.client.servicetunnel.ServiceTunnelInvocationHandler.invoke(ServiceTunnelInvocationHandler.java:47)
	at $Proxy9.getAllCodeTypeClasses(Unknown Source)
	at org.eclipse.scout.rt.client.services.common.code.CodeServiceClientProxy.getAllCodeTypeClasses(CodeServiceClientProxy.java:342)
	at org.eclipse.scout.rt.client.services.common.code.CodeServiceClientProxy.getAllCodeTypes(CodeServiceClientProxy.java:363)
	at org.eclipse.scout.rt.shared.services.common.code.CODES.getAllCodeTypes(CODES.java:64)
	at nl.rid.scarabee.client.ClientSession.execLoadSession(ClientSession.java:48)
	at org.eclipse.scout.rt.client.AbstractClientSession.startSession(AbstractClientSession.java:259)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService$1.runVoid(ClientSessionRegistryService.java:64)
	at org.eclipse.scout.rt.client.ClientJob.runStatus(ClientJob.java:189)
	at org.eclipse.scout.rt.client.ClientJob.runTransactionWrapper(ClientJob.java:172)
	at org.eclipse.scout.rt.client.ClientJob.run(ClientJob.java:159)
	at org.eclipse.scout.commons.job.JobEx.runNow(JobEx.java:50)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService.createAndStartClientSession(ClientSessionRegistryService.java:68)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService.newClientSession(ClientSessionRegistryService.java:49)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.init(AbstractRwtEnvironment.java:341)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.ensureInitialized(AbstractRwtEnvironment.java:289)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createApplicationContent(AbstractStandaloneRwtEnvironment.java:158)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createUI(AbstractStandaloneRwtEnvironment.java:107)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.createUI(RWTLifeCycle.java:177)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle$UIThreadController.run(RWTLifeCycle.java:289)
	at java.lang.Thread.run(Unknown Source)
	at org.eclipse.rwt.internal.lifecycle.UIThread.run(UIThread.java:102)
	at org.eclipse.scout.rt.client.servicetunnel.AbstractServiceTunnel.invokeService(AbstractServiceTunnel.java:167)
	at org.eclipse.scout.rt.client.servicetunnel.http.internal.InternalHttpServiceTunnel.invokeService(InternalHttpServiceTunnel.java:175)
	at org.eclipse.scout.rt.client.servicetunnel.http.HttpServiceTunnel.invokeService(HttpServiceTunnel.java:115)
	at org.eclipse.scout.rt.client.servicetunnel.ServiceTunnelInvocationHandler.invoke(ServiceTunnelInvocationHandler.java:47)
	... 21 more
Caused by: org.eclipse.scout.rt.shared.servicetunnel.HttpException: 401 - UNAUTHORIZED
	at org.eclipse.scout.rt.client.servicetunnel.http.internal.HttpBackgroundJob.runStatus(HttpBackgroundJob.java:85)
	at org.eclipse.scout.rt.client.ClientJob.runTransactionWrapper(ClientJob.java:172)
	at org.eclipse.scout.rt.client.ClientJob.run(ClientJob.java:159)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)

!ENTRY org.eclipse.scout.rt.ui.rap 4 0 2014-05-14 10:31:59.885
!MESSAGE org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.ensureInitialized(AbstractRwtEnvironment.java:292) could not initialize Environment
!STACK 0
java.lang.NullPointerException
	at org.eclipse.ui.internal.Workbench.getWorkbenchWindows(Workbench.java:1512)
	at org.eclipse.scout.rt.ui.rap.util.RwtUtility.getParentShellIgnoringPopups(RwtUtility.java:1618)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.getParentShellIgnoringPopups(AbstractRwtEnvironment.java:1291)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.showClientSessionLoadError(AbstractRwtEnvironment.java:430)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.init(AbstractRwtEnvironment.java:352)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.ensureInitialized(AbstractRwtEnvironment.java:289)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createApplicationContent(AbstractStandaloneRwtEnvironment.java:158)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createUI(AbstractStandaloneRwtEnvironment.java:107)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.createUI(RWTLifeCycle.java:177)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle$UIThreadController.run(RWTLifeCycle.java:289)
	at java.lang.Thread.run(Unknown Source)
	at org.eclipse.rwt.internal.lifecycle.UIThread.run(UIThread.java:102)
2014-05-14 10:31:59.885:WARN:oejs.ServletHandler:ERROR:  /web
java.lang.SecurityException: Cannot initialize application
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createApplicationContent(AbstractStandaloneRwtEnvironment.java:160)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createUI(AbstractStandaloneRwtEnvironment.java:107)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.createUI(RWTLifeCycle.java:177)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle$UIThreadController.run(RWTLifeCycle.java:289)
	at java.lang.Thread.run(Unknown Source)
	at org.eclipse.rwt.internal.lifecycle.UIThread.run(UIThread.java:102)

!ENTRY org.eclipse.scout.commons 2 0 2014-05-14 10:40:13.158
!MESSAGE org.eclipse.scout.commons.serialization.SerializationUtility.getBundleOrderPrefixes(SerializationUtility.java:123) bundle order prefixes are neither defined in config.ini nor as a system property. Using default value: org.eclipse.scout.commons.serialization.bundleOrderPrefixes=nl.rid.scarabee.,org.eclipse.scout

!ENTRY org.eclipse.scout.rt.ui.rap 4 0 2014-05-14 10:40:13.159
!MESSAGE org.eclipse.scout.rt.ui.rap.login.internal.InternalNetAuthenticator.getPasswordAuthentication(InternalNetAuthenticator.java:74) http://localhost:8080/scarabee/ajax
!STACK 0
java.lang.NullPointerException
	at org.eclipse.scout.rt.ui.rap.login.internal.InternalNetAuthenticator.showModalDialog(InternalNetAuthenticator.java:102)
	at org.eclipse.scout.rt.ui.rap.login.internal.InternalNetAuthenticator.getPasswordAuthentication(InternalNetAuthenticator.java:71)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.scout.net.internal.InternalEclipseAuthenticator.reflectPasswordAuthentication(InternalEclipseAuthenticator.java:77)
	at org.eclipse.scout.net.internal.InternalEclipseAuthenticator.getPasswordAuthentication(InternalEclipseAuthenticator.java:44)
	at org.eclipse.scout.net.EclipseAuthenticator.getPasswordAuthentication(EclipseAuthenticator.java:31)
	at java.net.Authenticator.requestPasswordAuthentication(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection$1.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at sun.net.www.protocol.http.HttpURLConnection.privilegedRequestPasswordAuthentication(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection.getServerAuthentication(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
	at java.net.HttpURLConnection.getResponseCode(Unknown Source)
	at org.eclipse.scout.rt.client.servicetunnel.http.internal.HttpBackgroundJob.runStatus(HttpBackgroundJob.java:79)
	at org.eclipse.scout.rt.client.ClientJob.runTransactionWrapper(ClientJob.java:172)
	at org.eclipse.scout.rt.client.ClientJob.run(ClientJob.java:159)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)

!ENTRY org.eclipse.scout.rt.client 4 0 2014-05-14 10:40:13.159
!MESSAGE org.eclipse.scout.rt.client.AbstractClientSession.startSession(AbstractClientSession.java:264) load session
!STACK 0
java.lang.reflect.UndeclaredThrowableException
	at $Proxy9.getAllCodeTypeClasses(Unknown Source)
	at org.eclipse.scout.rt.client.services.common.code.CodeServiceClientProxy.getAllCodeTypeClasses(CodeServiceClientProxy.java:342)
	at org.eclipse.scout.rt.client.services.common.code.CodeServiceClientProxy.getAllCodeTypes(CodeServiceClientProxy.java:363)
	at org.eclipse.scout.rt.shared.services.common.code.CODES.getAllCodeTypes(CODES.java:64)
	at nl.rid.scarabee.client.ClientSession.execLoadSession(ClientSession.java:48)
	at org.eclipse.scout.rt.client.AbstractClientSession.startSession(AbstractClientSession.java:259)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService$1.runVoid(ClientSessionRegistryService.java:64)
	at org.eclipse.scout.rt.client.ClientJob.runStatus(ClientJob.java:189)
	at org.eclipse.scout.rt.client.ClientJob.runTransactionWrapper(ClientJob.java:172)
	at org.eclipse.scout.rt.client.ClientJob.run(ClientJob.java:159)
	at org.eclipse.scout.commons.job.JobEx.runNow(JobEx.java:50)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService.createAndStartClientSession(ClientSessionRegistryService.java:68)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService.newClientSession(ClientSessionRegistryService.java:49)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.init(AbstractRwtEnvironment.java:341)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.ensureInitialized(AbstractRwtEnvironment.java:289)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createApplicationContent(AbstractStandaloneRwtEnvironment.java:158)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createUI(AbstractStandaloneRwtEnvironment.java:107)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.createUI(RWTLifeCycle.java:177)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle$UIThreadController.run(RWTLifeCycle.java:289)
	at java.lang.Thread.run(Unknown Source)
	at org.eclipse.rwt.internal.lifecycle.UIThread.run(UIThread.java:102)
Caused by: ProcessingException[ProcessingStatus[ERROR code=0 Calling ICodeService.getAllCodeTypeClasses() org.eclipse.scout.rt.shared.servicetunnel.HttpException: 401 - UNAUTHORIZED]]
	at org.eclipse.scout.rt.client.servicetunnel.AbstractServiceTunnel.invokeService(AbstractServiceTunnel.java:163)
	at org.eclipse.scout.rt.client.servicetunnel.http.internal.InternalHttpServiceTunnel.invokeService(InternalHttpServiceTunnel.java:175)
	at org.eclipse.scout.rt.client.servicetunnel.http.HttpServiceTunnel.invokeService(HttpServiceTunnel.java:115)
	at org.eclipse.scout.rt.client.servicetunnel.ServiceTunnelInvocationHandler.invoke(ServiceTunnelInvocationHandler.java:47)
	at $Proxy9.getAllCodeTypeClasses(Unknown Source)
	at org.eclipse.scout.rt.client.services.common.code.CodeServiceClientProxy.getAllCodeTypeClasses(CodeServiceClientProxy.java:342)
	at org.eclipse.scout.rt.client.services.common.code.CodeServiceClientProxy.getAllCodeTypes(CodeServiceClientProxy.java:363)
	at org.eclipse.scout.rt.shared.services.common.code.CODES.getAllCodeTypes(CODES.java:64)
	at nl.rid.scarabee.client.ClientSession.execLoadSession(ClientSession.java:48)
	at org.eclipse.scout.rt.client.AbstractClientSession.startSession(AbstractClientSession.java:259)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService$1.runVoid(ClientSessionRegistryService.java:64)
	at org.eclipse.scout.rt.client.ClientJob.runStatus(ClientJob.java:189)
	at org.eclipse.scout.rt.client.ClientJob.runTransactionWrapper(ClientJob.java:172)
	at org.eclipse.scout.rt.client.ClientJob.run(ClientJob.java:159)
	at org.eclipse.scout.commons.job.JobEx.runNow(JobEx.java:50)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService.createAndStartClientSession(ClientSessionRegistryService.java:68)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService.newClientSession(ClientSessionRegistryService.java:49)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.init(AbstractRwtEnvironment.java:341)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.ensureInitialized(AbstractRwtEnvironment.java:289)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createApplicationContent(AbstractStandaloneRwtEnvironment.java:158)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createUI(AbstractStandaloneRwtEnvironment.java:107)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.createUI(RWTLifeCycle.java:177)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle$UIThreadController.run(RWTLifeCycle.java:289)
	at java.lang.Thread.run(Unknown Source)
	at org.eclipse.rwt.internal.lifecycle.UIThread.run(UIThread.java:102)
	at org.eclipse.scout.rt.client.servicetunnel.AbstractServiceTunnel.invokeService(AbstractServiceTunnel.java:167)
	at org.eclipse.scout.rt.client.servicetunnel.http.internal.InternalHttpServiceTunnel.invokeService(InternalHttpServiceTunnel.java:175)
	at org.eclipse.scout.rt.client.servicetunnel.http.HttpServiceTunnel.invokeService(HttpServiceTunnel.java:115)
	at org.eclipse.scout.rt.client.servicetunnel.ServiceTunnelInvocationHandler.invoke(ServiceTunnelInvocationHandler.java:47)
	... 21 more
Caused by: org.eclipse.scout.rt.shared.servicetunnel.HttpException: 401 - UNAUTHORIZED
	at org.eclipse.scout.rt.client.servicetunnel.http.internal.HttpBackgroundJob.runStatus(HttpBackgroundJob.java:85)
	at org.eclipse.scout.rt.client.ClientJob.runTransactionWrapper(ClientJob.java:172)
	at org.eclipse.scout.rt.client.ClientJob.run(ClientJob.java:159)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)

!ENTRY org.eclipse.scout.rt.ui.rap 4 0 2014-05-14 10:40:13.191
!MESSAGE org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.ensureInitialized(AbstractRwtEnvironment.java:292) could not initialize Environment
!STACK 0
java.lang.NullPointerException
	at org.eclipse.ui.internal.Workbench.getWorkbenchWindows(Workbench.java:1512)
	at org.eclipse.scout.rt.ui.rap.util.RwtUtility.getParentShellIgnoringPopups(RwtUtility.java:1618)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.getParentShellIgnoringPopups(AbstractRwtEnvironment.java:1291)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.showClientSessionLoadError(AbstractRwtEnvironment.java:430)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.init(AbstractRwtEnvironment.java:352)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.ensureInitialized(AbstractRwtEnvironment.java:289)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createApplicationContent(AbstractStandaloneRwtEnvironment.java:158)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createUI(AbstractStandaloneRwtEnvironment.java:107)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.createUI(RWTLifeCycle.java:177)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle$UIThreadController.run(RWTLifeCycle.java:289)
	at java.lang.Thread.run(Unknown Source)
	at org.eclipse.rwt.internal.lifecycle.UIThread.run(UIThread.java:102)
2014-05-14 10:40:13.191:WARN:oejs.ServletHandler:ERROR:  /web
java.lang.SecurityException: Cannot initialize application
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createApplicationContent(AbstractStandaloneRwtEnvironment.java:160)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createUI(AbstractStandaloneRwtEnvironment.java:107)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.createUI(RWTLifeCycle.java:177)
	at org.eclipse.rwt.internal.lifecycle.RWTLifeCycle$UIThreadController.run(RWTLifeCycle.java:289)
	at java.lang.Thread.run(Unknown Source)
	at org.eclipse.rwt.internal.lifecycle.UIThread.run(UIThread.java:102)


Re: Rap login problem [message #1383810 is a reply to message #1354439] Mon, 26 May 2014 10:51 Go to previous messageGo to next message
Chris Thoma is currently offline Chris Thoma
Messages: 2
Registered: April 2014
Junior Member
Hi,
I don't know if you have already configured this, but this was a point I struggled some weeks ago.
Did you change the config.ini of the RAP configuration? Because you have to add there the same credential as in the SWT config.ini for DataSourceSecurity.
Also you have to plugin.xml. For me the following configuration worked.
<extension point="org.eclipse.scout.http.servletfilter.filters">
    <filter
      aliases="/"
      class="org.eclipse.scout.http.servletfilter.security.AnonymousSecurityFilter"
      ranking="50">
    </filter>
    <filter
      aliases="/web"
      class="org.eclipse.scout.http.servletfilter.security.BasicSecurityFilter"
      ranking="40">
    </filter>
    <filter
      aliases="/process"
      class="org.eclipse.scout.http.servletfilter.security.DataSourceSecurityFilter"
      ranking="30">
    </filter>
    <filter
      aliases="/web"
      class="org.eclipse.scout.http.servletfilter.security.DataSourceSecurityFilter"
      ranking="20">
    </filter>
     <filter
      aliases="/"
      class="org.eclipse.scout.http.servletfilter.security.DataSourceSecurityFilter"
      ranking="10">
    </filter>


Regards Chris
Re: Rap login problem [message #1391113 is a reply to message #1383810] Mon, 30 June 2014 09:14 Go to previous messageGo to next message
Bertin Kiekebosch is currently offline Bertin Kiekebosch
Messages: 300
Registered: August 2011
Senior Member
Hi, still did not solve the issue.

To validate my eclipse (Kepler SR2) environment, I created a new project and only implemented the security. That works OK with a dataSourceSecurityFilter (Server, Swing client and RAP client).

The project I have the problem with is a project that is initailly created with an older version of Eclipes Scout (could be Indigo or Juno). I ran through all the configurations , target definitions etc. but I cannot find any difference. Maybe someone has another hint?

!ENTRY org.eclipse.scout.rt.client 4 0 2014-06-30 15:01:29.462
!MESSAGE org.eclipse.scout.rt.client.AbstractClientSession.startSession(AbstractClientSession.java:264) load session
!STACK 0
java.lang.reflect.UndeclaredThrowableException
	at $Proxy9.getAllCodeTypeClasses(Unknown Source)
	at org.eclipse.scout.rt.client.services.common.code.CodeServiceClientProxy.getAllCodeTypeClasses(CodeServiceClientProxy.java:342)
	at org.eclipse.scout.rt.client.services.common.code.CodeServiceClientProxy.getAllCodeTypes(CodeServiceClientProxy.java:363)
	at org.eclipse.scout.rt.shared.services.common.code.CODES.getAllCodeTypes(CODES.java:64)
	at nl.rid.scarabee.client.ClientSession.execLoadSession(ClientSession.java:48)
	at org.eclipse.scout.rt.client.AbstractClientSession.startSession(AbstractClientSession.java:259)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService$1.runVoid(ClientSessionRegistryService.java:64)
	at org.eclipse.scout.rt.client.ClientJob.runStatus(ClientJob.java:189)
	at org.eclipse.scout.rt.client.ClientJob.runTransactionWrapper(ClientJob.java:172)
	at org.eclipse.scout.rt.client.ClientJob.run(ClientJob.java:159)
	at org.eclipse.scout.commons.job.JobEx.runNow(JobEx.java:50)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService.createAndStartClientSession(ClientSessionRegistryService.java:68)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService.newClientSession(ClientSessionRegistryService.java:49)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.initClientSession(AbstractRwtEnvironment.java:463)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.init(AbstractRwtEnvironment.java:365)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.ensureInitialized(AbstractRwtEnvironment.java:319)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createApplicationContent(AbstractStandaloneRwtEnvironment.java:135)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createUI(AbstractStandaloneRwtEnvironment.java:99)
	at org.eclipse.rap.rwt.internal.lifecycle.RWTLifeCycle.createUI(RWTLifeCycle.java:186)
	at org.eclipse.rap.rwt.internal.lifecycle.RWTLifeCycle$UIThreadController.run(RWTLifeCycle.java:298)
	at java.lang.Thread.run(Unknown Source)
	at org.eclipse.rap.rwt.internal.lifecycle.UIThread.run(UIThread.java:104)
Caused by: ProcessingException[ProcessingStatus[ERROR code=0 Calling ICodeService.getAllCodeTypeClasses() org.eclipse.scout.rt.shared.servicetunnel.HttpException: 401 - UNAUTHORIZED]]
	at org.eclipse.scout.rt.client.servicetunnel.AbstractServiceTunnel.invokeService(AbstractServiceTunnel.java:163)
	at org.eclipse.scout.rt.client.servicetunnel.http.internal.InternalHttpServiceTunnel.invokeService(InternalHttpServiceTunnel.java:175)
	at org.eclipse.scout.rt.client.servicetunnel.http.HttpServiceTunnel.invokeService(HttpServiceTunnel.java:115)
	at org.eclipse.scout.rt.client.servicetunnel.ServiceTunnelInvocationHandler.invoke(ServiceTunnelInvocationHandler.java:47)
	at $Proxy9.getAllCodeTypeClasses(Unknown Source)
	at org.eclipse.scout.rt.client.services.common.code.CodeServiceClientProxy.getAllCodeTypeClasses(CodeServiceClientProxy.java:342)
	at org.eclipse.scout.rt.client.services.common.code.CodeServiceClientProxy.getAllCodeTypes(CodeServiceClientProxy.java:363)
	at org.eclipse.scout.rt.shared.services.common.code.CODES.getAllCodeTypes(CODES.java:64)
	at nl.rid.scarabee.client.ClientSession.execLoadSession(ClientSession.java:48)
	at org.eclipse.scout.rt.client.AbstractClientSession.startSession(AbstractClientSession.java:259)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService$1.runVoid(ClientSessionRegistryService.java:64)
	at org.eclipse.scout.rt.client.ClientJob.runStatus(ClientJob.java:189)
	at org.eclipse.scout.rt.client.ClientJob.runTransactionWrapper(ClientJob.java:172)
	at org.eclipse.scout.rt.client.ClientJob.run(ClientJob.java:159)
	at org.eclipse.scout.commons.job.JobEx.runNow(JobEx.java:50)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService.createAndStartClientSession(ClientSessionRegistryService.java:68)
	at org.eclipse.scout.rt.client.services.common.session.internal.ClientSessionRegistryService.newClientSession(ClientSessionRegistryService.java:49)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.initClientSession(AbstractRwtEnvironment.java:463)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.init(AbstractRwtEnvironment.java:365)
	at org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.ensureInitialized(AbstractRwtEnvironment.java:319)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createApplicationContent(AbstractStandaloneRwtEnvironment.java:135)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createUI(AbstractStandaloneRwtEnvironment.java:99)
	at org.eclipse.rap.rwt.internal.lifecycle.RWTLifeCycle.createUI(RWTLifeCycle.java:186)
	at org.eclipse.rap.rwt.internal.lifecycle.RWTLifeCycle$UIThreadController.run(RWTLifeCycle.java:298)
	at java.lang.Thread.run(Unknown Source)
	at org.eclipse.rap.rwt.internal.lifecycle.UIThread.run(UIThread.java:104)
	at org.eclipse.scout.rt.client.servicetunnel.AbstractServiceTunnel.invokeService(AbstractServiceTunnel.java:167)
	at org.eclipse.scout.rt.client.servicetunnel.http.internal.InternalHttpServiceTunnel.invokeService(InternalHttpServiceTunnel.java:175)
	at org.eclipse.scout.rt.client.servicetunnel.http.HttpServiceTunnel.invokeService(HttpServiceTunnel.java:115)
	at org.eclipse.scout.rt.client.servicetunnel.ServiceTunnelInvocationHandler.invoke(ServiceTunnelInvocationHandler.java:47)
	... 22 more
Caused by: org.eclipse.scout.rt.shared.servicetunnel.HttpException: 401 - UNAUTHORIZED
	at org.eclipse.scout.rt.client.servicetunnel.http.internal.HttpBackgroundJob.runStatus(HttpBackgroundJob.java:85)
	at org.eclipse.scout.rt.client.ClientJob.runTransactionWrapper(ClientJob.java:172)
	at org.eclipse.scout.rt.client.ClientJob.run(ClientJob.java:159)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)

!ENTRY org.eclipse.scout.rt.ui.rap 4 0 2014-06-30 15:01:31.444:WARN:oejs.ServletHandler:ERROR:  /web
java.lang.SecurityException: Cannot initialize application
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createApplicationContent(AbstractStandaloneRwtEnvironment.java:142)
	at org.eclipse.scout.rt.ui.rap.AbstractStandaloneRwtEnvironment.createUI(AbstractStandaloneRwtEnvironment.java:99)
	at org.eclipse.rap.rwt.internal.lifecycle.RWTLifeCycle.createUI(RWTLifeCycle.java:186)
	at org.eclipse.rap.rwt.internal.lifecycle.RWTLifeCycle$UIThreadController.run(RWTLifeCycle.java:298)
	at java.lang.Thread.run(Unknown Source)
	at org.eclipse.rap.rwt.internal.lifecycle.UIThread.run(UIThread.java:104)
2014-06-30 15:01:31.429
!MESSAGE org.eclipse.scout.rt.ui.rap.AbstractRwtEnvironment.init(AbstractRwtEnvironment.java:368) ClientSession is not active, there must be a problem with loading or starting

Re: Rap login problem [message #1396076 is a reply to message #1391113] Mon, 07 July 2014 17:09 Go to previous message
Chris Monty is currently offline Chris Monty
Messages: 24
Registered: July 2013
Junior Member
I had similar issues once. My solution may be relevant.

The problem was that the RAP had no alias to the server, and therefore no access. The solution:
    <filter
      aliases="/ /web"
      class="org.eclipse.scout.http.servletfilter.security.BasicSecurityFilter"
      ranking="20">
    </filter>


Hope that's helpful...
Previous Topic:HTTP 404
Next Topic:How can i get the contract in java
Goto Forum:
  


Current Time: Thu Jul 24 04:28:13 EDT 2014

Powered by FUDForum. Page generated in 0.09381 seconds