Repository navigation
v1.2.0-RC4
Pre-release
Pre-release
This is the fourth release candidate for Milo 1.2.0.
The 1.2.0 feature and migration guide describes the new features and the changes that may require code changes in your application. 1.2.0 includes source and binary compatibility breaks, so recompile applications and extensions against one consistent Milo version.
Changes since RC3
Client
OpcUaClient.changeIdentity(IdentityProvider)andchangeIdentityAsync(...)change the user identity of the active Session without recreating it, so Subscriptions and MonitoredItems stay in place.SessionActivityListener.onSessionIdentityChangedreports the change.SessionActivityListener.onSessionAttemptFailed(AttemptStep, Throwable)reports every failed attempt to create, activate, or reactivate a Session that the client will retry, and names the step that failed. An application can stop retrying when the Server rejects its identity instead of sending a rejected login every 16 seconds.OpcUaClient.getEndpoint()returns the endpoint currently in use, andEndpointRefreshListenerreports when an endpoint refresh adopts a changed endpoint or fails.- Session endpoint validation failures throw
SessionEndpointMismatchException.UaException.extract(Throwable, Class)finds a typedUaExceptionin a cause chain. - On
Noneendpoints, user tokens are encrypted to the certificate CreateSession returned, so a Server can renew its certificate without locking clients out.UsernameProvidernow checks that certificate with the client's certificate validator. disconnect()no longer waits for a new SecureChannel just to send CloseSession after the old one is lost, and a disconnect that overtakes a connect cancels the pending Session.OpcUaClient.create(...)falls back to<endpointUrl>/discoveryonly when the first attempt fails withBad_TcpEndpointUrlInvalidor a security rejection, and it reports the original failure when the fallback also fails.- Fixes in
LazyClientDataTypeTree(a deadlock, negative caching after interrupts, and inherited field order in the seed tree),OpcUaMonitoredItemstate under concurrent changes,UaNode.refresh, andAddressSpaceAccessLevelEx.
Server
- Standard namespace-0 Nodes no longer carry default
RolePermissions, andOPCUANamespaceMetadata.DefaultRolePermissionsandDefaultUserRolePermissionsare removed. Reading RolePermissions or UserRolePermissions on an unconfigured Node returnsBad_AttributeIdInvalid. When an application sets RolePermissions on one of these Nodes, the server derives UserRolePermissions for each Session. - Browse reclaims abandoned continuation points instead of failing with
Bad_NoContinuationPointsonce a Session reaches its limit, andMaxBrowseContinuationPoints = 0means unlimited. Browse keeps references to remote and unreadable targets. - When a request's host matches no configured endpoint, GetEndpoints, FindServers, and CreateSession return the endpoints of one default HostName per transport profile, so clients with session endpoint validation can connect through an alias or NAT address.
- Encrypted username token failures return
Bad_IdentityTokenInvalid, and a token with no matching user token policy returnsBad_IdentityTokenRejected. Sessions onNoneendpoints keep working after an in-place certificate renewal, and the server closes Sessions it refuses in CreateSession.
Stack and security
- The
nsu=andsvu=parts of NodeId, ExpandedNodeId, and QualifiedName strings are percent-encoded as OPC 10000-6 5.1.12 requires. URIs that contain;or%now produce different strings, and strings from other stacks that escape them now parse correctly. FileBasedTrustListManagerwrites certificate and CRL files atomically, and throwsUncheckedIOExceptionwhen it cannot persist a change, after reconciling memory with disk.FileBasedCertificateQuarantinenames rejected certificate files by thumbprint and throwsUncheckedIOExceptionon I/O failures instead of returning an empty list.- Subject alternative names are parsed with Bouncy Castle, and a complete untrusted chain is reported as
Bad_CertificateUntrusted. - DiagnosticInfo encodes Locale before LocalizedText, DateTime conversions handle pre-1970 values, UInt32 narrowing no longer wraps, and the client handshake fails with a
UaExceptionwhen the Server closes the connection early or sends an undecodable reply. ReferenceTypesadds the constants missing from OPC UA 1.05.07.
Performance
- Faster type lookups and NodeId hashing, bulk binary array encoding, symmetric chunk crypto with Mac reuse, and coalesced transport flushes.
- Fewer allocations and less contention in service dispatch, attribute reads and writes, sampling, and subscriptions, which now schedule with a monotonic clock.
Code changes may be required
- Clients that read RolePermissions from standard Nodes, or depend on the removed
OPCUANamespaceMetadataproperties, must handleBad_AttributeIdInvalid. - Code that stores or compares NodeId, ExpandedNodeId, or QualifiedName strings with
;or%in a namespace or server URI must expect the percent-encoded form. - Callers of
FileBasedTrustListManagerupdates andFileBasedCertificateQuarantineshould handleUncheckedIOException. - A client with a strict certificate validator now refuses to send a username token on a
Noneendpoint to a server certificate it does not trust. Add the server certificate to the client's trust list.
What's Changed
- Encode DiagnosticInfo Locale before LocalizedText by @alxkm in #2184
- Maven dependency updates 2026-11-16 by @kevinherron in #2188
- Store every refreshed attribute in UaNode.refresh by @alxkm in #2185
- fix(sdk-server): return null instead of wrapped garbage for UInt32 -> Int16/SByte/UInt16 narrowings of values >= 2^31 by @NUAAwqy in #2187
- Maven dependency updates 2026-11-23 by @kevinherron in #2190
- Set AccessLevelEx on Variable nodes built by AddressSpace by @alxkm in #2191
- Fix deadlock in LazyClientDataTypeTree when clearFailedResolutions races a failed lookup by @kevinherron in #2193
- Fix inherited field order in LazyClientDataTypeTreeSeed by @kevinherron in #2203
- Report failed Session attempts to SessionActivityListener by @kevinherron in #2215
- Validate the certificate UsernameProvider encrypts to with the client's validator by @kevinherron in #2218
- Report a missing user token policy as Bad_IdentityTokenRejected by @kevinherron in #2244
- Use the CreateSession certificate for user tokens on None endpoints, and clear the plaintext password buffer by @kevinherron in #2245
- Return uniform Bad_IdentityTokenInvalid for enhanced username tokens by @kevinherron in #2226
- Validate padding on legacy encrypted username tokens by @kevinherron in #2227
- Add missing OPC UA 1.05.07 constants to ReferenceTypes by @kevinherron in #2230
- Fix DateTime pre-1970 Instant and millisecond conversions by @kevinherron in #2231
- Fail client handshake on close before Acknowledge by @kevinherron in #2232
- Percent-encode nsu= and svu= URIs per OPC 10000-6 5.1.12 by @kevinherron in #2233
- Report the failed step to SessionActivityListener.onSessionAttemptFailed by @kevinherron in #2267
- Name quarantined certificate files by thumbprint and remove all copies by @kevinherron in #2246
- Follow dangling symbolic links in KeyStoreCertificateStore by @kevinherron in #2251
- Parse subjectAltName via Bouncy Castle and omit empty default URI by @kevinherron in #2247
- Report complete untrusted chains as Bad_CertificateUntrusted by @kevinherron in #2248
- Cancel pending Session open when disconnect overtakes connect by @kevinherron in #2262
- Close refused CreateSession sessions on the Server by @kevinherron in #2263
- Restrict /discovery fallback in OpcUaClient.create and preserve first failure by @kevinherron in #2260
- Avoid negative-caching interrupted lazy DataType resolutions by @kevinherron in #2250
- Serialize OpcUaMonitoredItem setters and state transitions by @kevinherron in #2255
- Retain in-flight OpcUaMonitoredItem parameter changes across sync by @kevinherron in #2256
- Update OpcUaMonitoredItem ServerState monitoring mode on SetMonitoringMode by @kevinherron in #2257
- Clear stale MonitoredItem operation results when re-added by @kevinherron in #2258
- Reclaim prior browse continuation points and enforce session limits by @kevinherron in #2234
- Preserve remote and unreadable target references in server Browse by @kevinherron in #2235
- Fall back to one default HostName per transport profile in discovery and session creation by @kevinherron in #2237
- Clear default namespace-0 RolePermissions and decouple diagnostics policies by @kevinherron in #2261
- Preserve interrupt status and clear trust list on FileBasedTrustListManager.close() by @kevinherron in #2252
- Reconcile and fail on FileBasedTrustListManager persistence errors by @kevinherron in #2253
- Retain CreateSession key pair for None-endpoint Sessions by @kevinherron in #2269
- Report I/O failures from FileBasedCertificateQuarantine by @kevinherron in #2271
- Add SessionEndpointMismatchException and typed UaException.extract by @kevinherron in #2270
- Skip CloseSession on disconnect when the SecureChannel is lost by @kevinherron in #2268
- Expose current endpoint and endpoint refresh outcomes on OpcUaClient by @kevinherron in #2272
- Skip unreadable files when removing trust list entries by @kevinherron in #2275
- Support changing user identity on an active client Session by @kevinherron in #2273
- Skip unreadable files when loading trust list directories by @kevinherron in #2279
- Fail client handshake with UaException for undecodable replies by @kevinherron in #2280
- Use the current certificate for Sessions on None SecureChannels by @kevinherron in #2281
- Add a test retention policy to AGENTS.md by @kevinherron in #2282
- Optimize stack-core type lookups, NodeId hashing, and lock-free codec registry by @kevinherron in #2283
- Optimize binary codec bulk array paths, scalar encoding, and Variant framing by @kevinherron in #2284
- Reduce allocations and contention in SDK service dispatch, filter chains, and session state by @kevinherron in #2285
- Optimize server attribute read, write, and access-control hot paths by @kevinherron in #2286
- Optimize symmetric chunk crypto, Mac reuse, and single-chunk framing by @kevinherron in #2287
- Coalesce small outbound flushes and remove per-message transport copies by @kevinherron in #2288
- Use monotonic nanoTime scheduling in SamplingGroup and Subscription by @kevinherron in #2289
- Eliminate per-cycle allocations and lock contention in sampling and subscriptions by @kevinherron in #2290
Full Changelog: v1.2.0-RC3...v1.2.0-RC4