Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
42ad863
feat(admin): fix dashboard typecheck and rebuild core modules
Nov 4, 2026
f2dd306
feat: migration, edge function, admin bootstrap, CI fix
Nov 4, 2026
ea3622d
fix(sql): reserved-keyword helper, declaration policy, docs
Nov 4, 2026
f793723
fix(admin): demo logins now resolve to seeded profiles
Nov 4, 2026
1e35496
fix(sql): three defects found by running the migrations on real Postgres
Nov 4, 2026
178be22
chore: make the repo-level typecheck script cover all workspaces
Nov 4, 2026
d117ef9
fix(admin): read SUPABASE_URL / SUPABASE_PUBLISHABLE_KEY from .env files
Nov 4, 2026
b0fc86b
docs(env): record why unprefixed Supabase vars need loadEnv
Nov 4, 2026
3e3a951
docs(status): note the loadEnv build-config row
Nov 4, 2026
a8a70c8
Merge origin/main into the dashboard branch
Nov 4, 2026
eaa531d
fix(deps): clear the glob and minimatch advisories; upgrade to eslint 10
Nov 4, 2026
218ed69
fix(admin): satisfy react-hooks v7 and remove the last advisories
Nov 4, 2026
345075b
fix(security): escape user input in printable and preview HTML
Nov 4, 2026
03501ca
docs(security): record which scan workflows can actually run
Nov 4, 2026
57f4c70
ci: run on Node 22 and move first-party actions off Node 20
Nov 4, 2026
8241eaa
fix(deploy): stop 404 when refreshing a client-side route
Nov 4, 2026
c8a34ec
docs(status): record the dependency, XSS, deploy and scanner outcomes
Nov 4, 2026
0377c07
ci(security): pin every action to a SHA and declare least-privilege p…
Nov 4, 2026
670434f
fix(auth): close the demo-account login bypass
Nov 4, 2026
c25c08a
fix(build): keep demo credentials out of production bundles reliably
Nov 4, 2026
ca6f31a
chore(lint): declare the __DEMO_MODE__ build constant
Nov 4, 2026
56fbe68
fix(sql): teaches_section() was always true (parameter shadowed the c…
Nov 4, 2026
947b3bd
fix(sql): qualify the outer student_id in the threads INSERT policy
Nov 4, 2026
1588784
fix(sql): qualify poll_options.poll_id in its INSERT policy
Nov 4, 2026
8bf3f27
docs: record the SQL shadowing fixes and the 25-assertion RLS suite
Nov 4, 2026
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
5 changes: 4 additions & 1 deletion .github/workflows/black-duck-security-scan-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ on:
schedule:
- cron: '43 7 * * 6'

permissions:
contents: read

jobs:
build:
runs-on: ubuntu-latest
Expand All @@ -29,7 +32,7 @@ jobs:

steps:
- name: Checkout source
uses: actions/checkout@v4
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262
- name: Black Duck SCA scan
uses: blackduck-inc/black-duck-security-scan@805cbd09e806b01907bbea0f990723c2bb85abe9
with:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/checkmarx-one.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,18 +38,18 @@ jobs:
steps:
# This step checks out a copy of your repository.
- name: Checkout repository
uses: actions/checkout@v4
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262
# This step creates the Checkmarx One scan
- name: Checkmarx One scan
uses: checkmarx/ast-github-action@8e887bb93dacc44e0f5b64ee2b06d5815f89d4fc
uses: checkmarx/ast-github-action@58c998c5d78b3ecfa51e7cbde852d5565d5dea0b
with:
base_uri: https://ast.checkmarx.net # This should be replaced by your base uri for Checkmarx One
cx_client_id: ${{ secrets.CX_CLIENT_ID }} # This should be created within your Checkmarx One account : https://checkmarx.com/resource/documents/en/34965-118315-authentication-for-checkmarx-one-cli.html#UUID-a4e31a96-1f36-6293-e95a-97b4b9189060_UUID-4123a2ff-32d0-2287-8dd2-3c36947f675e
cx_client_secret: ${{ secrets.CX_CLIENT_SECRET }} # This should be created within your Checkmarx One account : https://checkmarx.com/resource/documents/en/34965-118315-authentication-for-checkmarx-one-cli.html#UUID-a4e31a96-1f36-6293-e95a-97b4b9189060_UUID-4123a2ff-32d0-2287-8dd2-3c36947f675e
cx_tenant: ${{ secrets.CX_TENANT }} # This should be replaced by your tenant for Checkmarx One
additional_params: --report-format sarif --output-path .
- name: Upload SARIF file
uses: github/codeql-action/upload-sarif@v3
uses: github/codeql-action/upload-sarif@33d7b85da1a04171e211befe2c739303b9a4c066
with:
# Path to SARIF file relative to the root of the repository
sarif_file: cx_result.sarif
4 changes: 2 additions & 2 deletions .github/workflows/checkmarx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
# Steps require - checkout code, run CxFlow Action, Upload SARIF report (optional)
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v4
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262
# Runs the Checkmarx Scan leveraging the latest version of CxFlow - REFER to Action README for list of inputs
- name: Checkmarx CxFlow Action
uses: checkmarx-ts/checkmarx-cxflow-github-action@49d8269b14ca87910ba003d47a31fa0c7a11f2fe
Expand All @@ -50,6 +50,6 @@ jobs:
params: --namespace=${{ github.repository_owner }} --repo-name=${{ github.event.repository.name }} --branch=${{ github.ref }} --cx-flow.filter-severity --cx-flow.filter-category --checkmarx.disable-clubbing=true --repo-url=${{ github.event.repository.url }}
# Upload the Report for CodeQL/Security Alerts
- name: Upload SARIF file
uses: github/codeql-action/upload-sarif@v3
uses: github/codeql-action/upload-sarif@33d7b85da1a04171e211befe2c739303b9a4c066
with:
sarif_file: cx.sarif
80 changes: 79 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1 +1,79 @@
name: CI\n\non:\n push:\n branches: [main]\n pull_request:\n\njobs:\n lint-and-typecheck:\n runs-on: ubuntu-latest\n steps:\n - uses: actions/checkout@v4\n - uses: actions/setup-node@v4\n with:\n node-version: "18"\n cache: "npm"\n - run: npm ci\n - run: npm run typecheck\n - run: npm run lint\n - name: Guard against public secrets\n run: |\n if grep -r "EXPO_PUBLIC_.*\\(SECRET\\|SERVICE\\|PRIVATE\\|JWT\\|POSTGRES\\|PASSWORD\\|TOKEN\\)" apps/ 2>/dev/null | grep -v "PUBLISHABLE_KEY\\|ANON_KEY"; then\n echo "Found secret-like EXPO_PUBLIC_ var"\n exit 1\n fi\n if grep -r "VITE_.*\\(SECRET\\|SERVICE\\|PRIVATE\\|JWT\\|POSTGRES\\|PASSWORD\\|TOKEN\\)" apps/ 2>/dev/null | grep -v "PUBLISHABLE_KEY\\|ANON_KEY"; then\n echo "Found secret-like VITE_ var"\n exit 1\n fi\n - name: Warn if PROJECT_STATUS not updated\n run: |\n if git diff --name-only HEAD~1 2>/dev/null | grep -E "^(apps|supabase)/" && ! git diff --name-only HEAD~1 2>/dev/null | grep -q "PROJECT_STATUS.md"; then\n echo "::warning::Consider updating PROJECT_STATUS.md"\n fi\n
name: CI

on:
push:
branches: [main]
pull_request:

concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true

permissions:
contents: read

jobs:
lint-and-typecheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262

- uses: actions/setup-node@249970729cb0ef3589644e2896645e5dc5ba9c38
with:
node-version: "22"
cache: "npm"

- run: npm ci

- run: npm run typecheck

- run: npm run lint

- name: Build admin console
run: npm run build --workspace=apps/admin

- name: Guard against public secrets
run: |
failed=0

# A client-side variable may name a public key and nothing else.
# PUBLISHABLE_KEY / ANON_KEY are the allowed exceptions.
if grep -rIn --include='*.ts' --include='*.tsx' --include='*.js' --include='*.mjs' \
--include='.env.example' -E '(EXPO_PUBLIC|VITE)_[A-Z_]*(SECRET|SERVICE|PRIVATE|JWT|POSTGRES|PASSWORD|TOKEN)' \

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Suggestion: The pattern omits DATABASE, so names such as VITE_DATABASE_URL bypass this guard even though the project classifies database variables as server-side.

Assessment: 🟠 Major · 🔁 Occurrence: Rarely · 🏷️ Security

Use CodeAnt Skill Fix in Cursor Fix in VSCode Claude

Prompt for AI Agent 🤖
This is a comment left during a code review.

**Path:** .github/workflows/ci.yml
**Line:** 42:42
**Comment:**
	*Security: The pattern omits `DATABASE`, so names such as `VITE_DATABASE_URL` bypass this guard even though the project classifies database variables as server-side.

Validate the correctness of the flagged issue. If correct, How can I resolve this? If you propose a fix, implement it and please make it concise.
Once fix is implemented, also check other comments on the same PR, and ask user if the user wants to fix the rest of the comments as well. if said yes, then fetch all the comments validate the correctness and implement a minimal fix
👍 | 👎

apps/ scripts/ 2>/dev/null \
| grep -v -E 'PUBLISHABLE_KEY|ANON_KEY' ; then

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Suggestion: Filtering whole result lines lets a secret-like variable pass whenever its source line also mentions PUBLISHABLE_KEY or ANON_KEY.

Assessment: 🟠 Major · 🔁 Occurrence: Rarely · 🏷️ Security

Use CodeAnt Skill Fix in Cursor Fix in VSCode Claude

Prompt for AI Agent 🤖
This is a comment left during a code review.

**Path:** .github/workflows/ci.yml
**Line:** 44:44
**Comment:**
	*Security: Filtering whole result lines lets a secret-like variable pass whenever its source line also mentions `PUBLISHABLE_KEY` or `ANON_KEY`.

Validate the correctness of the flagged issue. If correct, How can I resolve this? If you propose a fix, implement it and please make it concise.
Once fix is implemented, also check other comments on the same PR, and ask user if the user wants to fix the rest of the comments as well. if said yes, then fetch all the comments validate the correctness and implement a minimal fix
👍 | 👎

echo "::error::Found a secret-like public (EXPO_PUBLIC_/VITE_) variable."
failed=1
fi

# The service role / secret key must never be referenced by a web app.
if grep -rIn --include='*.ts' --include='*.tsx' --include='*.js' --include='*.mjs' \
'SUPABASE_SERVICE_ROLE_KEY' apps/ 2>/dev/null ; then
echo "::error::Service role key referenced inside apps/."
failed=1
fi

if [ "$failed" -ne 0 ]; then
exit 1
fi
echo "No secret-like public variables found."

- name: Check env var names are the Vercel ones
run: |
# The admin console is documented to read SUPABASE_URL and
# SUPABASE_PUBLISHABLE_KEY. Keep that contract visible in CI.
grep -q 'SUPABASE_PUBLISHABLE_KEY' apps/admin/.env.example || {
echo "::error::apps/admin/.env.example must document SUPABASE_PUBLISHABLE_KEY"
exit 1
}
grep -q 'SUPABASE_URL' apps/admin/.env.example || {
echo "::error::apps/admin/.env.example must document SUPABASE_URL"
exit 1
}

- name: Warn if PROJECT_STATUS not updated
run: |
changed=$(git diff --name-only "origin/${{ github.base_ref }}...HEAD" 2>/dev/null || git diff --name-only HEAD~1 2>/dev/null || true)
if echo "$changed" | grep -qE '^(apps|supabase)/' && ! echo "$changed" | grep -q 'PROJECT_STATUS.md'; then
echo "::warning::Source changed without updating PROJECT_STATUS.md"
fi
4 changes: 2 additions & 2 deletions .github/workflows/codacy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
steps:
# Checkout the repository to the GitHub Actions runner
- name: Checkout code
uses: actions/checkout@v4
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262

# Execute Codacy Analysis CLI and generate a SARIF output with the security issues identified during the analysis
- name: Run Codacy Analysis CLI
Expand All @@ -56,6 +56,6 @@ jobs:

# Upload the SARIF file generated in the previous step
- name: Upload SARIF results file
uses: github/codeql-action/upload-sarif@v3
uses: github/codeql-action/upload-sarif@33d7b85da1a04171e211befe2c739303b9a4c066
with:
sarif_file: results.sarif
11 changes: 6 additions & 5 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ on:
schedule:
- cron: '25 2 * * 0'

permissions:
contents: read

jobs:
analyze:
name: Analyze (${{ matrix.language }})
Expand Down Expand Up @@ -57,17 +60,15 @@ jobs:
# your codebase is analyzed, see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages
steps:
- name: Checkout repository
uses: actions/checkout@v7
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262

# Add any setup steps before running the `github/codeql-action/init` action.
# This includes steps like installing compilers or runtimes (`actions/setup-node`
# or others). This is typically only required for manual builds.
# - name: Setup runtime (example)
# uses: actions/setup-example@v1

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v4
uses: github/codeql-action/init@33d7b85da1a04171e211befe2c739303b9a4c066
with:
languages: ${{ matrix.language }}
build-mode: ${{ matrix.build-mode }}
Expand Down Expand Up @@ -96,6 +97,6 @@ jobs:
exit 1

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v4
uses: github/codeql-action/analyze@33d7b85da1a04171e211befe2c739303b9a4c066
with:
category: "/language:${{matrix.language}}"
6 changes: 3 additions & 3 deletions .github/workflows/codescan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262
- name: Cache files
uses: actions/cache@v3
uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830
with:
path: |
~/.sonar
Expand All @@ -44,6 +44,6 @@ jobs:
organization: ${{ secrets.CODESCAN_ORGANIZATION_KEY }}
projectKey: ${{ secrets.CODESCAN_PROJECT_KEY }}
- name: Upload SARIF file
uses: github/codeql-action/upload-sarif@v3
uses: github/codeql-action/upload-sarif@33d7b85da1a04171e211befe2c739303b9a4c066
with:
sarif_file: codescan.sarif
4 changes: 2 additions & 2 deletions .github/workflows/debricked.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- uses: debricked/actions@v4
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262
- uses: debricked/actions@659ae7accc12313772fbfbd1b1fccec31772ce41
env:
DEBRICKED_TOKEN: ${{ secrets.DEBRICKED_TOKEN }}
9 changes: 6 additions & 3 deletions .github/workflows/endorlabs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ on:
branches: [ "main" ]
schedule:
- cron: '40 5 * * 5'
permissions:
contents: read

jobs:
scan:
permissions:
Expand All @@ -21,12 +24,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262
#### Package Build Instructions
### Use this section to define the build steps used by your software package.
### Endor Labs builds your software for you where possible but the required build tools must be made available.
# - name: Setup Java
# uses: actions/setup-java@v4
# uses: actions/setup-java@b843ebf9b913146b38da2eaa7aeddf76074ae1ad
# with:
# distribution: 'microsoft'
# java-version: '17'
Expand All @@ -46,6 +49,6 @@ jobs:
ci_run: "false"
sarif_file: findings.sarif
- name: Upload SARIF to github
uses: github/codeql-action/upload-sarif@v3
uses: github/codeql-action/upload-sarif@33d7b85da1a04171e211befe2c739303b9a4c066
with:
sarif_file: findings.sarif
8 changes: 4 additions & 4 deletions .github/workflows/ossar.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,25 +32,25 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v4
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262

# Ensure a compatible version of dotnet is installed.
# The [Microsoft Security Code Analysis CLI](https://aka.ms/mscadocs) is built with dotnet v3.1.201.
# A version greater than or equal to v3.1.201 of dotnet must be installed on the agent in order to run this action.
# GitHub hosted runners already have a compatible version of dotnet installed and this step may be skipped.
# For self-hosted runners, ensure dotnet version 3.1.201 or later is installed by including this action:
# - name: Install .NET
# uses: actions/setup-dotnet@v4
# uses: actions/setup-dotnet@0f4a354dd5547a28c70b7853dbd95d5b67886e73
# with:
# dotnet-version: '3.1.x'

# Run open source static analysis tools
- name: Run OSSAR
uses: github/ossar-action@v1
uses: github/ossar-action@786a16a90ba92b4ae6228fe7382fb16ef5c51000
id: ossar

# Upload results to the Security tab
- name: Upload OSSAR results
uses: github/codeql-action/upload-sarif@v3
uses: github/codeql-action/upload-sarif@33d7b85da1a04171e211befe2c739303b9a4c066
with:
sarif_file: ${{ steps.ossar.outputs.sarifFile }}
7 changes: 5 additions & 2 deletions .github/workflows/synopsys-action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,19 @@ on:
pull_request:
branches: [ "main" ]

permissions:
contents: read

jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262
- name: Synopsys Action
uses: synopsys-sig/synopsys-action@v1.6.0
uses: synopsys-sig/synopsys-action@45ec794c72a1dff9baba58ff356386bbbfeb32c7
with:
#------------------------------------------COVERITY-----------------------------------------
coverity_url: ${{ secrets.COVERITY_URL }}
Expand Down
Loading
Loading