Table of Contents

Class RabbitMQSslOptions

Namespace
Excalibur.Dispatch.Transport.RabbitMQ
Assembly
Excalibur.Dispatch.Transport.RabbitMQ.dll

SSL/TLS configuration options for RabbitMQ connections.

public sealed class RabbitMQSslOptions
Inheritance
RabbitMQSslOptions
Inherited Members
Extension Methods

Properties

AcceptUntrustedCertificates

Gets or sets a value indicating whether a broker certificate that fails trust validation is accepted.

public bool AcceptUntrustedCertificates { get; set; }

Property Value

bool

true to complete the handshake despite an untrusted certificate; false to require a certificate that validates. Default is false.

Remarks

This waives exactly two validation errors: a certificate that does not chain to a trusted root, and a certificate whose subject does not match the host being dialled. It does not disable validation wholesale -- a broker that presents no certificate at all is still refused, so the connection can never silently become unauthenticated.

The relaxation is applied to any connection that carries TLS, whether TLS came from UseSsl or from an amqps connection string. It has no effect on a plaintext connection, which has no handshake to relax.

The connection stays encrypted but stops being authenticated: an interposed party presenting any certificate is accepted. It exists for self-signed local brokers and test fixtures, not for anything holding real data.

CertificatePassphrase

Gets or sets the certificate passphrase.

public string? CertificatePassphrase { get; set; }

Property Value

string

The certificate passphrase.

CertificatePath

Gets or sets the path to the client certificate file.

public string? CertificatePath { get; set; }

Property Value

string

The certificate file path.

RequireTls

Gets or sets a value indicating whether an unencrypted broker connection is refused.

public bool RequireTls { get; set; }

Property Value

bool

true to refuse to build a connection factory that would connect in the clear; false to permit one. Default is true.

Remarks

The refusal happens when the connection factory is built, so a plaintext registration fails where it is wired rather than at the first message. Every AMQP client this transport creates is reached through that one factory, so the refusal covers all of them.

A connection carries TLS when its connection string uses the amqps scheme or when UseSsl is set. Neither being present is plaintext, so this setting is read whether or not the rest of this group has been configured.

Setting this to false permits credentials and message payloads to travel in the clear. It exists for local brokers and test fixtures, not for anything holding real data.

ServerName

Gets or sets the server name for SSL certificate validation.

public string? ServerName { get; set; }

Property Value

string

The server name.