Skip to content

Stream TLS connections use wrong advertised host #1668

@mathieudz

Description

@mathieudz

Describe the bug

Stream TLS connections use stream.advertised_host instead of stream.advertised_tls_host

Reproduction steps

  1. Install RabbitMQ using docker with streams & TLS (port 5551) and specify only stream.advertised_tls_*, not the non-TLS versions. The advertised hostname must be the hostname of the docker host that forwards the stream port to the container.
  2. Try to connect from RabbitMQ Java client (outside docker) to the stream TLS port (5551) and check the debug logs

Expected behavior

In the debug logs you can see that it first connects to the hostname configured in the Java client, discovers the advertised TLS host name, but tries to connect to the hostname of the docker container anyway.

If you also add stream.advertised_* (non-TLS) settings, the connection is successful

Additional context

The usage of docker is not really necessary. It just makes the hostname of the rabbitmq host (docker container) unrouteable from outside. Any proxy will do.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions