Skip to content

Fix driver test probes for local URLs and persisted secrets - #1503

Closed
segran2 wants to merge 5 commits into
srcfl:masterfrom
segran2:fix/vw-merged-local-probe-current
Closed

segran2 wants to merge 5 commits into
srcfl:masterfrom
segran2:fix/vw-merged-local-probe-current

Conversation

@segran2

@segran2 segran2 commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • allow Test connection for configured loopback driver URLs only when the requested probe matches the saved enabled driver and URL
  • wire driver test probes to the original driver's persisted secret state so OAuth drivers reuse refreshed tokens
  • keep probe secret writes under the original driver name instead of the temporary _test* name
  • add regression coverage for configured loopback access and OAuth secret reuse/persistence

Fixes #1502.

Verification

  • go test ./internal/api -run 'TestHandleDriverTest|TestConfiguredProbeLoopbackHost|TestRejectUnsafeProbeTargets'
  • built linux/arm64 package v0.139.0-beta.10000 and installed on FTW at 192.168.1.88
  • verified myUplink Test connection returns ok:true with telemetry and no invalid_grant in journal

@segran2 segran2 changed the title fix(api): allow configured loopback driver probes Fix driver test probes for local URLs and persisted secrets Oct 2, 2026

segran2 commented Oct 4, 2026

Copy link
Copy Markdown
Contributor Author

Hardware validation completed on ARM64 FTW with v0.139.2-beta.4 built from PR head 7dba6aa.

Validated MyUplink persisted-secret reuse without running "Connect to MyUplink" again:

  • FTW started v0.139.2-beta.4 as a native trial and committed it successfully.
  • Existing MyUplink driver auto-detected the device and reached ready (read-only).
  • Ran Test connection directly without a new OAuth login.
  • First probe created __test_myuplink_dlvmy877u0hd, auto-detected the device, reached ready (read-only), and was removed normally.
  • Reloaded the web UI and ran Test connection again, still without Connect/OAuth.
  • Second probe created __test_myuplink_dlvmyx14zxyt, again reached ready (read-only), and was removed normally.
  • No invalid_grant was logged.

This verifies the original issue on real hardware: Test connection can reuse the installed driver's persisted MyUplink authentication across UI reloads instead of requiring Connect/login first.

Additional verification on this head:

  • go test ./internal/api — pass
  • native ARM64 runtime healthy after activation

@segran2 segran2 closed this Oct 4, 2026

segran2 commented Oct 4, 2026

Copy link
Copy Markdown
Contributor Author

Ready to merge — hardware validated and all checks passing.

Final status:

  • Current PR head 8f47905a is cleanly mergeable with the current base branch.
  • All applicable GitHub checks pass (10 successful, 4 skipped).
  • No merge conflicts.
  • MyUplink Test connection was hardware-validated on ARM64 FTW without running Connect/OAuth again, including after a web UI reload.
  • Two independent __test_myuplink_* probes reached ready (read-only) and were removed normally.
  • No invalid_grant observed.

The superseded UI workaround #1514 has been closed. This PR addresses the root cause via persisted driver secret reuse.

Maintainer: please merge when ready.

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.

myUplink Test connection fails with invalid_grant

1 participant