Skip to content

SecurityScorecard Executor

Category: Attack Surface Management Script: securityscorecard.py Integration: REST API Faraday Plugin: Raw JSON Website: https://securityscorecard.com

Description

Imports the security rating and open issues of one company monitored in SecurityScorecard into Faraday. The company becomes a Faraday host that shows its score and grade, and each issue becomes a [SECURITY-RATING] vulnerability.

Prerequisites

  • A SecurityScorecard account with access to the company you want to import
  • A SecurityScorecard API token, created in the portal under My Settings > API
  • requests available in the agent's Python environment (checked with python3 -c 'import requests')
  • Network access to https://api.securityscorecard.io

Configuration

Environment Variables (Setup)

Variable Required Description
SSC_TOKEN Yes SecurityScorecard API token

These variables are also accepted as execution arguments, so a single run can override them.

Execution Arguments

Parameter Type Mandatory Description
SSC_DOMAIN string Yes Primary domain of the company to import, as shown in the SecurityScorecard portal (e.g., example.com). An IPv4 address is also accepted.
SSC_ISSUE_TYPE string No Import only one issue type, using its SecurityScorecard slug in lowercase snake_case (e.g., patching_cadence_low, service_open_port, malware_infection). If empty, all issue types are imported. A value that is not in this format is ignored.
SSC_MIN_SEVERITY string No Minimum severity to import: info, low, medium, high or critical (default: info)

YAML Configuration Example

executors:
  securityscorecard:
    repo_executor: securityscorecard.py
    max_size: 65536
    varenvs:
      SSC_TOKEN: "<ssc_token>"
    params:
      SSC_DOMAIN:
        mandatory: true
        type: string
        base: string
      SSC_ISSUE_TYPE:
        mandatory: false
        type: string
        base: string
      SSC_MIN_SEVERITY:
        mandatory: false
        type: string
        base: string

How It Works

  1. Authenticates with Authorization: Token <SSC_TOKEN>
  2. Reads the company record with GET /companies/{domain} and its factor grades with GET /companies/{domain}/factors
  3. Reads the issues with GET /companies/{domain}/issues (or /issues/{type} when SSC_ISSUE_TYPE is set), 100 per page
  4. Maps each issue to a Faraday vulnerability:
    • Name: [SECURITY-RATING] followed by the issue title
    • Severity: SecurityScorecard's severity (positive counts as info), or its numeric score when the severity is missing
    • Status: active issues are open, resolved or fixed issues are closed, waived or accepted issues are risk-accepted
    • Details: affected targets, evidence, CVEs, reference links and remediation text
  5. Drops issues below SSC_MIN_SEVERITY and creates one host for the company

Notes

  • The host uses IP 0.0.0.0 and the company's domain as hostname, because the rating belongs to a company and not to an IP address. Its operating system field shows the score and grade (e.g., SecurityScorecard 87 (B)), and its description lists the factor grades.
  • If the company or factor requests fail (other than a 401), the run continues with less host information.
  • An invalid SSC_DOMAIN stops the run. An unrecognized SSC_MIN_SEVERITY falls back to info.
  • The shared agent parameters (AGENT_CONFIG_* tags and severity filters) are not applied by this executor. Use SSC_MIN_SEVERITY to filter by severity.