Skip to content

[AMQ-9682] allow array type permission #1415

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

colinwerner
Copy link

The payload:

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<org.apache.activemq.command.DataArrayResponse>
    <commandId>0</commandId>
    <responseRequired>false</responseRequired>
    <correlationId>4</correlationId>
    <data class="org.apache.activemq.command.XATransactionId-array"/>
</org.apache.activemq.command.DataArrayResponse> 

causes:

15:38:26,650 [ActiveMQ Task-2     ] INFO  .a.t.f.FailoverTransport - Successfully reconnected to http://172.17.0.2:61618
15:38:26,650 [p://172.17.0.2:61618] WARN  .a.t.f.FailoverTransport - Transport (http://172.17.0.2:61618) failed, attempting to automatically reconnect
 java.io.IOException: Failed to perform GET on: http://172.17.0.2:61618 Reason: [Lorg.apache.activemq.command.XATransactionId;
	at org.apache.activemq.util.IOExceptionSupport.create(IOExceptionSupport.java:36) ~[activemq-client-6.1.3.jar:6.1.3]
	at org.apache.activemq.transport.http.HttpClientTransport.run(HttpClientTransport.java:209) [activemq-http-6.1.3.jar:6.1.3]
	at java.base/java.lang.Thread.run(Thread.java:840) [?:?]
Caused by: com.thoughtworks.xstream.security.ForbiddenClassException: [Lorg.apache.activemq.command.XATransactionId;
	at com.thoughtworks.xstream.security.NoTypePermission.allows(NoTypePermission.java:26) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.mapper.SecurityMapper.realClass(SecurityMapper.java:74) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:125) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.mapper.CachingMapper.realClass(CachingMapper.java:47) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.converters.reflection.AbstractReflectionConverter.doUnmarshal(AbstractReflectionConverter.java:420) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.converters.reflection.AbstractReflectionConverter.unmarshal(AbstractReflectionConverter.java:277) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:74) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.core.AbstractReferenceUnmarshaller.convert(AbstractReferenceUnmarshaller.java:72) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:68) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:52) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.core.TreeUnmarshaller.start(TreeUnmarshaller.java:136) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.core.AbstractTreeMarshallingStrategy.unmarshal(AbstractTreeMarshallingStrategy.java:32) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:1464) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:1441) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.XStream.fromXML(XStream.java:1321) ~[xstream-1.4.20.jar:1.4.20]
	at com.thoughtworks.xstream.XStream.fromXML(XStream.java:1312) ~[xstream-1.4.20.jar:1.4.20]
	at org.apache.activemq.transport.xstream.XStreamWireFormat.unmarshalText(XStreamWireFormat.java:65) ~[activemq-http-6.1.3.jar:6.1.3]
	at org.apache.activemq.transport.util.TextWireFormat.unmarshal(TextWireFormat.java:56) ~[activemq-http-6.1.3.jar:6.1.3]
	at org.apache.activemq.transport.http.HttpClientTransport.run(HttpClientTransport.java:200) ~[activemq-http-6.1.3.jar:6.1.3]
	... 1 more 

This PR allows the array type permission.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant