ningbing commented on issue #13728:
URL: https://github.com/apache/dubbo/issues/13728#issuecomment-2765748199

   i am using Dubbo3.3.0 with spring security + spring auth server to implement 
the OAuth2 SSO,after user login success, i call a method by @DubboReference, 
it's not work:
   java.lang.IllegalArgumentException: The class with 
org.springframework.security.oauth2.server.resource.authentication.JwtAuthenticationToken
 and name of 
org.springframework.security.oauth2.server.resource.authentication.JwtAuthenticationToken
 is not in the allowlist. If you believe this class is safe to deserialize, 
please provide an explicit mapping using Jackson annotations or by providing a 
Mixin. If the serialization is only done by a trusted source, you can also 
enable default typing. See 
https://github.com/spring-projects/spring-security/issues/4370 for details
        at 
org.springframework.security.jackson2.SecurityJackson2Modules$AllowlistTypeIdResolver.typeFromId(SecurityJackson2Modules.java:285)
 ~[spring-security-core-6.3.3.jar:6.3.3]
        at 
com.fasterxml.jackson.databind.jsontype.impl.TypeDeserializerBase._findDeserializer(TypeDeserializerBase.java:159)
 ~[jackson-databind-2.17.2.jar:2.17.2]
        at 
com.fasterxml.jackson.databind.jsontype.impl.AsPropertyTypeDeserializer._deserializeTypedForId(AsPropertyTypeDeserializer.java:151)
 ~[jackson-databind-2.17.2.jar:2.17.2]
        at 
com.fasterxml.jackson.databind.jsontype.impl.AsPropertyTypeDeserializer.deserializeTypedFromObject(AsPropertyTypeDeserializer.java:136)
 ~[jackson-databind-2.17.2.jar:2.17.2]
        at 
com.fasterxml.jackson.databind.deser.AbstractDeserializer.deserializeWithType(AbstractDeserializer.java:263)
 ~[jackson-databind-2.17.2.jar:2.17.2]
        at 
com.fasterxml.jackson.databind.deser.impl.TypeWrappedDeserializer.deserialize(TypeWrappedDeserializer.java:74)
 ~[jackson-databind-2.17.2.jar:2.17.2]
        at 
com.fasterxml.jackson.databind.deser.DefaultDeserializationContext.readRootValue(DefaultDeserializationContext.java:342)
 ~[jackson-databind-2.17.2.jar:2.17.2]
        at 
com.fasterxml.jackson.databind.ObjectMapper._readMapAndClose(ObjectMapper.java:4905)
 ~[jackson-databind-2.17.2.jar:2.17.2]
        at 
com.fasterxml.jackson.databind.ObjectMapper.readValue(ObjectMapper.java:3909) 
~[jackson-databind-2.17.2.jar:2.17.2]
        at 
org.apache.dubbo.spring.security.jackson.ObjectMapperCodec.deserialize(ObjectMapperCodec.java:50)
 ~[dubbo-3.3.0.jar:3.3.0]
        at 
org.apache.dubbo.spring.security.jackson.ObjectMapperCodec.deserialize(ObjectMapperCodec.java:67)
 ~[dubbo-3.3.0.jar:3.3.0]


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to