Hi all,I noticed the following difference between 0.9.1 and 0.10 and I'm not 
able to use Qpid Proton C 0.10 for sending messages to Azure Service Bus (a 
queue for example).The endpoint is the same for both :
amqps://<username>:<password>@<namespace>.servicebus.windows.net/q1
I'm using the "send" example in the Proton solution (Visual Studio 2015 under 
Windows 10).
With 0.9.1 the message is sent correctly to the Service Bus queue but it 
doesn't happen with version 0.10.
Enabling the PN_TRACE_FRM I can see a big difference ...
With 0.9.1 version the SASL mechanism is PLAIN and it's correct. With 0.10 
version the SASL mechanism is EXTERNAL, so after some messages exchanges I 
receive the unauthorized access with a claim needed. It's right because I'm not 
sending the SAS token to Azure (needed by the AMQP Claim Based Security 
specification).
0.9.1 ......
[011FDF28]:  -> SASL
[011FDF28]:0 -> @sasl-init(65) [mechanism=:PLAIN, 
initial-response=b"\x00RootManageSharedAccessKey\x00<mysecretkey>"]
[011FDF28]:  <- SASL
0.10 ....
[00D9D160]:  -> SASL
[00D9D160]:  <- SASL
[00D9D160]:0 <- @sasl-mechanisms(64) [sasl-server-mechanisms=@PN_SYMBOL[:PLAIN, 
:EXTERNAL]]
[00D9D160]:0 -> @sasl-init(65) [mechanism=:EXTERNAL, 
initial-response=b"RootManageSharedAccessKey"]....[00D9D160]:0 <- @detach(22) 
[handle=0, closed=true, error=@error(29) 
[condition=:"amqp:unauthorized-access", description
="Unauthorized access. 'Send' claim(s) are required to perform this operation. 
Resource: 'sb://qpidprotontest.servicebus
.windows.net/q1'. 
TrackingId:c5a321fd35e7461f83846bbcef5e42ff_G34,TimeStamp:9/1/2015 2:12:36 PM"]]
My question is why the two version have these two different behaviors ?It's the 
client to propose the PLAIN in 0.9.1 and EXTERNAL in 0.10.
Attached you can find the two different trace (I removed <mysecretkey>).
With these changes seems that the current 0.10 version doesn't work with Azure 
Service Bus.
Thanks,Paolo.

Paolo PatiernoSenior Software Engineer
 

Windows Embedded & IoTMicrosoft Azure Insider 
Twitter : @ppatierno
Linkedin : paolopatierno
Blog : DevExperienceBlog : Embedded101
                                          
[011FDF28]:  -> SASL
[011FDF28]:0 -> @sasl-init(65) [mechanism=:PLAIN, 
initial-response=b"\x00RootManageSharedAccessKey\x00<mysecretkey>"]
[011FDF28]:  <- SASL
[011FDF28]:0 <- @sasl-mechanisms(64) [sasl-server-mechanisms=@PN_SYMBOL[:PLAIN, 
:EXTERNAL]]
[011FDF28]:0 <- @sasl-outcome(68) [code=0, additional-data=b"Welcome!"]
[011FDF28]:  -> AMQP
[011FDF28]:0 -> @open(16) [container-id="912a3358-d8cf-422c-b168-2ad17149c6e9", 
hostname="qpidprotontest.servicebus.wind
ows.net"]
[011FDF28]:0 -> @begin(17) [next-outgoing-id=0, incoming-window=2147483647, 
outgoing-window=1]
[011FDF28]:0 -> @attach(18) [name="sender-xxx", handle=0, role=false, 
snd-settle-mode=2, rcv-settle-mode=0, source=@sour
ce(40) [address="q1", durable=0, timeout=0, dynamic=false], target=@target(41) 
[address="q1", durable=0, timeout=0, dyna
mic=false], initial-delivery-count=0]
[011FDF28]:  <- AMQP
[011FDF28]:0 <- @open(16) [container-id="b34776cd5580479780c6fc02b60e8c61_G40", 
max-frame-size=65536, channel-max=4999,
idle-time-out=240000]
[011FDF28]:0 <- @begin(17) [remote-channel=0, next-outgoing-id=1, 
incoming-window=1, outgoing-window=5000, handle-max=25
5]
[011FDF28]:0 <- @attach(18) [name="sender-xxx", handle=0, role=true, 
snd-settle-mode=2, rcv-settle-mode=0, source=@sourc
e(40) [address="q1", durable=0, timeout=0, dynamic=false], target=@target(41) 
[address="q1", durable=0, timeout=0, dynam
ic=false], max-message-size=262144, 
properties={:"com.microsoft:tracking-id"="b34776cd5580479780c6fc02b60e8c61_G40"}]
[011FDF28]:0 <- @flow(19) [next-incoming-id=0, incoming-window=1, 
next-outgoing-id=1, outgoing-window=5000, handle=0, de
livery-count=0, link-credit=300, available=0, echo=false]
[011FDF28]:0 -> @transfer(20) [handle=0, delivery-id=0, 
delivery-tag=b"\x00\x00\x00\x00\x00\x00\x00\x00", message-format
=0, settled=true, more=false] (120) 
"\x00Sp\xd0\x00\x00\x00\x0b\x00\x00\x00\x05BP\x04@BR\x00\x00Ss\xd0\x00\x00\x00S\x00\
x00\x00\x0d@@\xa10amqps://qpidprotontest.servicebus.windows.net/q1@@@@@\x83\x00\x00\x00\x00\x00\x00\x00\x00\x83\x00\x00\
x00\x00\x00\x00\x00\x00@R\x00@\x00Sw\xa1\x05Hello"
[011FDF28]:0 -> @detach(22) [handle=0, closed=true]
[011FDF28]:0 -> @close(24) []
[011FDF28]:0 <- @flow(19) [next-incoming-id=1, incoming-window=1, 
next-outgoing-id=1, outgoing-window=5000]
[011FDF28]:0 <- @detach(22) [handle=0, closed=true]
[011FDF28]:0 <- @close(24) []
[011FDF28]:  <- EOS
[011FDF28]:  -> EOS
[00D9D160]:  -> SASL
[00D9D160]:  <- SASL
[00D9D160]:0 <- @sasl-mechanisms(64) [sasl-server-mechanisms=@PN_SYMBOL[:PLAIN, 
:EXTERNAL]]
[00D9D160]:0 -> @sasl-init(65) [mechanism=:EXTERNAL, 
initial-response=b"RootManageSharedAccessKey"]
[00D9D160]:0 <- @sasl-outcome(68) [code=0, additional-data=b"Welcome!"]
[00D9D160]:  -> AMQP
[00D9D160]:0 -> @open(16) [container-id="3916B309-E52B-473D-9A17-F93C9959F021", 
hostname="qpidprotontest.servicebus.wind
ows.net", channel-max=32767]
[00D9D160]:0 -> @begin(17) [next-outgoing-id=0, incoming-window=2147483647, 
outgoing-window=2147483647]
[00D9D160]:0 -> @attach(18) [name="sender-xxx", handle=0, role=false, 
snd-settle-mode=2, rcv-settle-mode=0, source=@sour
ce(40) [address="q1", durable=0, timeout=0, dynamic=false], target=@target(41) 
[address="q1", durable=0, timeout=0, dyna
mic=false], initial-delivery-count=0]
[00D9D160]:  <- AMQP
[00D9D160]:0 <- @open(16) [container-id="c5a321fd35e7461f83846bbcef5e42ff_G34", 
max-frame-size=65536, channel-max=4999,
idle-time-out=240000]
[00D9D160]:0 <- @begin(17) [remote-channel=0, next-outgoing-id=1, 
incoming-window=5000, outgoing-window=5000, handle-max
=255]
[00D9D160]:0 <- @attach(18) [name="sender-xxx", handle=0, role=true, 
snd-settle-mode=2, rcv-settle-mode=0, max-message-s
ize=262144]
[00D9D160]:0 <- @detach(22) [handle=0, closed=true, error=@error(29) 
[condition=:"amqp:unauthorized-access", description
="Unauthorized access. 'Send' claim(s) are required to perform this operation. 
Resource: 'sb://qpidprotontest.servicebus
.windows.net/q1'. 
TrackingId:c5a321fd35e7461f83846bbcef5e42ff_G34,TimeStamp:9/1/2015 2:12:36 PM"]]
[00D9D160]:0 -> @detach(22) [handle=0, closed=true]
[00D9D160]:0 -> @close(24) []
[00D9D160]:0 <- @close(24) []
[00D9D160]:  <- EOS
[00D9D160]:  -> EOS

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@qpid.apache.org
For additional commands, e-mail: users-h...@qpid.apache.org

Reply via email to