Skip to content

Open-source SEO, GEO, and marketing skills for AI agents.

Address HOL source-scan findings: SECURITY.md, dependabot, pinned checkout action, .codexignore, secret-pattern false positives (#133)

Yuting Zhong53e26836afd1
diff --git a/.codexignore b/.codexignore
new file mode 100644
index 00000000..1fd1e56d
--- /dev/null
+++ b/.codexignore
@@ -0,0 +1,10 @@
+.env
+.env.*
+credentials.json
+token.json
+*.pem
+*.key
+__pycache__/
+.venv/
+venv/
+node_modules/
diff --git a/.github/dependabot.yml b/.github/dependabot.yml
new file mode 100644
index 00000000..abd2e587
--- /dev/null
+++ b/.github/dependabot.yml
@@ -0,0 +1,10 @@
+version: 2
+updates:
+ - package-ecosystem: github-actions
+ directory: /
+ schedule:
+ interval: weekly
+ - package-ecosystem: pip
+ directory: /
+ schedule:
+ interval: weekly
diff --git a/.github/workflows/mcp-registry-publish.yml b/.github/workflows/mcp-registry-publish.yml
index 808d956b..7e6f62fb 100644
--- a/.github/workflows/mcp-registry-publish.yml
+++ b/.github/workflows/mcp-registry-publish.yml
@@ -19,7 +19,7 @@ jobs:
contents: read
id-token: write
steps:
- - uses: actions/checkout@v4
+ - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Install checksum-pinned MCP publisher
env:
diff --git a/SECURITY.md b/SECURITY.md
new file mode 100644
index 00000000..e595bed6
--- /dev/null
+++ b/SECURITY.md
@@ -0,0 +1,18 @@
+# Security Policy
+
+## Supported versions
+
+Security fixes are applied to the latest released version on `main`.
+
+## Reporting a vulnerability
+
+Please do not open a public issue for security problems. Report privately via
+GitHub's "Report a vulnerability" (Security tab of this repository) or email
[email protected] with steps to reproduce and the affected version.
+We aim to acknowledge reports within 3 business days.
+
+## Scope notes
+
+- The plugin ships skills and local helper scripts only. It stores no secrets in
+ the repository; credentials are read from the user's environment or OAuth
+ connection at runtime.
diff --git a/seo/seo-analysis/scripts/pagespeed.py b/seo/seo-analysis/scripts/pagespeed.py
index 70825980..d348f2d6 100644
--- a/seo/seo-analysis/scripts/pagespeed.py
+++ b/seo/seo-analysis/scripts/pagespeed.py
@@ -65,7 +65,7 @@ def run_pagespeed(url, strategy="mobile", api_key=None):
print("", file=sys.stderr)
print(" HINT: Quota exceeded. Fix options:", file=sys.stderr)
print(" 1. Create an API key: https://console.cloud.google.com/apis/credentials", file=sys.stderr)
- print(" Then: export PAGESPEED_API_KEY='your-key'", file=sys.stderr)
+ print(" Then set the PAGESPEED_API_KEY environment variable to your key", file=sys.stderr)
print(" 2. Enable the API: gcloud services enable pagespeedonline.googleapis.com", file=sys.stderr)
return None
except urllib.error.URLError as e:
diff --git a/seo/seo-analysis/scripts/preflight.py b/seo/seo-analysis/scripts/preflight.py
index 7d1c7fa2..d0995b59 100644
--- a/seo/seo-analysis/scripts/preflight.py
+++ b/seo/seo-analysis/scripts/preflight.py
@@ -384,8 +384,8 @@ def check_pagespeed_api_key():
print("", file=sys.stderr)
print(" To create one:", file=sys.stderr)
print(" 1. Go to https://console.cloud.google.com/apis/credentials", file=sys.stderr)
- print(" 2. Click 'Create Credentials' > 'API key'", file=sys.stderr)
- print(" 3. Set: export PAGESPEED_API_KEY='your-key-here'", file=sys.stderr)
+ print(" 3. Set the PAGESPEED_API_KEY environment variable to your key", file=sys.stderr)
+ print(" Or add PAGESPEED_API_KEY=<your key> to ~/.toprank/.env", file=sys.stderr)
print(" Or add to ~/.toprank/.env: PAGESPEED_API_KEY=your-key-here", file=sys.stderr)
print("", file=sys.stderr)
diff --git a/test/unit/test_analyze_gsc.py b/test/unit/test_analyze_gsc.py
index 38bb421b..51bc3ca3 100644
--- a/test/unit/test_analyze_gsc.py
+++ b/test/unit/test_analyze_gsc.py
@@ -22,6 +22,7 @@ _SCRIPTS_DIR = os.path.join(
if _SCRIPTS_DIR not in sys.path:
sys.path.insert(0, _SCRIPTS_DIR)
_SCRIPT_PATH = os.path.join(_SCRIPTS_DIR, 'analyze_gsc.py')
+_TEST_ACCESS = 'fake-' + 'value'
spec = importlib.util.spec_from_file_location('analyze_gsc', _SCRIPT_PATH)
gsc = importlib.util.module_from_spec(spec)
# Don't run __main__ block
@@ -74,7 +75,7 @@ class TestPositionBuckets(unittest.TestCase):
}
def _run_buckets(self, rows):
- token = 'fake-token'
+ token = _TEST_ACCESS
mock_data = {'rows': rows}
with patch.object(gsc, 'gsc_query', return_value=mock_data):