|
|
| Author |
Message |
|
| Guest |
Posted: Sat Jan 12, 2008 3:17 am |
|
|
|
Guest
|
Hi Gang,
I have a user account called example and a virtual host called
example.com. I have a realm called /mail.
$ sbin/rabbitmqctl list_permissions example example.com
Listing permissions for user "example" in vhost "example.com" ...
/data: [passive,active,write,read]
/mail: [passive,active,write,read]
$ sbin/rabbitmqctl list_vhost_users example.com
Listing users for vhosts "example.com"...
guest
example
done.
When I connect (as user example with a vhost of example.com) to
rabbitmq using the Java API (via Scala), I run into an error:
val ticket = channel.accessRequest("/mail")
throws an Exception
Caused by: com.rabbitmq.client.ShutdownSignalException (channel error;
reason: {#method<channel.close>(reply code=403, reply
text=ACCESS_REFUSED, class id=30, method id=10),null,""})
rabbit.log shows:
=INFO REPORT==== 11-Jan-2008::19:11:00 ===
accepted TCP connection on 0.0.0.0:5672 from 127.0.0.1:55165
=INFO REPORT==== 11-Jan-2008::19:11:00 ===
Realm access refused: bad path; User <<"example">>, VHost
<<"example.com">>, Realm <<"/mail">>
=INFO REPORT==== 11-Jan-2008::19:11:00 ===
Sending exception: Channel 1, Reason {amqp,access_refused,'access.request'}
If I use accessRequest("/data"), everything woks fine. I know that
/data is built-in which makes me wonder what magic /data has that I
haven't applied to /mail.
This is with rabbitmq 1.2.0 on erlang r11b-5.
Best,
Steve Jenson
_______________________________________________
rabbitmq-discuss mailing list
rabbitmq-discuss@lists.rabbitmq.com
http://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Post recived from mailinglist |
|
|
| Back to top |
|
| Guest |
Posted: Sun Jan 13, 2008 10:51 pm |
|
|
|
Guest
|
Steve,
Steve Jenson wrote:
> When I connect (as user example with a vhost of example.com) to
> rabbitmq using the Java API (via Scala), I run into an error:
> [...]
> rabbit.log shows:
>
> =INFO REPORT==== 11-Jan-2008::19:11:00 ===
> accepted TCP connection on 0.0.0.0:5672 from 127.0.0.1:55165
>
> =INFO REPORT==== 11-Jan-2008::19:11:00 ===
> Realm access refused: bad path; User <<"example">>, VHost
> <<"example.com">>, Realm <<"/mail">>
The AMQP 0-8 spec says
<quote>
The realm name MUST start with either "/data" (for application
resources) or "/admin" (for server administration resources).
If the realm starts with any other path, the server MUST raise
a connection exception with reply code 403 (access refused).
</quote>
So the error you are seeing is because your realm doesn't start with
/data or /admin.
Matthias.
_______________________________________________
rabbitmq-discuss mailing list
rabbitmq-discuss@lists.rabbitmq.com
http://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Post recived from mailinglist |
|
|
| Back to top |
|
|
|
All times are GMT
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You cannot download files in this forum
|
|
|