Skip to content

add socket tier 1 reachability analysis#142

Open
kanwalpreetd wants to merge 1 commit into
stellar:masterfrom
kanwalpreetd:master
Open

add socket tier 1 reachability analysis#142
kanwalpreetd wants to merge 1 commit into
stellar:masterfrom
kanwalpreetd:master

Conversation

@kanwalpreetd

Copy link
Copy Markdown
Contributor

Copilot AI review requested due to automatic review settings June 12, 2026 14:21

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b3d82cf4ac

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

# annotation that GitHub Actions renders as a yellow run-level
# warning without failing the job.
set +e
socket scan create --reach \

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Wait for the Socket report before marking success

For scheduled/manual runs this command can mark the job green before Socket has actually generated or evaluated the scan report: the Socket CLI docs/scan create --help state that socket scan create returns after creating the scan, while --report is what waits for and reads the generated report. As written, server-side vulnerability/policy failures or report-generation failures can happen after this step exits 0, so the workflow status no longer matches the documented GREEN/RED meaning; add --report if the job is intended to verify the completed scan.

Useful? React with 👍 / 👎.

# warning without failing the job.
set +e
socket scan create --reach \
--org=stellar \

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Associate scans with the js-xdr repository

This fresh Actions runner has no checked-in socket.json, and the Socket CLI docs say scans default to socket-default-repository / socket-default-branch unless --repo and --branch are supplied. In this workflow, scheduled scans for js-xdr will therefore be filed under the default placeholder repo/branch (and can collide with other repos using the same org token) instead of updating the intended Socket repository/alerts page; pass the repository and branch/default-branch explicitly.

Useful? React with 👍 / 👎.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a scheduled GitHub Actions workflow to run Socket’s “full application reachability” scan against the js-xdr repository so dependency vulnerabilities can be evaluated with reachability context.

Changes:

  • Adds a new scheduled + manual “Socket reachability scan” workflow.
  • Installs the Socket CLI and runs socket scan create --reach, emitting a GitHub Actions warning when Tier 2 reachability fallbacks are detected.
  • Pins actions/checkout and actions/setup-node to specific SHAs.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +58 to +60
- uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
with:
node-version: "20.20.2"
Comment on lines +61 to +62
- name: Enable Corepack (yarn/pnpm per repo packageManager)
run: corepack enable
@@ -0,0 +1,90 @@
# Socket reachability scan for js-xdr.
# For general Socket reachability documentation, see https://docs.socket.dev/docs/full-application-reachability
# Multi-ecosystem: Node (pnpm-lock.yaml) + Ruby (Gemfile).
Comment on lines +25 to +34
# THIS REPO STARTS YELLOW — a KNOWN upstream Coana bug, NOT your code or this
# scan setup:
# Coana's gem analyzer can't locate installed gems ("No load paths found");
# the 3 gem CVEs fall back to Tier 2. (The npm portion gets full Tier 1.)
# Reported to Socket; may be fixed upstream over time. Do NOT let this baseline
# yellow train the team to ignore yellow — a *new* yellow (a different Tier 2
# fallback that appears later) is a real signal worth investigating. After the
# initial rollout, the team may resolve the baseline yellow at its discretion
# (once Coana ships a fix, or by adjusting the scan) so GREEN becomes the
# normal state and any future yellow stands out.
Comment on lines +64 to +66
- name: Install Socket CLI
run: npm install -g socket

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.

2 participants