OP-04: Inspect Oracle connection info¶
This operation reads the secure Oracle credential for an instance and user directly from the Environment API and returns the raw credential, the split user and password, and the composed connection string. It performs no connectivity probe, uses no cache and writes no audit log, and it discloses the plaintext password.
| Field | Value |
|---|---|
| Operation ID | OP-04 |
| Trigger | HTTP request from an authorized caller |
| Entry endpoint | POST /v1/Admin/GetOracleConnectionInfo |
| Owning component | AdminController.GetOracleConnectionInfo, delegating to AdminController.GetConnectionInfo |
| Inputs | Query values instance and userName (inferred query binding, no body); template oraconnectiontemplate and a secure credential |
| Outputs | Dictionary<string,string> with keys credentials, user, pw, connectionString and optionally Error |
| Failure response | A failed credential split still returns 200 with an Error entry; a missing secure setting or template raises a failure whose status is not visible in source** |
Steps¶
- Authorize the caller against resource
DBConnAPIRetrieveResource, the same resource as the retrieval endpoints (BR-DBC-025) - Build the lower-cased secure-setting key
ora_<instance>_<user>(BR-DBC-005) - Read the template
oraconnectiontemplateand replace{INSTANCE}(BR-DBC-007) - Read and decrypt the secure setting directly, with no existence check, no probe and no cache (BR-DBC-023)
- A missing key is not handled locally; the status is not visible in source**
- Split the credential at the first pipe inside a bare
try/catch - On failure: add an
Errorentry, leaveuserandpwempty, and continue with status 200 (BR-DBC-024) - Substitute
{USER}and{PW}into the template (BR-DBC-008) - Return the dictionary with status 200
Process flow¶
The following diagram visualizes this operation's control flow.
flowchart TD
A["Authorize DBConnAPIRetrieveResource"] -->|"Denied"| Z["Authorization denial, status not visible in source"]
A --> B["Build secure key and read template"]
B -->|"Template missing"| X["Unhandled/package error, status not visible in source"]
B --> C["Read and decrypt secure setting"]
C -->|"Secure setting missing or read fails"| X2["Unhandled/package error, status not visible in source"]
C --> D{"Credential split at pipe succeeds?"}
D -->|"Yes"| E["Set user and pw"]
D -->|"No"| F["Add Error entry, user and pw empty"]
E --> G["Substitute into template"]
F --> G
G --> H["Return dictionary, 200"]
Transaction and side effects¶
| Aspect | Finding |
|---|---|
| Unit of work | None |
| Commit point | None |
| Records written | None |
| Downstream calls | SAIF Environment API through IEnvironmentClient (template read and secure read) |
| Repeat-call behavior | Every call re-reads the secure setting; nothing is cached |
Logging¶
| Surface | Written content |
|---|---|
| None in this controller | AdminController writes no log entry, so disclosures are not audit-logged locally |
Error handling¶
- Credential without a pipe: swallowed by the local
try/catchand reported in theErrorentry with status 200 - Missing secure setting or missing template: unhandled; handled by package middleware with a status that is not visible in source**
- Authorization failure: produced by the package authorization handler†; the status is not visible in source**
Related documentation¶
- API index
- Overview
- Architecture
- Hosting pipeline
- Endpoints
- Authentication and authorization
- Dependencies
- Configuration
- Operations and processes
- Business rules
- Data model
- Operational runbook
- Tech debt
Note: Statements marked with
â€are derived from dependency library documentation via the Legends CLI. Statements marked with**could not be confirmed; treat as unknown until verified.
Sources¶
- DBConnectionAPI/DBConnectionAPI/Controllers/AdminController.cs
- DBConnectionAPI/DBConnectionAPI/Services/ConnectionManager.cs
- DBConnectionAPI/DBConnectionAPI/Services/IConnectionManager.cs