Files
dbx/apps/desktop
弈秋anddev b168508b9f fix(connection): keep the Oracle TNS_ADMIN directory in plaintext exports (#12723)
An Oracle TNS connection stores its alias in `database` and the
`jdbc:oracle:thin:@<alias>?TNS_ADMIN=<dir>` string that resolves it in
`connection_string`. `scrubConnectionForPlaintextExport()` blanked
`connection_string` unconditionally, so a plaintext export/import silently
dropped the directory that resolves the alias — the re-imported connection
could not connect and had to be reconfigured from scratch (issue #12672).

The string is now rebuilt from the alias and TNS_ADMIN only, so every other
query parameter is dropped instead of forwarded. Validating the stored string
is not enough: the JDBC layer decodes each parameter name with URLDecoder and
trims it before comparing, so `?%70assword=`, `?+password=` and
`?password%20=` all read as `password` there. Rebuilding makes that
impossible by construction, and every non-TNS connection string (JDBC URLs,
DSNs, service-name strings) is still dropped along with the stored password.

Co-authored-by: dev <dev@local>
2026-10-20 10:10:25 +08:00
..