syncope-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Francesco Chicchiriccò <ilgro...@apache.org>
Subject Re: 500 calling SyncopeClient
Date Mon, 12 Oct 2015 13:58:25 GMT
On 12/10/2015 15:55, Massimiliano Perrone wrote:
> Hi all,
> I'm developing the CLI client and I'm using the 
> org.apache.syncope.client.lib.SyncopeClient class to call the Syncope 
> rest services.
>
> Just now I found something wrong with SyncopeClient authentication.
> If I try to create a SyncopeClient with a right username but a wrong 
> password I get a "normal" exception with this message: User admin not 
> authenticated. (as expected)
> Otherwise I try the same operation with a wrong username and a right 
> (or wrong) password I get a 500:

Hi Massimiliano,
that's surely not the way to go, please open an issue on JIRA for the 
problem.

Regards.

> ID: 1
> Response-Code: 500
> Encoding: UTF-8
> Content-Type: text/html;charset=utf-8
> Headers: {connection=[close], Content-Language=[en], 
> Content-Length=[6389], content-type=[text/html;charset=utf-8], 
> Date=[Mon, 12 Oct 2015 13:53:18 GMT], Server=[Apache-Coyote/1.1]}
> Payload: <!DOCTYPE html><html><head><title>Apache Tomcat/8.0.27
- 
> Error report</title><style type="text/css">H1 
> {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;}

> H2 
> {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;}

> H3 
> {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:14px;}

> BODY 
> {font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} 
> B 
> {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;} 
> P 
> {font-family:Tahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A 
> {color : black;}A.name {color : black;}.line {height: 1px; 
> background-color: #525D76; border: none;}</style> 
> </head><body><h1>HTTP Status 500 - Null key</h1><div 
> class="line"></div><p><b>type</b> Exception 
> report</p><p><b>message</b> <u>Null key</u></p><p><b>description</b>

> <u>The server encountered an internal error that prevented it from 
> fulfilling this 
> request.</u></p><p><b>exception</b></p><pre>org.apache.syncope.core.persistence.api.dao.NotFoundException:

> Null key
> org.apache.syncope.core.persistence.jpa.dao.AbstractAnyDAO.authFind(AbstractAnyDAO.java:87)

>
>     sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) 
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

>
>     java.lang.reflect.Method.invoke(Method.java:606)
> org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)

>
> org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)

>
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)

>
> org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)

>
> org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)

>
> org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)

>
> org.apache.syncope.core.misc.spring.DomainTransactionInterceptor.invoke(DomainTransactionInterceptor.java:64)

>
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)

>
> org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:207)

>
>     com.sun.proxy.$Proxy129.authFind(Unknown Source)
> org.apache.syncope.core.workflow.java.AbstractUserWorkflowAdapter.internalSuspend(AbstractUserWorkflowAdapter.java:95)

>
>     sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) 
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

>
>     java.lang.reflect.Method.invoke(Method.java:606)
> org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)

>
> org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)

>
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)

>
> org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)

>
> org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)

>
> org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)

>
> org.apache.syncope.core.misc.spring.DomainTransactionInterceptor.invoke(DomainTransactionInterceptor.java:64)

>
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)

>
> org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:207)

>
>     com.sun.proxy.$Proxy137.internalSuspend(Unknown Source)
> org.apache.syncope.core.provisioning.java.DefaultUserProvisioningManager.internalSuspend(DefaultUserProvisioningManager.java:308)

>
> org.apache.syncope.core.misc.security.SyncopeAuthenticationProvider$3.exec(SyncopeAuthenticationProvider.java:141)

>
> org.apache.syncope.core.misc.security.SyncopeAuthenticationProvider$3.exec(SyncopeAuthenticationProvider.java:137)

>
> org.apache.syncope.core.misc.security.AuthContextUtils.execWithAuthContext(AuthContextUtils.java:114)

>
> org.apache.syncope.core.misc.security.SyncopeAuthenticationProvider.authenticate(SyncopeAuthenticationProvider.java:137)

>
> org.springframework.security.authentication.ProviderManager.authenticate(ProviderManager.java:167)

>
> org.springframework.security.authentication.ProviderManager.authenticate(ProviderManager.java:192)

>
> org.springframework.security.web.authentication.www.BasicAuthenticationFilter.doFilterInternal(BasicAuthenticationFilter.java:177)

>
> org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)

>
> org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330)

>
> org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:53)

>
> org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)

>
> org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330)

>
> org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:91)

>
> org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330)

>
> org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:213)

>
> org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:176)

>
> org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:346)

>
> org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:262)

>
> org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:85)

>
> org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)

>
> </pre><p><b>note</b> <u>The full stack trace of the root
cause is 
> available in the Apache Tomcat/8.0.27 logs.</u></p><hr 
> class="line"><h3>Apache Tomcat/8.0.27</h3></body></html>
> --------------------------------------
> ott 12, 2015 3:53:18 PM org.apache.cxf.jaxrs.utils.JAXRSUtils 
> logMessageHandlerProblem
> GRAVE: No message body reader has been found for class 
> org.apache.syncope.common.lib.to.ErrorTO, ContentType: 
> text/html;charset=utf-8
> ott 12, 2015 3:53:18 PM org.apache.cxf.jaxrs.utils.JAXRSUtils 
> logMessageHandlerProblem
> GRAVE: No message body reader has been found for class java.util.List, 
> ContentType: text/html;charset=utf-8
> > > Remote exception with status code: INTERNAL_SERVER_ERROR
>
> Massimiliano
>


-- 
Francesco Chicchiriccò

Tirasa - Open Source Excellence
http://www.tirasa.net/

Involved at The Apache Software Foundation:
member, Syncope PMC chair, Cocoon PMC, Olingo PMC
http://people.apache.org/~ilgrosso/


Mime
View raw message