Skip to content

02 Connection Setup

Mark Todd edited this page Jun 25, 2026 · 1 revision

Connection Setup

MQTTProbe supports multiple simultaneous MQTT broker connections with persistent configuration.

Creating a Connection

  1. Open the Connections panel
  2. Click Add Connection to open the connection dialog
  3. Configure your connection settings (see below)
  4. Click Connect

Connection Settings

Identity

Setting Description
Name Friendly name for this connection (must be unique)
Client ID MQTT client ID (auto-generated if left empty; a session suffix is appended automatically for uniqueness)

Transport

Setting Description
Protocol MQTT (TCP) or WebSocket
MQTT Version 3.1.1 (default) or 5.0
Host Broker hostname or IP address
Port Broker port (see defaults below)
Username Authentication username (optional)
Password Authentication password (optional, stored encrypted)

Port Defaults

Protocol Plain TLS
MQTT 1883 8883
WebSocket 8083 8084

TLS

Setting Description
Use TLS Enable TLS/SSL encryption
Allow untrusted certificate Skip certificate validation (not recommended for production)

Warning: "Allow untrusted certificate" disables certificate validation. Only use this for development or testing with self-signed certificates.

WebSocket (additional)

Setting Description
WebSocket Base Path Path appended to the WebSocket URL (default: mqtt)

On Connect

Setting Description
Auto-subscribe topics Topics to subscribe to immediately after connecting (default: spBv1.0/# for Sparkplug B)

Connection States

State Description
Disconnected Not connected
Connecting Attempting to connect
Connected Active connection
Failed Connection attempt failed

Subscriptions

  • Maximum 500 subscriptions per connection
  • Subscriptions use QoS 1 (At Least Once)
  • Topics persist per connection in config/appsettings.json
  • Auto-resubscribe reconnects to previously subscribed topics when the connection is restored

Secret Storage

MQTT passwords are never stored in plain text:

  • Web host: Encrypted using ASP.NET Data Protection, stored in config/secrets.dat
  • MAUI host: Stored in platform-native secure storage (iOS Keychain, Android Keystore, Windows PasswordVault)
  • Linux/macOS: Optionally uses the MQTTPROBE_KEK environment variable for AES key encryption

Saving Connections

When you connect, you'll be prompted to save the connection. Saved connections appear in the Connections panel on subsequent launches and can be edited or deleted.

Validation

Connection settings are validated before connecting:

  • Name: Cannot be empty
  • Host: Must be a valid hostname or IP address
  • Port: Must be between 1 and 65535

If validation fails, an error message will appear in the connection dialog.

Clone this wiki locally