[
https://issues.apache.org/jira/browse/QPID-4666?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13612739#comment-13612739
]
JAkub Scholz edited comment on QPID-4666 at 3/25/13 3:51 PM:
-------------------------------------------------------------
The client sends a following command:
[main] DEBUG org.apache.qpid.transport.Connection - SEND: [conn:29f429f4] ch=0
id=2 MessageSubscribe(queue=broadcast.CBKFR_CBKFRALMMACC1.TradeConfirmation,
destination=1, acceptMode=EXPLICIT, acquireMode=PRE_ACQUIRED, resumeTtl=0,
arguments={x-filter-jms-selector=})
and receives following response:
[IoReceiver - prmd05.xeop.de/172.16.11.49:61314] DEBUG
org.apache.qpid.transport.Connection - RECV: [conn:29f429f4] ch=0
ExecutionException(errorCode=UNAUTHORIZED_ACCESS, commandId=2,
description=Cannot subscribe to '1': Permission denied)
As you can see, the destination is returned in the response instead of the
queue name. This seems to be cause by the
org.apache.qpid.server.transport.ServerSessionDelegate, which on the line 278
does this:
exception(session, method, e, "Cannot subscribe to '" + destination);
Instead of this:
exception(session, method, e, "Cannot subscribe to '" + queueName);
Attached is a patch with a fix. I'm not sure whether this doesn't cause any
other problems, but it definitely fixes the error message in my case. Patch is
attached.
was (Author: scholzj):
The client sends a following command:
> Incorrect exception message returned in MessageSubscribe when permission is
> denied
> ----------------------------------------------------------------------------------
>
> Key: QPID-4666
> URL: https://issues.apache.org/jira/browse/QPID-4666
> Project: Qpid
> Issue Type: Bug
> Components: Java Broker
> Environment: Linux, Java 1.6, Qpid Java Client 0.20, Qpid Java Broker
> 0.23 (trunk)
> Reporter: JAkub Scholz
> Priority: Minor
> Attachments: client.log
>
>
> When AMQP client tries to subscribe to a queue which he is not allowed to
> assign to due to insufficient ACL rights, he seems to receive a slightly
> incorrect error message:
> Cannot subscribe to '1': Permission denied
> instead of:
> Cannot subscribe to 'queueName': Permission denied
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]