Skip to content

fix: protect build arguments across API and native SDK - #864

Merged
Hydralerne merged 2 commits into
oblien:feat/bugfix-integration-2026-09-15from
AbdullahM07:fix/854-mask-build-args
Sep 15, 2026
Merged

Hydralerne merged 2 commits into
oblien:feat/bugfix-integration-2026-09-15from
AbdullahM07:fix/854-mask-build-args

Conversation

@AbdullahM07

@AbdullahM07 AbdullahM07 commented Sep 8, 2026

Copy link
Copy Markdown
Member

Service and deployment reads exposed current and historical build-argument secrets. This change masks non-empty values at the shared platform boundary and recovers echoed masks on writes, preserving working builds and rollback snapshots. Fixes #854 when the integration branch reaches main.

  • Covers service CRUD, Compose sync and drift, source scans, deployment history and build status through both HTTP and the native SDK.
  • Preserves empty strings, inherited null arguments and whole-map replacement. Masked arguments retain their stored interpolation provenance; new literal values cannot inherit a stale template marker.
  • Adds project/service/key-scoped HMAC fingerprints for comparing stored literal values without disclosing them. Inherited or interpolated arguments are excluded; fingerprints do not attest running-container values.
  • Keeps explicitly authorized includeEnv: true source editing scans functional. Internal merge baselines stay private, and retained snapshots remain usable for rollback.

Abdullah Mohamed's original commit is retained. The PR is updated for the current shared platform architecture and targets feat/bugfix-integration-2026-09-15, ahead of the draft integration PR #891.

Validation with repository-pinned Bun 1.3.10:

  • 292 targeted API tests passed, including six tests using real PGlite, PAT authentication, service writes and native/HTTP deployment reads.
  • 29 SDK tests passed, including real native-worker source preparation and staged-upload scans.
  • API typecheck and documentation checks passed (including SDK examples).
  • Historical-disclosure and masked-sync regressions both fail on the pre-fix branch and pass with this change.

The separate encryption-at-rest and environment-precedence concerns in #844 remain under review.

@Hydralerne
Hydralerne changed the base branch from main to feat/bugfix-integration-2026-09-15 September 15, 2026 19:27
@Hydralerne Hydralerne changed the title fix(api): mask build arguments and preserve secrets on round trips fix: protect build arguments across API and native SDK Sep 15, 2026
@Hydralerne
Hydralerne merged commit 8c20a9b into oblien:feat/bugfix-integration-2026-09-15 Sep 15, 2026
9 checks passed
@Hydralerne

Copy link
Copy Markdown
Member

Merged into feat/bugfix-integration-2026-09-15 via 8c20a9b, with Abdullah Mohamed's original bcdc840 commit preserved. Main is unchanged; the combined review is draft PR #891.

The adaptation moves protection into the shared platform, exposes fingerprints in the SDK contract, preserves masked build-argument interpolation on Compose sync, and keeps authorized source editing scans usable. Real PGlite/native/HTTP tests cover writes, old and new deployment snapshots, build status, drift, read-only tokens and tenant isolation.

Validation: 292 API tests and 29 SDK tests passed; API typecheck and documentation checks passed. Both historical-disclosure and masked-sync regressions fail on the pre-fix code and pass after the change. Every GitHub CI job passed: https://github.com/oblien/openship/actions/runs/35015115546

Issue #854 is fixed on the integration branch, awaiting merge to main. The separate #844 work remains open.

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.

[Bug] buildArgs returned unmasked in the deployments API while the same key is masked in environment

2 participants