Explainer
Why defining a CA certificate enables secure MQTT on a Flexy
Short answer
Yes. On an eWON Flexy running firmware 14.0s02, the built-in MQTT client makes secure SSL connections, and the enabler is the CA certificate: define the broker's CA in the connection properties and the connection is secured, with no separate encrypted-or-not parameter to find. The Java ETK 1.4.4 path is not established, so route the TLS session through the built-in client.

On this page
- Does eWON firmware 14.0s02 support a secure SSL MQTT client connection?
- How do you enable the encrypted connection when there is no TLS parameter?
- Where do you define the CA certificate for the MQTT connection?
- What does the broker need for the MQTTS session to succeed?
- How do you check that the secure MQTT session is running?
- Why does the Flexy's clock make or break certificate validation?
- Is secure MQTT also supported through Java ETK 1.4.4?
- Which firmware and client path do you deploy for secure MQTT?
- Questions asked
Yes — firmware 14.0s02 for the eWON Flexy supports secure SSL MQTT client connections, and there is no TLS switch to hunt for: the secure connection is enabled as soon as you define a CA certificate in the MQTT connection properties. A Flexy 205 was reported connecting to its broker exactly that way. The sections below explain why the certificate is the switch, where you define it, what the broker must present, how you prove the session is up, and where the Java ETK path stands.
Does eWON firmware 14.0s02 support a secure SSL MQTT client connection? #
Yes: firmware 14.0s02 supports secure SSL MQTT client connections on the Flexy, confirmed by a Flexy 205 that connected to its broker over the encrypted session once its CA certificate was configured.
The version question gets asked because the capability hides. The MQTT client carries no field labelled TLS, so an engineer paging through the connection configuration can easily conclude the firmware offers no encryption. It does — the design puts the secure-or-not decision inside the certificate field itself. Define a CA and the connection goes secure; leave the field empty and it stays plain MQTT. That is also why the answer is pinned to a firmware release and a client: the behavior described here belongs to the built-in MQTT client delivered with that release, while the separate Java ETK library is a different code path, covered further down.
How do you enable the encrypted connection when there is no TLS parameter? #
By defining the broker's CA certificate in the MQTT connection properties: that one definition turns the connection into MQTT over TLS, and a connection left without a CA keeps publishing unencrypted.
The secure form is what the industry writes as MQTTS — plain MQTT wrapped in a TLS session — and on this client the trust anchor doubles as the mode selector. There is no explicit parameter that says encrypted or not, and there is no encrypt-but-do-not-validate middle ground: TLS and trust arrive together, because a client with no CA to check against has nothing to validate. Two field consequences follow. You cannot configure this client into TLS with validation switched off — validation is not optional. And the audit unit is the connection entry: every MQTT connection definition without a CA is a plaintext publisher, even on a Flexy whose other entries are secured.
Where do you define the CA certificate for the MQTT connection? #
In the properties of the MQTT connection itself — the same configuration block where the broker's address lives — not in a device-wide security menu or a global trust list.
What you define there is the CA at the top of the chain that issued the broker's certificate: the root CA, or the intermediate you have chosen to trust. The Flexy treats whatever you define as its trust anchor, so the broker's certificate must chain up to exactly that certificate. Do not confuse this with the device keystore: the documented keystore procedure — create a folder named certificates inside the usr folder, place the certificate in it, then complete the step in the device's web interface — is written for client HTTPS requests, as the documented keystore procedure for adding a custom CA certificate shows, and it is not the switch for the MQTT connection. One detail the material establishing this behavior does not show is the file encoding the MQTT entry expects; read it from the certificate import on the unit rather than assuming the keystore's format carries over.
What does the broker need for the MQTTS session to succeed? #
A TLS listener — conventionally TCP port 8883, the IANA-registered secure-mqtt port — plus a server certificate chain that reaches the CA you defined and carries the DNS name you connect to.
Chain first: a broker typically presents a leaf certificate signed by an intermediate, itself signed by a root. If you defined the root, every certificate the broker sends must verify up to it, and a broker whose chain stops at an intermediate you never defined fails validation. Name second: this client checks the DNS name, and a Flexy MQTT TLS connection fails when the certificate lacks the broker DNS name — connect by the name printed in the certificate and make sure the Flexy can resolve that name. Path third: every firewall or NAT rule between the Flexy and the broker must pass the listener's port; if your broker's TLS listener is not on the conventional port, that other port is the one the connection must target. One more case sits outside this design: cloud MQTT endpoints that demand client-certificate authentication require the Flexy itself to present a certificate, and fixing X.509 certificate auth to Azure IoT Hub over MQTT walks that separate setup.
How do you check that the secure MQTT session is running? #
Read the connection status back from the Flexy after the first attempt: checking MQTT connection status in an Ewon Flexy BASIC script gives you the readback that shows whether the session established.
Two failure signatures are worth knowing before you enable TLS, because both look like MQTT problems and are not. A status that stays at 3 after enabling TLS traces to the secure layer, so work the CA chain and the DNS name, not the publish logic. And when MQTT TLS connects but no CONNACK arrives, the TCP and TLS hops are already up and the failure sits further along the exchange — find the failing hop instead of re-entering the certificate. The discipline that saves an afternoon: change one thing at a time. Take a working plain connection, add the CA, and if it breaks, the delta is the certificate path — the broker address and the topic configuration did not change.
Why does the Flexy's clock make or break certificate validation? #
Because TLS checks every certificate against the device clock: a Flexy whose clock reads outside the CA's validity window rejects the broker's certificate before any MQTT packet is exchanged, and the session never opens.
Worked example, with illustrative dates. Take a CA valid from 15 January 2021 to 15 January 2031, and a Flexy whose clock, synchronized from its time source, reads 15 January 2026. The validity check is 2021 ≤ 2026 ≤ 2031 — true — so the certificate validates, with 2031 − 2026 = 5 years of margin before the CA expires. Now take the same Flexy after it lost its time source and the clock fell back to 15 January 2020. The check becomes 2021 ≤ 2020 — false — with the clock sitting 2021 − 2020 = 1 year before the window even opens, and the broker's certificate is rejected even though every byte of it is correct. The broker certificate's own validity dates are checked the same way. Decision: a Flexy publishing over TLS needs a working time source as much as it needs the CA. When a secure session fails on a device that was just powered or reset, read the clock before you touch the certificate.
Is secure MQTT also supported through Java ETK 1.4.4? #
Not on the evidence available: nothing confirms that the Java ETK 1.4.4 MQTT path builds the same CA-secured session, so a design that promises TLS through that library is unverified.
The vendor's MQTT TLS material does show a Java flow in which the CA and key files are passed as connection parameters after the open request, so the library has TLS plumbing — but nothing ties that flow to the ETK release your project uses. The confirmed path is the built-in client, and that is a workable decision, not a gap: route the secure session through the built-in connection and keep custom Java logic off the TLS leg until the release documentation for that exact library version states the support. If a project cannot split the roles that way, treat the ETK's TLS capability as an open compatibility question and get the answer through the vendor's support channel before the design freezes. The field confirmation covers the built-in client, not the library.
Which firmware and client path do you deploy for secure MQTT? #
Firmware 14.0s02 or later, the built-in MQTT client, the broker's CA in the connection properties, and a working time source: that is the confirmed secure path, decision made.
- New deployment: that firmware release or later, built-in client, and a CA defined on every connection entry that leaves the plant network.
- Fleet still on the previous release: upgrade before you configure TLS — read why a Flexy MQTT client drops after one publish on firmware 14.0s01, because no certificate configuration rescues a session that will not stay up.
- Project that needs the Java library: keep the ETK off the TLS leg until its documentation for that release confirms the support.
- Broker side: TLS listener reachable through every firewall and NAT on the path, a chain that climbs to your defined CA, and the DNS name you connect by inside the certificate.
Enable it, read the status back, and secure MQTT on the Flexy is a configuration item, not a firmware mystery.
Questions asked
Does the secure connection work with any standard MQTT broker?
Yes, because it is standard MQTT over TLS, not a proprietary scheme. Any broker with a TLS listener and a chain that reaches the CA you defined can serve the session, including one you run on your own premise. Cloud endpoints that also demand client certificates are a different case: there the Flexy must present its own certificate, which is the X.509 setup, not the CA-only connection.
What happens if the CA you define does not match the broker's certificate?
The TLS handshake fails and no MQTT packet is ever exchanged; the client does not fall back to plain MQTT on a connection where a CA is defined. Replace the entry's certificate with the one that signed the broker's chain, confirm the DNS name matches, and reconnect — the status readback then tells you whether the session established.
Does firmware 14.0s01 also support secure MQTT connections?
Treat 14.0s02 as the floor. The earlier release carries a known session failure — the client drops after one publish — and adding a CA to a connection on it gives you an encrypted session with the same instability. Upgrade the unit first, then define the certificate; order matters, because a certificate cannot repair a session that will not persist.
Can you use your own private CA instead of a purchased certificate chain?
Yes. The certificate you define is the trust anchor, so a CA you generated yourself works, provided the broker's certificate chains to it and carries the broker's DNS name. You then own both expiry dates: put the CA's renewal and the broker certificate's renewal on the same maintenance calendar as the rest of the plant's certificates.


