socketsecurity 2.13.1__tar.gz → 2.14.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/workflows/docker-stable.yml +2 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/workflows/release.yml +3 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/CHANGELOG.md +83 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/PKG-INFO +26 -24
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/README.md +24 -22
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/docs/ci-cd.md +76 -20
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/docs/cli-reference.md +30 -28
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/docs/troubleshooting.md +23 -2
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/pyproject.toml +2 -2
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/__init__.py +1 -1
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/config.py +5 -2
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/__init__.py +136 -89
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/classes.py +7 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/messages.py +163 -132
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/scm/github.py +54 -6
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/scm/gitlab.py +16 -1
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/scm_comments.py +33 -16
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/exit_codes.py +1 -5
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/output.py +5 -2
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/socketcli.py +14 -10
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_cli_exit_contract.py +8 -3
- socketsecurity-2.14.0/tests/core/test_existing_alerts.py +667 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_exit_codes.py +124 -3
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_strict_blocking_duplicates.py +7 -3
- socketsecurity-2.14.0/tests/core/test_strict_blocking_no_manifest_change.py +398 -0
- socketsecurity-2.14.0/tests/unit/test_comment_event_flow.py +256 -0
- socketsecurity-2.14.0/tests/unit/test_comment_package_links.py +222 -0
- socketsecurity-2.14.0/tests/unit/test_github_event_filter.py +269 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_ignore_telemetry_filtering.py +2 -3
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_include_dirs.py +57 -5
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_messages.py +18 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_pr_comment_rendering.py +128 -1
- socketsecurity-2.14.0/tests/unit/test_strict_blocking_report_only.py +88 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/uv.lock +5 -5
- socketsecurity-2.14.0/workflows/github-actions-comments.yml +36 -0
- socketsecurity-2.14.0/workflows/github-actions-push.yml +32 -0
- socketsecurity-2.14.0/workflows/github-actions.yml +35 -0
- socketsecurity-2.13.1/tests/core/test_existing_alerts.py +0 -380
- socketsecurity-2.13.1/workflows/github-actions.yml +0 -63
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.dockerignore +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/CODEOWNERS +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/PULL_REQUEST_TEMPLATE/bug-fix.md +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/PULL_REQUEST_TEMPLATE/feature.md +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/PULL_REQUEST_TEMPLATE/improvement.md +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/PULL_REQUEST_TEMPLATE.md +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/actions/setup-docker/action.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/actions/setup-hatch/action.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/actions/setup-sfw/action.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/dependabot.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/workflows/dependency-audit.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/workflows/dependency-review.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/workflows/e2e-image.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/workflows/e2e-test.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/workflows/package-check.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/workflows/pr-preview.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/workflows/python-tests.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/workflows/version-check.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.github/zizmor.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.gitignore +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.hooks/sync_version.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.pre-commit-config.yaml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/.python-version +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/CONTRIBUTING.md +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/Dockerfile +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/Dockerfile.preview +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/LICENSE +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/Makefile +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/benchmarks/manifest_discovery.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/docs/development.md +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/examples/config/sarif-dashboard-parity.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/examples/config/sarif-dashboard-parity.toml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/examples/config/sarif-diff-ci-cd.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/examples/config/sarif-diff-ci-cd.toml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/examples/config/sarif-instance-detail.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/examples/config/sarif-instance-detail.toml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/instructions/gitlab-commit-status/uat.md +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/pytest.ini +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/scripts/build_container.sh +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/scripts/build_container_flexible.sh +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/scripts/deploy-test-docker.sh +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/scripts/deploy-test-pypi.sh +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/scripts/docker-entrypoint.sh +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/scripts/run.sh +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/session.md +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socket.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/alert_selection.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/cli_client.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/cli_run.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/exceptions.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/git_interface.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/git_remote.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/helper/__init__.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/helper/socket_facts_loader.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/lazy_file_loader.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/log_uploader.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/logging.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/pull_request.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/resource_utils.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/scm/__init__.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/scm/base.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/scm/client.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/socket_config.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/streaming.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/tools/coana-cache.mjs +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/tools/reachability.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/core/utils.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/fossa_compat.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/plugins/__init__.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/plugins/base.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/plugins/formatters/__init__.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/plugins/formatters/slack.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/plugins/jira.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/plugins/manager.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/plugins/slack.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/plugins/teams.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/socketsecurity/plugins/webhook.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/__init__.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/conftest.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/create_diff_input.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_alert_consolidation.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_diff_alerts.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_diff_generation.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_diff_scan_polling.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_facts_compression.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_full_scan_outputs.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_has_manifest_files.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_invalid_facts_marker.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_package_and_alerts.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_sdk_methods.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/core/test_supporting_methods.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/data/fullscans/create_response.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/data/fullscans/diff/stream_diff.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/data/fullscans/diff/stream_diff_full.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/data/fullscans/head_scan/metadata.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/data/fullscans/head_scan/stream_scan.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/data/fullscans/head_scan/stream_scan_full.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/data/fullscans/new_scan/metadata.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/data/fullscans/new_scan/stream_scan.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/data/repos/repo_info_error.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/data/repos/repo_info_no_head.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/data/repos/repo_info_success.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/data/settings/security-policy.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/fixtures/simple-cargo/Cargo.lock +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/fixtures/simple-cargo/Cargo.toml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/fixtures/simple-cargo/src/main.rs +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/fixtures/simple-npm/index.js +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/fixtures/simple-npm/package.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/fixtures/simple-pypi/requirements.txt +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/reach_facts.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/run-with-retries.sh +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/validate-gitlab.sh +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/validate-json.sh +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/validate-reachability.sh +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/validate-sarif.sh +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/e2e/validate-scan.sh +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/fixtures/fossa/README.md +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/fixtures/fossa/fossa-analyze-empty.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/fixtures/fossa/fossa-analyze-populated.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/fixtures/fossa/fossa-sbom-empty-deep.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/fixtures/fossa/fossa-sbom-populated.json +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/__init__.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_alert_selection.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_cli_config.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_cli_run.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_client.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_commit_message_truncation.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_config.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_dependency_overview.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_disable_ignore.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_dockerfile.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_exclude_paths.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_fossa_compat.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_fossa_parity.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_full_scan_retry.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_git_interface.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_git_remote.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_github_buildkite_config.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_gitlab_auth.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_gitlab_auth_fallback.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_gitlab_commit_status.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_gitlab_format.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_ignore_authorization.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_log_uploader.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_manifest_discovery.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_output.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_pull_request_context.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_reachability.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_scan_scope.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_slack_plugin.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_slack_severity_normalization.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_socketcli.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_streaming.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_summary_text.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_tier1_finalize.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/tests/unit/test_user_agent.py +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/workflows/bitbucket-pipelines.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/workflows/buildkite.yml +0 -0
- {socketsecurity-2.13.1 → socketsecurity-2.14.0}/workflows/gitlab-ci.yml +0 -0
|
@@ -126,8 +126,11 @@ jobs:
|
|
|
126
126
|
# Attach an SPDX SBOM generated from the built image, next to the
|
|
127
127
|
# provenance attestation the action already adds.
|
|
128
128
|
sbom: true
|
|
129
|
+
# `stable` follows `latest`. To point it at an older release, run
|
|
130
|
+
# docker-stable.yml.
|
|
129
131
|
tags: |
|
|
130
132
|
socketdev/cli:latest
|
|
133
|
+
socketdev/cli:stable
|
|
131
134
|
socketdev/cli:${{ env.VERSION }}
|
|
132
135
|
build-args: |
|
|
133
136
|
CLI_VERSION=${{ env.VERSION }}
|
|
@@ -1,5 +1,88 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 2.14.0
|
|
4
|
+
|
|
5
|
+
### Upgrade notes
|
|
6
|
+
|
|
7
|
+
- Without a GitHub or GitLab SCM adapter, `--strict-blocking` now compares scans
|
|
8
|
+
even when no manifest changed. This includes default-branch pushes and scans of
|
|
9
|
+
non-git paths. These runs can now fail on Block findings or comparison errors
|
|
10
|
+
and need the [API token scopes for comparison runs](docs/troubleshooting.md#api-token-permissions).
|
|
11
|
+
- If you use the GitHub Actions example, replace the combined workflow with the
|
|
12
|
+
[PR workflow](workflows/github-actions.yml) and require its `socket-security`
|
|
13
|
+
check. Install the [push workflow](workflows/github-actions-push.yml) in the
|
|
14
|
+
same change: the PR workflow doesn't run on pushes, so without it the
|
|
15
|
+
default-branch baseline stops updating and PR comparisons run against an old
|
|
16
|
+
scan. Install the
|
|
17
|
+
[ignore-command workflow](workflows/github-actions-comments.yml) if you use PR
|
|
18
|
+
ignore commands.
|
|
19
|
+
|
|
20
|
+
### Changed
|
|
21
|
+
|
|
22
|
+
- Updated the Socket Python SDK (`socketdev`) to 3.6.4. This can increase
|
|
23
|
+
advisory counts in full-scan JSON, SARIF, and GitLab security reports, and
|
|
24
|
+
in the existing findings shown in GitLab security and FOSSA diff reports.
|
|
25
|
+
- Skipped GitHub events and GitLab pipeline sources now warn that no scan ran.
|
|
26
|
+
|
|
27
|
+
### Fixed
|
|
28
|
+
|
|
29
|
+
- `--strict-blocking` counts distinct advisories on unchanged dependencies and
|
|
30
|
+
lists findings that persist after a version change in the Existing alerts
|
|
31
|
+
table. When a finding has both Warn and Block actions, Block takes precedence.
|
|
32
|
+
- SARIF reports use advisory IDs to distinguish findings on the same package
|
|
33
|
+
and manifest.
|
|
34
|
+
- Comparisons with missing or invalid package lists fail with exit `3` by
|
|
35
|
+
default. `--exit-code-on-api-error` can remap the code, and
|
|
36
|
+
`--disable-blocking` takes precedence.
|
|
37
|
+
- `--strict-blocking` checks existing Block findings on code-only changes.
|
|
38
|
+
GitHub and GitLab pull request comments show those findings under Existing
|
|
39
|
+
alerts.
|
|
40
|
+
- With `--scm github`, reopened pull requests and pull requests marked ready for
|
|
41
|
+
review run the PR scan.
|
|
42
|
+
- GitHub pull request comment runs exit `0` and leave the Socket security
|
|
43
|
+
comment unchanged when there are no Socket ignore commands to process.
|
|
44
|
+
- Under `--strict-blocking --disable-blocking`, the PR/MR comment and console
|
|
45
|
+
summary no longer say that existing Block alerts fail the run.
|
|
46
|
+
- The "This package" link in GitHub and GitLab security comments opens the
|
|
47
|
+
affected package version on socket.dev. License findings for different
|
|
48
|
+
namespaces appear in separate rows, and generated ignore commands identify
|
|
49
|
+
the package by its scope or namespace.
|
|
50
|
+
- Large PR/MR security comments fit within GitHub's size limit and show how many
|
|
51
|
+
new or existing findings were omitted. Policy checks and reports use all findings.
|
|
52
|
+
|
|
53
|
+
### Documentation
|
|
54
|
+
|
|
55
|
+
- The [CI guide](docs/ci-cd.md#required-github-checks) describes GitHub required
|
|
56
|
+
checks and the GitHub Actions workflow migration.
|
|
57
|
+
- The README's upgrade notes for 2.13 and 2.14 are combined into one short
|
|
58
|
+
[section](README.md#upgrading-from-212-or-earlier).
|
|
59
|
+
- Clarified that `--include-module-folders` discovers dependency manifests.
|
|
60
|
+
Added a guide to scanning packages installed outside the lockfile with a
|
|
61
|
+
CycloneDX SBOM.
|
|
62
|
+
|
|
63
|
+
## 2.13.2
|
|
64
|
+
|
|
65
|
+
### Added
|
|
66
|
+
|
|
67
|
+
- Security and license alerts on a transitive dependency now name the direct
|
|
68
|
+
dependency that introduced it, under the manifest link. Up to five are listed.
|
|
69
|
+
|
|
70
|
+
### Changed
|
|
71
|
+
|
|
72
|
+
- Manifest file links in PR comments and reports pick the source host only from
|
|
73
|
+
`--scm`. The fallback that guessed GitHub, GitLab, or Bitbucket from the Socket
|
|
74
|
+
diff URL never produced a link and has been removed.
|
|
75
|
+
- Each release now also tags `socketdev/cli:stable`, so `stable` and `latest`
|
|
76
|
+
both point at the newest release. Previously `stable` moved only when someone
|
|
77
|
+
promoted a release by hand. Pin `socketdev/cli:<version>` for reproducible CI
|
|
78
|
+
runs.
|
|
79
|
+
|
|
80
|
+
### Fixed
|
|
81
|
+
|
|
82
|
+
- Scoped npm packages and Maven artifacts named as the introducing dependency
|
|
83
|
+
keep their scope or group ID (`npm/@acme/widgets@1.2.0`, not
|
|
84
|
+
`npm/widgets@1.2.0`).
|
|
85
|
+
|
|
3
86
|
## 2.13.1
|
|
4
87
|
|
|
5
88
|
### Documentation
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: socketsecurity
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.14.0
|
|
4
4
|
Summary: Socket Security CLI for CI/CD
|
|
5
5
|
Project-URL: Homepage, https://socket.dev
|
|
6
6
|
Author-email: Douglas Coburn <douglas@socket.dev>
|
|
@@ -44,7 +44,7 @@ Requires-Dist: packaging==26.3
|
|
|
44
44
|
Requires-Dist: prettytable==3.18.0
|
|
45
45
|
Requires-Dist: python-dotenv==1.2.4
|
|
46
46
|
Requires-Dist: requests==2.34.2
|
|
47
|
-
Requires-Dist: socketdev==3.6.
|
|
47
|
+
Requires-Dist: socketdev==3.6.4
|
|
48
48
|
Provides-Extra: dev
|
|
49
49
|
Requires-Dist: hatch==1.18.2; extra == 'dev'
|
|
50
50
|
Requires-Dist: pre-commit==4.7.0; extra == 'dev'
|
|
@@ -266,7 +266,7 @@ JSON:
|
|
|
266
266
|
|
|
267
267
|
Prebuilt workflow examples:
|
|
268
268
|
|
|
269
|
-
-
|
|
269
|
+
- GitHub Actions for [pull requests](https://github.com/SocketDev/socket-python-cli/blob/main/workflows/github-actions.yml), [pushes](https://github.com/SocketDev/socket-python-cli/blob/main/workflows/github-actions-push.yml), and [ignore commands](https://github.com/SocketDev/socket-python-cli/blob/main/workflows/github-actions-comments.yml)
|
|
270
270
|
- [Buildkite](https://github.com/SocketDev/socket-python-cli/blob/main/workflows/buildkite.yml)
|
|
271
271
|
- [GitLab CI](https://github.com/SocketDev/socket-python-cli/blob/main/workflows/gitlab-ci.yml)
|
|
272
272
|
- [Bitbucket Pipelines](https://github.com/SocketDev/socket-python-cli/blob/main/workflows/bitbucket-pipelines.yml)
|
|
@@ -329,27 +329,29 @@ scan exit `0` on *both* findings and outages — the `soft_fail: 100` rule would
|
|
|
329
329
|
never match, and real findings would stop blocking. That's usually not what you
|
|
330
330
|
want.
|
|
331
331
|
|
|
332
|
-
### Upgrading
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
332
|
+
### Upgrading from 2.12 or earlier
|
|
333
|
+
|
|
334
|
+
2.13 and 2.14 change exit codes and what `--strict-blocking` checks:
|
|
335
|
+
|
|
336
|
+
- **Exit codes:** invalid flags or configuration exit `2`, Ctrl+C exits `130`,
|
|
337
|
+
and setup failures such as a missing token use the infrastructure-error code
|
|
338
|
+
(`3` by default). Blocking findings still exit `1`. See
|
|
339
|
+
[Exit codes in CI](docs/ci-cd.md#exit-codes-in-ci).
|
|
340
|
+
- **Config files** are validated before credentials or network setup. Use native
|
|
341
|
+
JSON/TOML booleans, a positive integer `timeout` and an array for `files`.
|
|
342
|
+
- **`--strict-blocking`** fails on existing Block alerts, counts each advisory
|
|
343
|
+
separately, and compares code-only changes too, so pipelines can fail on
|
|
344
|
+
alerts they used to pass. Without `--scm github` or `--scm gitlab`, that
|
|
345
|
+
includes default-branch pushes, which need the `full-scans:list` and
|
|
346
|
+
`repo:list` token scopes; see
|
|
347
|
+
[API token permissions](docs/troubleshooting.md#api-token-permissions).
|
|
348
|
+
- **GitHub Actions example:** if you copied it, put the
|
|
349
|
+
[PR workflow](workflows/github-actions.yml) at the existing path and add the
|
|
350
|
+
[push workflow](workflows/github-actions-push.yml) in the same change. See
|
|
351
|
+
[Required GitHub checks](docs/ci-cd.md#required-github-checks).
|
|
352
|
+
|
|
353
|
+
GitLab report findings get new IDs once. The [release notes](CHANGELOG.md) have
|
|
354
|
+
the details.
|
|
353
355
|
|
|
354
356
|
## Common gotchas
|
|
355
357
|
|
|
@@ -205,7 +205,7 @@ JSON:
|
|
|
205
205
|
|
|
206
206
|
Prebuilt workflow examples:
|
|
207
207
|
|
|
208
|
-
-
|
|
208
|
+
- GitHub Actions for [pull requests](https://github.com/SocketDev/socket-python-cli/blob/main/workflows/github-actions.yml), [pushes](https://github.com/SocketDev/socket-python-cli/blob/main/workflows/github-actions-push.yml), and [ignore commands](https://github.com/SocketDev/socket-python-cli/blob/main/workflows/github-actions-comments.yml)
|
|
209
209
|
- [Buildkite](https://github.com/SocketDev/socket-python-cli/blob/main/workflows/buildkite.yml)
|
|
210
210
|
- [GitLab CI](https://github.com/SocketDev/socket-python-cli/blob/main/workflows/gitlab-ci.yml)
|
|
211
211
|
- [Bitbucket Pipelines](https://github.com/SocketDev/socket-python-cli/blob/main/workflows/bitbucket-pipelines.yml)
|
|
@@ -268,27 +268,29 @@ scan exit `0` on *both* findings and outages — the `soft_fail: 100` rule would
|
|
|
268
268
|
never match, and real findings would stop blocking. That's usually not what you
|
|
269
269
|
want.
|
|
270
270
|
|
|
271
|
-
### Upgrading
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
271
|
+
### Upgrading from 2.12 or earlier
|
|
272
|
+
|
|
273
|
+
2.13 and 2.14 change exit codes and what `--strict-blocking` checks:
|
|
274
|
+
|
|
275
|
+
- **Exit codes:** invalid flags or configuration exit `2`, Ctrl+C exits `130`,
|
|
276
|
+
and setup failures such as a missing token use the infrastructure-error code
|
|
277
|
+
(`3` by default). Blocking findings still exit `1`. See
|
|
278
|
+
[Exit codes in CI](docs/ci-cd.md#exit-codes-in-ci).
|
|
279
|
+
- **Config files** are validated before credentials or network setup. Use native
|
|
280
|
+
JSON/TOML booleans, a positive integer `timeout` and an array for `files`.
|
|
281
|
+
- **`--strict-blocking`** fails on existing Block alerts, counts each advisory
|
|
282
|
+
separately, and compares code-only changes too, so pipelines can fail on
|
|
283
|
+
alerts they used to pass. Without `--scm github` or `--scm gitlab`, that
|
|
284
|
+
includes default-branch pushes, which need the `full-scans:list` and
|
|
285
|
+
`repo:list` token scopes; see
|
|
286
|
+
[API token permissions](docs/troubleshooting.md#api-token-permissions).
|
|
287
|
+
- **GitHub Actions example:** if you copied it, put the
|
|
288
|
+
[PR workflow](workflows/github-actions.yml) at the existing path and add the
|
|
289
|
+
[push workflow](workflows/github-actions-push.yml) in the same change. See
|
|
290
|
+
[Required GitHub checks](docs/ci-cd.md#required-github-checks).
|
|
291
|
+
|
|
292
|
+
GitLab report findings get new IDs once. The [release notes](CHANGELOG.md) have
|
|
293
|
+
the details.
|
|
292
294
|
|
|
293
295
|
## Common gotchas
|
|
294
296
|
|
|
@@ -84,11 +84,13 @@ they also hide findings and usage errors. Even with exit `0`, a setup/API failur
|
|
|
84
84
|
does not mean a clean scan; check the logs for a completed report.
|
|
85
85
|
|
|
86
86
|
Findings block only when a [diff comparison runs](#scan-type-by-pipeline).
|
|
87
|
-
SCM event filters can also skip unsupported events with exit `0
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
87
|
+
SCM event filters can also skip unsupported events with exit `0` and a warning
|
|
88
|
+
(see [Skipped events](#skipped-events)); confirm a report was created when
|
|
89
|
+
validating a new workflow.
|
|
90
|
+
The CLI treats comparisons marked incomplete or returned with missing or
|
|
91
|
+
invalid package lists as infrastructure failures. With `--strict-blocking`,
|
|
92
|
+
incomplete existing-alert data is also an infrastructure failure. See the
|
|
93
|
+
[upgrade notes](../README.md#upgrading-from-212-or-earlier) when updating existing CI rules.
|
|
92
94
|
|
|
93
95
|
## Config file usage in CI
|
|
94
96
|
|
|
@@ -137,6 +139,11 @@ Buildkite-specific config-file format is required.
|
|
|
137
139
|
SOCKET_SECURITY_API_TOKEN: ${{ secrets.SOCKET_SECURITY_API_TOKEN }}
|
|
138
140
|
```
|
|
139
141
|
|
|
142
|
+
With `--scm github`, `issue_comment` runs process Socket ignore commands on the
|
|
143
|
+
pull request. When there are no commands to process, the run exits `0` and
|
|
144
|
+
leaves the security comment unchanged. Use a dedicated `pull_request` scan job
|
|
145
|
+
for any required check that gates merges on scan findings.
|
|
146
|
+
|
|
140
147
|
#### GitHub Actions: scan changed monorepo workspaces independently
|
|
141
148
|
|
|
142
149
|
GitHub Actions `paths` filters only decide whether a workflow starts. They do not
|
|
@@ -499,27 +506,75 @@ pipelines:
|
|
|
499
506
|
|
|
500
507
|
## Scan type by pipeline
|
|
501
508
|
|
|
502
|
-
With `--scm github` or `--scm gitlab`, the
|
|
509
|
+
With `--scm github` or `--scm gitlab`, the adapter uses the event and PR/MR
|
|
510
|
+
context to select the scan type. A push given a PR/MR number can use the
|
|
511
|
+
comparison path.
|
|
503
512
|
|
|
504
513
|
| Event | Scan | Blocks the build |
|
|
505
514
|
|:------|:-----|:-----------------|
|
|
506
|
-
|
|
|
507
|
-
|
|
|
515
|
+
| Supported pull request / merge request events | Diff scan against the repository's baseline when a comparison runs | Yes, on new blocking alerts and on existing blockers with `--strict-blocking` |
|
|
516
|
+
| Push without a PR/MR number, including default-branch pushes | Full scan | No blocking on findings |
|
|
508
517
|
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
518
|
+
With changed-file detection, a PR/MR with no supported manifest change runs a
|
|
519
|
+
full scan by default. Use `--strict-blocking` or `--ignore-commit-files` to
|
|
520
|
+
compare it. Full scans report through the Dashboard. A branch pipeline without
|
|
521
|
+
PR/MR context stays in full-scan mode even with `--enable-diff`,
|
|
522
|
+
`--ignore-commit-files`, or `--strict-blocking`.
|
|
514
523
|
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
524
|
+
Without a GitHub or GitLab SCM adapter, `--strict-blocking` runs a comparison
|
|
525
|
+
even when no supported manifest changed. This includes default-branch pushes and
|
|
526
|
+
scans of non-git paths. A Block finding exits `1`. A comparison infrastructure
|
|
527
|
+
error exits `3` by default. Check the [API token scopes for comparison runs](troubleshooting.md#api-token-permissions)
|
|
528
|
+
when upgrading a pipeline that previously ran only full scans.
|
|
519
529
|
|
|
520
530
|
`--generate-license` and `--legal-format fossa` work on both paths; a full scan
|
|
521
531
|
fetches the package list for them.
|
|
522
532
|
|
|
533
|
+
### Skipped events
|
|
534
|
+
|
|
535
|
+
With `--scm github`, `pull_request` runs scan on the `opened`, `synchronize`,
|
|
536
|
+
`reopened` and `ready_for_review` actions. Other actions (`closed`, `labeled`,
|
|
537
|
+
`edited`, and others) and unsupported events log a warning and exit `0` without
|
|
538
|
+
scanning. `issue_comment` handles ignore commands. With `--scm gitlab`, the
|
|
539
|
+
recognized scan sources are `web`, `merge_request_event`, `push`, `api`, and
|
|
540
|
+
`pipeline`. Other sources, apart from the comment flow, also warn and exit `0`
|
|
541
|
+
without scanning.
|
|
542
|
+
|
|
543
|
+
- A GitHub merge queue evaluates required checks on the `merge_group` commit.
|
|
544
|
+
The CLI skips that event. Use a check that scans the merge group for
|
|
545
|
+
[merge queue enforcement](https://docs.github.com/en/pull-requests/how-tos/merge-and-close-pull-requests/troubleshooting-required-status-checks#status-checks-with-github-actions-and-a-merge-queue).
|
|
546
|
+
- GitHub runs `pull_request_target` in the base repository context, and the CLI
|
|
547
|
+
skips it. Under GitHub's default fork settings, `pull_request` runs cannot
|
|
548
|
+
access the Socket API secret. The CLI exits with its infrastructure error code
|
|
549
|
+
if the token is missing. See GitHub's guidance for
|
|
550
|
+
[securing workflows that handle fork PRs](https://docs.github.com/en/actions/reference/security/securely-using-pull_request_target).
|
|
551
|
+
|
|
552
|
+
### Required GitHub checks
|
|
553
|
+
|
|
554
|
+
Use the [PR workflow](../workflows/github-actions.yml) for the required
|
|
555
|
+
`socket-security` check. If your workflow skips drafts, include
|
|
556
|
+
`ready_for_review` in its `pull_request.types` so marking a PR ready starts the scan.
|
|
557
|
+
Use the [push workflow](../workflows/github-actions-push.yml) to update the
|
|
558
|
+
default-branch baseline and scan branch pushes. Use the
|
|
559
|
+
[ignore-command workflow](../workflows/github-actions-comments.yml) if your
|
|
560
|
+
repository handles ignore commands in PR comments.
|
|
561
|
+
|
|
562
|
+
GitHub normally checks the PR's test merge commit when it has a status and
|
|
563
|
+
otherwise checks the head commit. The default PR checkout uses the test merge
|
|
564
|
+
commit, while a push run uses the pushed commit. Keep the required job name
|
|
565
|
+
exclusive to the PR workflow in either setup. A job skipped by a job-level
|
|
566
|
+
`if` in a shared workflow can still report a successful check. See GitHub's
|
|
567
|
+
[required status check rules](https://docs.github.com/en/pull-requests/how-tos/merge-and-close-pull-requests/troubleshooting-required-status-checks).
|
|
568
|
+
|
|
569
|
+
When replacing the combined example, copy the PR workflow to the existing
|
|
570
|
+
workflow path and remove any other jobs named `socket-security`. Confirm the
|
|
571
|
+
PR job reports the check named in branch protection. Add the push workflow in
|
|
572
|
+
the same change: the PR workflow doesn't run on pushes, so without it the
|
|
573
|
+
default-branch baseline stops updating and later PR comparisons run against an
|
|
574
|
+
old scan. If you use
|
|
575
|
+
`--strict-blocking` as a merge gate, verify a reopened PR with an existing
|
|
576
|
+
Block alert fails and a completed clean comparison passes.
|
|
577
|
+
|
|
523
578
|
## Pull request and Dashboard association
|
|
524
579
|
|
|
525
580
|
The CLI sends the resolved pull request number with each full scan and attaches
|
|
@@ -564,8 +619,9 @@ console output and Dashboard association but does not post a PR comment.
|
|
|
564
619
|
|
|
565
620
|
`socketdev/cli` on Docker Hub packages the CLI with the toolchains reachability
|
|
566
621
|
analysis runs on: Node.js, Go, Java, .NET, Rust, Ruby, pyenv, and PyPy on
|
|
567
|
-
`linux/amd64`. The toolchains are most of the image's size.
|
|
568
|
-
|
|
622
|
+
`linux/amd64`. The toolchains are most of the image's size. Each release is
|
|
623
|
+
published as `socketdev/cli:<version>`, and `latest` and `stable` both point at
|
|
624
|
+
the newest release. Pin a version tag for reproducible CI runs.
|
|
569
625
|
|
|
570
626
|
```sh
|
|
571
627
|
docker run --rm \
|
|
@@ -641,7 +697,7 @@ listed thinly or not at all.
|
|
|
641
697
|
|
|
642
698
|
Prebuilt examples in this repo:
|
|
643
699
|
|
|
644
|
-
- [
|
|
700
|
+
- GitHub Actions for [pull requests](../workflows/github-actions.yml), [pushes](../workflows/github-actions-push.yml), and [ignore commands](../workflows/github-actions-comments.yml)
|
|
645
701
|
- [`../workflows/buildkite.yml`](../workflows/buildkite.yml)
|
|
646
702
|
- [`../workflows/gitlab-ci.yml`](../workflows/gitlab-ci.yml)
|
|
647
703
|
- [`../workflows/bitbucket-pipelines.yml`](../workflows/bitbucket-pipelines.yml)
|
|
@@ -324,7 +324,7 @@ docs.socket.dev use `SOCKET_SECURITY_API_KEY`. Either works. If both are set,
|
|
|
324
324
|
| Parameter | Required | Default | Description |
|
|
325
325
|
|:-------------------------|:---------|:--------|:------------------------------------------------------------------------------------------------------|
|
|
326
326
|
| `--default-branch` | False | *auto* | Make this branch the default branch (auto-detected from git and CI environment when not specified) |
|
|
327
|
-
| `--include-module-folders` | False | False |
|
|
327
|
+
| `--include-module-folders` | False | False | Includes supported manifests found under `node_modules`, `bower_components`, and `jspm_packages` in manifest discovery. Equivalent to `--include-dirs node_modules,bower_components,jspm_packages`. Other discovery exclusions still apply. For an inventory of installed packages, see [Packages installed outside the lockfile](troubleshooting.md#packages-installed-outside-the-lockfile). |
|
|
328
328
|
|
|
329
329
|
#### Output Configuration
|
|
330
330
|
| Parameter | Required | Default | Description |
|
|
@@ -461,12 +461,12 @@ The CLI runs a pinned version of the Coana CLI, the analysis engine; it does **n
|
|
|
461
461
|
#### Advanced Configuration
|
|
462
462
|
| Parameter | Required | Default | Description |
|
|
463
463
|
|:-------------------------|:---------|:--------|:----------------------------------------------------------------------|
|
|
464
|
-
| `--ignore-commit-files` | False | False |
|
|
464
|
+
| `--ignore-commit-files` | False | False | Skip the changed-file check for comparisons eligible under the SCM event rules. |
|
|
465
465
|
| `--exit-code-on-api-error` | False | 3 | Remap infrastructure failures, including missing tokens, setup failures, incomplete scan data and unexpected runtime errors. Findings (`1`), usage errors (`2`) and Ctrl+C (`130`) are unaffected. `--disable-blocking` takes precedence. |
|
|
466
466
|
| `--disable-blocking` | False | False | Non-blocking CI mode: the CLI exits **0** even when blocking alerts are present (including with `--strict-blocking`). Also exits 0 on infrastructure errors (missing API or SCM token, Socket API failures, uncaught runtime errors) and interrupts, so the job is treated as successful while findings and errors are still logged. Invalid flags still exit **2**. Takes precedence over `--strict-blocking`. |
|
|
467
467
|
| `--disable-ignore` | False | False | Disable support for `@SocketSecurity ignore` commands in PR comments. When set, alerts cannot be suppressed via comments and ignore instructions are hidden from comment output. See [Who can ignore an alert](#who-can-ignore-an-alert). |
|
|
468
468
|
| `--ignore-authorization` | False | enforce | Who may suppress alerts with `@SocketSecurity ignore`. `enforce` requires write access and honors the command with a warning when the provider cannot report it; `strict` rejects it in that case; `off` honors any commenter. See [Who can ignore an alert](#who-can-ignore-an-alert). |
|
|
469
|
-
| `--strict-blocking` | False | False | Fail on
|
|
469
|
+
| `--strict-blocking` | False | False | Fail on new and existing Block findings, including on changes that touch no manifest. See [Strict Blocking Mode](#strict-blocking-mode). |
|
|
470
470
|
| `--enable-diff` | False | False | Enable diff mode even when using `--integration api` (forces diff mode without SCM integration) |
|
|
471
471
|
| `--scm` | False | api | Source control management type |
|
|
472
472
|
| `--timeout` | False | 1200 | Positive integer timeout in seconds for each API request. This is not a total CLI runtime limit and does not limit local discovery, Git, or reachability analysis. |
|
|
@@ -604,19 +604,12 @@ Bot mode (`bot_configs` array items):
|
|
|
604
604
|
|
|
605
605
|
## Strict Blocking Mode
|
|
606
606
|
|
|
607
|
-
|
|
607
|
+
In a scan comparison, `--strict-blocking` fails the build on new and existing findings with a **Block** action.
|
|
608
608
|
|
|
609
609
|
### Standard vs Strict Blocking Behavior
|
|
610
610
|
|
|
611
|
-
**
|
|
612
|
-
-
|
|
613
|
-
- ❌ Fails only on NEW violations from your changes
|
|
614
|
-
- 🟡 Existing violations are ignored
|
|
615
|
-
|
|
616
|
-
**Strict Blocking Behavior (`--strict-blocking`)**:
|
|
617
|
-
- ✅ Passes only if NO violations exist (new or existing)
|
|
618
|
-
- ❌ Fails on ANY violation (new OR existing)
|
|
619
|
-
- 🔴 Enforces zero-tolerance policy
|
|
611
|
+
- **Default** fails on findings introduced by the change that have a **Block** action.
|
|
612
|
+
- **Strict blocking** also checks unchanged dependencies and findings that persist after a version change. For example, if an upgrade leaves a blocking advisory unresolved, the run still fails and the advisory appears under **Existing alerts** at the new version.
|
|
620
613
|
|
|
621
614
|
### Usage Examples
|
|
622
615
|
|
|
@@ -667,10 +660,20 @@ Security issues detected by Socket Security:
|
|
|
667
660
|
|
|
668
661
|
### Important Notes
|
|
669
662
|
|
|
670
|
-
- **
|
|
671
|
-
- **
|
|
672
|
-
- **
|
|
673
|
-
- **
|
|
663
|
+
- **Scan scope**. Strict mode compares the configured scan scope even when no supported manifest changed. Scan options such as `--sub-path` and `--reach-use-only-pregenerated-sboms` still control what the CLI submits. With `--scm`, GitHub and GitLab branch pipelines without PR/MR context perform non-blocking full scans. See [Scan type by pipeline](ci-cd.md#scan-type-by-pipeline).
|
|
664
|
+
- **With `--reach`**. With no explicit baseline, the CLI looks for a default-branch head scan with reachability enabled. If none exists, the CLI compares against an empty baseline and classifies all findings as new. Scan the default branch with `--reach` too.
|
|
665
|
+
- **Policy actions**. Warn findings are reported. If the same finding has both Warn and Block actions, Block takes precedence.
|
|
666
|
+
- **Existing alerts come from the full scan**. The CLI fetches the current full scan when the comparison leaves out alerts on unchanged packages or when a dependency version changes. A failed fetch or a missing package in that response triggers the infrastructure-error exit code.
|
|
667
|
+
- **PR/MR comments**. The comment lists new alerts first, then existing alerts
|
|
668
|
+
with Block findings first in the existing-alerts table. License findings are
|
|
669
|
+
grouped by package, including its scope or namespace. **This package** opens
|
|
670
|
+
the affected version on socket.dev. Use the generated `@SocketSecurity ignore`
|
|
671
|
+
command to target the package's exact scope or namespace.
|
|
672
|
+
- **Comment size**. Large comments show how many new and existing alerts were
|
|
673
|
+
omitted to fit GitHub's size limit and link to the full report.
|
|
674
|
+
Policy checks and reports still use all findings. If you ignore every visible
|
|
675
|
+
alert, the comment keeps the omission notice. Use `@SocketSecurity ignore-all`
|
|
676
|
+
to clear all findings, including omitted ones.
|
|
674
677
|
- **Priority**: `--disable-blocking` takes precedence - if both flags are set, the build will always pass.
|
|
675
678
|
- **First Scan**: On the very first scan of a repository, there are no "existing" violations, so behavior is identical to standard mode.
|
|
676
679
|
|
|
@@ -769,25 +772,26 @@ The CLI determines which files to scan based on the following logic:
|
|
|
769
772
|
|
|
770
773
|
2. **`--files` Parameter Override**: When specified, this parameter takes precedence over git commit detection. It accepts a JSON array of file paths to check for manifest files.
|
|
771
774
|
|
|
772
|
-
3. **`--ignore-commit-files` Flag**:
|
|
775
|
+
3. **`--ignore-commit-files` Flag**: Skip the changed-file check for comparisons, subject to the SCM event type.
|
|
773
776
|
|
|
774
|
-
4. **Automatic Fallback**:
|
|
777
|
+
4. **Automatic Fallback**: When the changed-file check finds no supported manifest, the CLI normally runs a full scan. Strict mode compares scans so it can evaluate existing findings. See [Scan type by pipeline](ci-cd.md#scan-type-by-pipeline) for SCM event rules.
|
|
775
778
|
|
|
776
|
-
|
|
779
|
+
The changed-file list and `--files` select the scan type. Manifest discovery
|
|
780
|
+
uses the configured scan scope, including any `--sub-path` restrictions.
|
|
777
781
|
|
|
778
782
|
### Scanning Modes
|
|
779
783
|
|
|
780
784
|
- **Differential Mode**: When manifest files are detected in changes, performs a diff scan with PR/MR comment integration
|
|
781
|
-
- **
|
|
782
|
-
- **Force Mode**: With `--ignore-commit-files`,
|
|
785
|
+
- **Full Scan**: Reports findings to the Dashboard. SCM branch pipelines without PR/MR context use this mode.
|
|
786
|
+
- **Force Mode**: With `--ignore-commit-files`, compares regardless of which files changed on pipelines eligible for comparison.
|
|
783
787
|
- **Forced Diff Mode**: With `--enable-diff`, forces differential mode even when using `--integration api` (without SCM integration)
|
|
784
788
|
|
|
785
789
|
### Examples
|
|
786
790
|
|
|
787
791
|
- **Commit with manifest file**: If your commit includes changes to `package.json`, a differential scan will be triggered automatically with PR comment integration.
|
|
788
|
-
- **
|
|
792
|
+
- **Code-only commit**: The CLI runs a full scan by default. `--strict-blocking` selects a comparison on pipelines eligible for comparison.
|
|
789
793
|
- **Using `--files`**: If you specify `--files '["package.json"]'`, the CLI will check if this file exists and is a manifest file before determining scan type.
|
|
790
|
-
- **Using `--ignore-commit-files`**:
|
|
794
|
+
- **Using `--ignore-commit-files`**: Compare the configured scan scope regardless of which files changed when the pipeline supports comparison.
|
|
791
795
|
- **Using `--enable-diff`**: Forces diff mode without SCM integration - useful when you want differential scanning but are using `--integration api`. For example: `socketcli --integration api --enable-diff --target-path /path/to/repo`
|
|
792
796
|
- **Auto-detection**: Most CI/CD scenarios now work with just `socketcli --target-path /path/to/repo --scm github --pr-number $PR_NUM`
|
|
793
797
|
|
|
@@ -899,13 +903,11 @@ The GitLab Security Dashboard report and the JSON/SARIF diff outputs use differe
|
|
|
899
903
|
|
|
900
904
|
| Output Format | Default Alerts | With `--strict-blocking` |
|
|
901
905
|
|:---|:---|:---|
|
|
902
|
-
| `--enable-gitlab-security` |
|
|
906
|
+
| `--enable-gitlab-security` | New alerts and existing alerts on unchanged dependencies | Also includes findings that persist after a version change |
|
|
903
907
|
| `--enable-json` | New alerts only | New + existing alerts |
|
|
904
908
|
| `--enable-sarif` (diff scope) | New alerts only | New + existing alerts |
|
|
905
909
|
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
> **Tip:** If you use `--enable-json` alongside `--enable-gitlab-security`, the GitLab report may contain more vulnerabilities than the JSON output. This is expected. To make JSON output match, add `--strict-blocking`.
|
|
910
|
+
Enable `--strict-blocking` to include existing findings in JSON and diff-scope SARIF. Scan-based SARIF includes the advisory ID in the rule ID when available, so separate advisories on the same package and manifest remain distinguishable.
|
|
909
911
|
|
|
910
912
|
### Alert Ignoring via PR/MR Comments
|
|
911
913
|
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
| Exit `0` despite expected blockers | Check `--disable-blocking`, remapping to `0`, and whether the run produced a full scan instead of a diff. Full scans do not gate on findings. |
|
|
11
11
|
|
|
12
12
|
See [Exit codes in CI](ci-cd.md#exit-codes-in-ci) for the flag combinations and
|
|
13
|
-
[upgrade
|
|
13
|
+
[upgrade notes](../README.md#upgrading-from-212-or-earlier) for older pipeline rules.
|
|
14
14
|
|
|
15
15
|
## Repository lookup or creation fails
|
|
16
16
|
|
|
@@ -123,7 +123,7 @@ Flags add:
|
|
|
123
123
|
| `--reach` | `POST orgs/{org}/upload-manifest-files`, `POST tier1-reachability-scan/finalize` | `full-scans:create` |
|
|
124
124
|
| `--generate-license` | `POST orgs/{org}/purl` | `packages:list` |
|
|
125
125
|
| `--enable-json`, `--enable-sarif`, `--enable-gitlab-security` or `--generate-license` on a full scan | `GET orgs/{org}/full-scans/{id}` (scan contents) | `full-scans:list` |
|
|
126
|
-
| `--strict-blocking`, `--enable-gitlab-security` or `--legal-format fossa` on a run that compares scans | `GET orgs/{org}/full-scans/{id}` (alerts
|
|
126
|
+
| `--strict-blocking`, `--enable-gitlab-security` or `--legal-format fossa` on a run that compares scans | `GET orgs/{org}/full-scans/{id}` (existing alerts) | `full-scans:list` |
|
|
127
127
|
|
|
128
128
|
`--reach` also runs the analysis engine with the same token. The engine reports to the
|
|
129
129
|
`tier1-reachability-scan/*` endpoints, which check `full-scans:create`.
|
|
@@ -232,6 +232,27 @@ by the comparison step that follows.
|
|
|
232
232
|
- Every vulnerability reported as `INSTALL ERROR`: the engine could not install your dependencies. Allow the ecosystem's package registry, or install dependencies in the target path before running `--reach`.
|
|
233
233
|
- See **Reachability network access** in the [CLI reference](cli-reference.md) for the full list of hosts.
|
|
234
234
|
|
|
235
|
+
## Packages installed outside the lockfile
|
|
236
|
+
|
|
237
|
+
Packages present only on disk, such as packages that a `postinstall` script adds without updating the lockfile, can be missing from a manifest-based scan.
|
|
238
|
+
|
|
239
|
+
`--include-module-folders` lets the CLI discover supported manifests in `node_modules`, `bower_components`, and `jspm_packages`, including nested directories. Other directory and path exclusions still apply, and discovery skips symlinked directories. Socket resolves the dependencies the manifests declare, including `devDependencies`. This can add findings for dependencies absent from your installed tree. With `--reach`, the CLI also includes these files in the manifest upload for reachability analysis.
|
|
240
|
+
|
|
241
|
+
For npm projects, generate a CycloneDX software bill of materials (SBOM) from the installed tree. The example uses Node.js 20.18 or newer and npm 9 or newer. Run it from the scan root with a Socket API token configured.
|
|
242
|
+
|
|
243
|
+
```bash
|
|
244
|
+
npm ci &&
|
|
245
|
+
npx --yes @cyclonedx/cyclonedx-npm@7.0.1 --omit dev --output-format JSON --output-file installed.cdx.json &&
|
|
246
|
+
socketcli --target-path .
|
|
247
|
+
```
|
|
248
|
+
|
|
249
|
+
The example excludes development dependencies. To include them, remove `--omit dev` and run the install and generator without production-only npm settings or `NODE_ENV=production`. If npm reports a dependency-tree error, inspect it first. Use the generator's `--ignore-npm-errors` option only if the tree npm returns contains the packages you intend to scan.
|
|
250
|
+
|
|
251
|
+
The CLI discovers CycloneDX files such as `bom.json`, `*.cdx.json`, and `*.cyclonedx.json` (or their `.xml` equivalents) alongside the lockfile. Leave `--include-module-folders` off when you only want to add the SBOM.
|
|
252
|
+
|
|
253
|
+
- For PR comparisons, generate the SBOM with the same settings before the default-branch and PR scans. Add `--ignore-commit-files` to the PR scan so it runs a comparison even on commits that change no tracked manifest. A generated SBOM outside the Git diff does not trigger comparison mode on its own.
|
|
254
|
+
- The SBOM covers packages present when it is generated. Packages fetched later or installed outside the tree, such as tools fetched into the npm cache by `npx`, are outside its scope.
|
|
255
|
+
|
|
235
256
|
## Dashboard vs CLI result counts
|
|
236
257
|
|
|
237
258
|
Differences in result counts can be valid, even when filtering appears similar.
|
|
@@ -6,7 +6,7 @@ build-backend = "hatchling.build"
|
|
|
6
6
|
|
|
7
7
|
[project]
|
|
8
8
|
name = "socketsecurity"
|
|
9
|
-
version = "2.
|
|
9
|
+
version = "2.14.0"
|
|
10
10
|
requires-python = ">= 3.11"
|
|
11
11
|
license = {"file" = "LICENSE"}
|
|
12
12
|
dependencies = [
|
|
@@ -16,7 +16,7 @@ dependencies = [
|
|
|
16
16
|
"gitpython==3.2.1",
|
|
17
17
|
"packaging==26.3",
|
|
18
18
|
"python-dotenv==1.2.4",
|
|
19
|
-
"socketdev==3.6.
|
|
19
|
+
"socketdev==3.6.4",
|
|
20
20
|
"beautifulsoup4==4.15.0",
|
|
21
21
|
"markdown==3.11.3",
|
|
22
22
|
"brotli==1.2.1; platform_python_implementation == 'CPython'",
|