Skip to content

git commit -m "Fix: allow mqtts:// in MQTT monitor hostname and updat…#7290

Open
Mrstragr wants to merge 1 commit intolouislam:masterfrom
Mrstragr:patch-1
Open

git commit -m "Fix: allow mqtts:// in MQTT monitor hostname and updat…#7290
Mrstragr wants to merge 1 commit intolouislam:masterfrom
Mrstragr:patch-1

Conversation

@Mrstragr
Copy link
Copy Markdown

…e validation hint"

Fix MQTT monitor not accepting mqtts:// hostname

This PR fixes an issue where mqtts:// URLs were rejected in the MQTT monitor hostname field.

Changes:

  • Updated UI hint to include mqtts://
  • Extended regex validation to allow mqtts:// alongside existing protocols

Notes:

  • Verified that backend does not restrict mqtts://, so this is a frontend-only fix

Fixes #7286

Summary

In this pull request, the following changes are made:

  • Foobar was changed to FooFoo, because ...
  • Relates to #issue-number
  • Resolves #issue-number
Please follow this checklist to avoid unnecessary back and forth (click to expand)
  • ⚠️ If there are Breaking change (a fix or feature that alters existing functionality in a way that could cause issues) I have called them out
  • 🧠 I have disclosed any use of LLMs/AI in this contribution and reviewed all generated content.
    I understand that I am responsible for and able to explain every line of code I submit.
  • 🔍 Any UI changes adhere to visual style of this project.
  • 🛠️ I have self-reviewed and self-tested my code to ensure it works as expected.
  • 📝 I have commented my code, especially in hard-to-understand areas (e.g., using JSDoc for methods).
  • 🤖 I added or updated automated tests where appropriate.
  • 📄 Documentation updates are included (if applicable).
  • 🧰 Dependency updates are listed and explained.
  • ⚠️ CI passes and is green.

Screenshots for Visual Changes

  • UI Modifications: Highlight any changes made to the user interface.
  • Before & After: Include screenshots or comparisons (if applicable).
Event Before After
UP Before After
DOWN Before After
Certificate-expiry Before After
Testing Before After

…e validation hint"

### Fix MQTT monitor not accepting mqtts:// hostname

This PR fixes an issue where `mqtts://` URLs were rejected in the MQTT monitor hostname field.

### Changes:

* Updated UI hint to include `mqtts://`
* Extended regex validation to allow `mqtts://` alongside existing protocols

### Notes:

* Verified that backend does not restrict `mqtts://`, so this is a frontend-only fix

Fixes louislam#7286
@CommanderStorm
Copy link
Copy Markdown
Collaborator

I am a bit sussed out by this change. There must be a reason why this was restricted to was before, but maybe this is an oversight.

Can you share a screenshot of this working?

@louislam
Copy link
Copy Markdown
Owner

https://www.iana.org/assignments/uri-schemes/uri-schemes.txt

Maybe it is a valid change, because the protocol is listed in this list. But I never used MQTT, probably need someone who have used mqtts:// to review/approve this change, because it seems a bit tricky to understand it:

https://stackoverflow.com/questions/59562215/how-can-i-get-the-mqtt-broker-url-starting-with-mqtts

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

MQTT monitor does not accept mqtts:// hostname URLs

3 participants