Skip to content

fix(deps): patch kin-openapi CVE-2026-73501 (VULN-252) - #247

Merged
GurinderRawala merged 2 commits into
coderabbit_micro_frontendfrom
vuln-252/kin-openapi-default-base
Sep 14, 2026
Merged

GurinderRawala merged 2 commits into
coderabbit_micro_frontendfrom
vuln-252/kin-openapi-default-base

Conversation

@GurinderRawala

@GurinderRawala GurinderRawala commented Sep 12, 2026 •

Copy link
Copy Markdown

Summary

Resolves VULN-252 / CVE-2026-73501 (GHSA-r277-6w6q-xmqw).
Replaces #246, which was mistakenly created from upstream main.

This is a fresh branch created directly from coderabbit_micro_frontend at d436d6b, not a rebase of upstream-main tooling changes.

  • Upgrade kin-openapi v0.127.0 → v0.144.0 and oapi-codegen to v2.8.0 (required for API compatibility).
  • Synchronize workspace module metadata and regenerate models affected by the generator update.
  • Preserve the default branch's CodeRabbit frontend, existing security fixes, Go 1.25.14/Alpine 3.23 image defaults, deployment workflows, Drone and lint configuration.
  • Keep CI scoped to Build and Test: production Docker build/startup-health check and focused Go codegen/schema tests. Existing CircleCI build-and-test remains; its Go image is aligned to Go 1.25 and its backend job now builds/tests instead of only downloading/tidying modules.
  • No Trivy, lint, K8s/CUE verification workflows or linter migration are introduced. Those came from the wrong upstream branch and are absent here.
  • Docker JS builder includes the Yarn test-plugin workspace, skips the unsupported Cypress binary download, supplies Python setuptools and uses bundled Node headers for native addons.

Vulnerability

openapi3filter.ValidationHandler.Load() defaults missing authentication to a no-op. Patched in v0.144.0. Grafana's inspected dependency graph did not include openapi3filter, but the module version ships in the server and is upgraded to remove the vulnerable dependency.

Verification

  • Go 1.25 full server compilation: passed on the corrected default-branch source.
  • go test ./pkg/codegen/... ./scripts/openapi3/...: passed.
  • Generated CUE verification: passed locally (not added as a CI gate).
  • Build/Test workflow and CircleCI YAML parsed successfully.
  • Full corrected-branch local Docker build: passed using the default Go/Node/Alpine image versions (JS_PLATFORM=linux/arm64 for the Mac).
  • Container startup/database health and independent Playwright login, dashboard save/read and panel rendering: passed at http://127.0.0.1:3301.
  • GitHub Test, CircleCI build-and-test and CodeRabbit: passed on the latest head. GitHub full Docker Build remains in progress.
  • Upstream Cypress smoke spec failed on a selector absent from the customized UI; it is not a PR gate and was not reported as passing.

No images are pushed or deployed by the new PR workflow.

Summary by CodeRabbit

  • Compatibility

    • Updated dashboard and data-source query models to support more flexible values and optional identifiers.
    • Added support for additional query, option, filter, and operator value formats.
  • Testing

    • Added automated checks for production container startup, health readiness, code generation, and API schema conversion.
    • Expanded pull request validation to build and verify the production image.
  • Maintenance

    • Updated the Go toolchain and refreshed supporting libraries across backend modules.
    • Improved production build configuration for more reliable application setup.

Upgrade kin-openapi to v0.144.0 and compatible oapi-codegen, sync workspace dependencies and generated models. Preserve CodeRabbit's existing Go 1.25.14/Alpine 3.23 and deployment configuration. Add only Build/Test PR jobs and align existing CircleCI build/test tooling.
@linear

linear Bot commented Sep 12, 2026

Copy link
Copy Markdown

VULN-252

@coderabbitai

coderabbitai Bot commented Sep 12, 2026 •

Copy link
Copy Markdown

Review Change StackReview Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Central YAML (base), Organization UI (inherited)

Review profile: CHILL

Plan: Enterprise

Run ID: 977e023e-1078-400e-89fd-7af99f9c815d

📥 Commits

Reviewing files that changed from the base of the PR and between 2016ca0 and 6474b72.

📒 Files selected for processing (1)
  • .github/workflows/build-test.yml
🔗 Linked repositories identified

CodeRabbit considers these linked repositories for cross-repo context during reviews:

  • coderabbitai/bitbucket (manual)

Included review availability: Your plan provides up to 100 included reviews per hour; 97 remain after this review.

📜 Recent review details
⏰ Context from checks skipped due to timeout. (2)
  • GitHub Check: Build
  • GitHub Check: build-and-test
🧰 Additional context used
🔀 Multi-repo context coderabbitai/bitbucket

Linked repositories findings

coderabbitai/bitbucket

  • This package consumes OpenAPI documents through openapi-typescript and openapi-fetch, not Go kin-openapi or oapi-codegen; its dependencies are declared in package.json:46-67. [::coderabbitai/bitbucket::]
  • OpenAPI clients are generated from remote Bitbucket Cloud/Data Center Swagger files by scripts/openapi.sh:3-14; the PR’s Go dependency upgrades do not alter this generation path. [::coderabbitai/bitbucket::]
  • Webhook event types are locally implemented under src/server/webhooks/events; no shared Go webhook contract or affected validation API was found. [::coderabbitai/bitbucket::]
🔇 Additional comments (1)
.github/workflows/build-test.yml (1)

35-35: LGTM!


📝 Walkthrough

Walkthrough

The PR upgrades kin-openapi and oapi-codegen, refreshes workspace Go modules, and regenerates affected dashboard and data source models. It adds production Docker startup and health checks, focused Go tests, and updated CircleCI validation. The Docker JavaScript build now supports test plugins, native Node builds, and skipped Cypress binary installation.

Priority: ⬆️ High

Severity of issue fixed: High

Merge Risk: ⚪ Minimal · up to 6474b

No actionable correctness, security, integrity, or availability issue has been identified in the current change.

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely identifies the dependency fix, the affected package, the CVE, and the vulnerability tracking ID. It matches the main objective of the changeset.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch vuln-252/kin-openapi-default-base
✨ Simplify code
  • Create PR with simplified code
  • Commit simplified code in branch vuln-252/kin-openapi-default-base

A rabbit checks the OpenAPI gate
Fresh models hop in, aligned and straight
Go builds sparkle, containers start
Health checks thump with a steady heart
Dependencies shed their winter coat
Safe paths carry every note

Comment @coderabbitai help to get the list of available commands.

@GurinderRawala

Copy link
Copy Markdown
Author

Corrected-branch verification: full local Docker image built successfully using the default Go 1.25.14, Alpine 3.23 and node:20-alpine images (only JS_PLATFORM=linux/arm64 overridden for this Mac). Startup and database health pass. Independent Playwright check passed UI login, authenticated dashboard save/read and actual panel rendering. Existing upstream Cypress smoke spec has a selector incompatible with the customized dashboard UI (Create new panel button); it is not a PR gate and its failure is not reported as a pass. Go tests pass, including the GitHub Test job. CI contains only Build/Test plus the default branch’s existing CircleCI build-and-test; there is no added Trivy/lint/codegen workflow. PR #246 is closed. Fresh GitHub Build is still running.

@GurinderRawala

Copy link
Copy Markdown
Author

Release gate update: all PR checks passed for 6474b72 (Build, Test, CircleCI build-and-test and CodeRabbit). Dispatched the existing dev workflow: https://github.com/coderabbitai/grafana/actions/runs/34662819163 — image build/publish and downstream dispatch succeeded. The actual dev deployment in mono failed its protected Terraform plan gate: https://github.com/coderabbitai/mono/actions/runs/34663606783 . Plan: 308 additions, 0 changes, 17 destructions (service accounts); error: coderabbitdev contains protected destructive changes. I did not enable force_change or bypass this gate. Per the requested order, PR remains open and no production deployment was initiated. Infrastructure plan remediation/review is required before retrying dev and proceeding to merge/prod.

@GurinderRawala
GurinderRawala merged commit 6af8729 into coderabbit_micro_frontend Sep 14, 2026
5 checks passed
@GurinderRawala
GurinderRawala deleted the vuln-252/kin-openapi-default-base branch September 14, 2026 15:42
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.

1 participant