Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions .githooks/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/bin/sh
# Enable per clone with: git config core.hooksPath .githooks
set -eu

if command -v mise >/dev/null 2>&1 && mise which gitleaks >/dev/null 2>&1; then
exec mise exec -- gitleaks git --pre-commit --redact --staged --verbose
fi

if command -v gitleaks >/dev/null 2>&1; then
exec gitleaks git --pre-commit --redact --staged --verbose
fi

printf '%s\n' "Gitleaks is required. Run 'mise install' or install Gitleaks 8.30.1." >&2
exit 1
25 changes: 25 additions & 0 deletions .github/workflows/security.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Security

on:
push:
pull_request:
workflow_dispatch:

permissions:
contents: read

jobs:
secret-scan:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Scan committed history for secrets
uses: gitleaks/gitleaks-action@e0c47f4f8be36e29cdc102c57e68cb5cbf0e8d1e # v3.0.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITLEAKS_ENABLE_COMMENTS: "false"
GITLEAKS_ENABLE_SUMMARY: "false"
GITLEAKS_ENABLE_UPLOAD_ARTIFACT: "false"
GITLEAKS_VERSION: "8.30.1"
5 changes: 5 additions & 0 deletions .gitleaks.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
title = "tripod"
minVersion = "8.30.1"

[extend]
useDefault = true
2 changes: 2 additions & 0 deletions .mise.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[tools]
gitleaks = "8.30.1"
20 changes: 20 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Security policy

## Supported versions

Tripod supports the current `main` branch.

## Report a vulnerability

Please use [GitHub's private vulnerability reporting](https://github.com/joryeugene/tripod/security/advisories/new) so the report stays private while it is investigated. Do not open a public issue for a suspected vulnerability.

Include the affected version or commit, reproduction steps, expected impact, and any mitigation you have already tested. Please omit real credentials and sensitive personal data.

## Local checks

The native staged secret scan is opt-in:

```text
mise install
git config core.hooksPath .githooks
```
Loading