Azure / amqpnetlite

AMQP 1.0 .NET Library
Apache License 2.0
401 stars 143 forks source link

Connecting from Azure.Messaging.ServiceBus package #477

Closed drjaydenm closed 2 years ago

drjaydenm commented 3 years ago

Hi there, I see in #176 it was possible to connect to an AMQP.Net Lite listener from the WindowsAzure.ServiceBus library. However they have now deprecated this package in lieu of the newer Azure.Messaging.ServiceBus package.

I was wondering if you know if it is possible to somehow connect with the newer package. I've been playing around trying to disable SSL as mentioned in #176 and cannot find a way to do that so far (maybe this isn't even required anymore?).

We are trying to get this working as a way to run integration tests locally without connecting to a real service bus, and this would be amazing if it worked.

Your insight would be greatly appreciated :)

xinchen10 commented 3 years ago

@joshlove-msft I don't know if there is a way to turn off ssl in the new Service Bus package. It is designed to work only with Azure Service Bus where SSL is always required.

JoshLove-msft commented 3 years ago

Hmm @jsquire do you happen to know?

jsquire commented 3 years ago

There is not a way to bypass TLS in the Azure.Messaging.ServiceBus package, since Service Bus itself requires its use. As Xin mentioned, the SDK is designed to work against Azure Service Bus only.

The best work-around that I can think of would be to use a proxy that would allow SSL to be used asymmetrically.

drjaydenm commented 3 years ago

Thanks for clarifying. If turning off SSL from the package isn't an option, is there a way to configure AMQP.Net Lite as a listener to accept SSL in a way that the Azure.Messaging.ServiceBus package would be compatible with?

jsquire commented 3 years ago

Thanks for clarifying. If turning off SSL from the package isn't an option, is there a way to configure AMQP.Net Lite as a listener to accept SSL in a way that the Azure.Messaging.ServiceBus package would be compatible with?

@xinchen10 - We'll need to defer to you on that one.

xinchen10 commented 3 years ago

The library uses any certificate you tell it to use for the SSL listener. The certificate is validated by the client. The question is actually about how to configure the client to accept the certificate you set on the listener side.