Skip to content

Verify passed bootstrap_server argument is a valid host:port #7254

Open
@polvorin

Description

Observed behavior

There is a confluent addon that enables end-to-end encrypted message streams through Confluent Cloud.

To be used, It need to be explicitly configured as an addon on the orchestrator' project:

   ockam project addon configure confluent \
       --bootstrap-server YOUR_CONFLUENT_CLOUD_BOOTSTRAP_SERVER_ADDRESS

that bootstrap server address must be a HOST:PORT pair, but currently no check is done when parsing the command arguments, resulting in an error further downstream that is not that evident to the user.

Steps to reproduce

Pass any invalid string as the --bootstrap-server argument.

Expected behavior

It must verify that:

  • It follows the HOST:PORT  format

  • HOST is a valid hostname

  • PORT is a valid tcp port (enough to check it's <= 65535)

  • Probably a good idea to try to open a tcp connection to that address, to check there is something really listening there.

In case of errors on the format or address not being reachable, terminate with an error message telling the user the encounter error.

Ockam Version

v0.113.0

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions