Skip to content

ServerKit is a lightweight, modern server control panel for managing web applications, databases, and services on your VPS or dedicated server. Built with Python/Flask backend and React frontend.

security(extensions): trust signed first-party catalog

Juan Denis49b44ab945bd
diff --git a/ROADMAP.md b/ROADMAP.md
index de0ecceb..a611377e 100644
--- a/ROADMAP.md
+++ b/ROADMAP.md
@@ -626,7 +626,7 @@ happen live, and debug failures entirely from the UI.
- [x] Runtime frontend loading — installed extensions render without rebuilding the panel
- [x] Extensions plug into the panel's own surfaces — their work shows up in the deploy console, their data in backups and restore, their health on the doctor page, their objects in search, and they can run commands across the fleet
- [x] Explicit install consent for unsigned, unreviewed or third-party extension code
-- [ ] Signed extension releases — the panel verifies ed25519 signatures against a pinned publisher key, but no published release is signed yet, so every first-party install still takes the unsigned-consent path
+- [x] Signed extension releases — all downloadable first-party artifacts publish detached ed25519 signatures, the canonical and bundled indexes carry them, and registry CI re-downloads and verifies the exact bytes against the pinned publisher key
- [x] The WordPress flagship extracted to its own repo and installed from the Marketplace like any other extension
- [ ] The remaining built-ins extracted to standalone repos
- [ ] Security suite (Fail2ban, ClamAV, Lynis, auto-updates, image scanning) as installable extensions for a leaner default panel
diff --git a/backend/app/data/registry_index.json b/backend/app/data/registry_index.json
index 7ca768ff..05dcc683 100644
--- a/backend/app/data/registry_index.json
+++ b/backend/app/data/registry_index.json
@@ -1,6 +1,6 @@
{
"schema_version": 3,
- "updated": "2026-08-15",
+ "updated": "2026-08-28",
"note": "Bundled fallback copy of the ServerKit extension registry index. The live index is fetched from SERVERKIT_REGISTRY_URL when configured; this file is used offline and in tests. It is a MIRROR of serverkit-extensions/index.json on main \u2014 do not hand-edit entries here, or it drifts from the artifacts it pins and installs fail checksum verification on exactly the panels that are already offline. Regenerate by copying that file's extensions array; tests/test_registry_bundled_index.py checks the two agree. Schema v3 adds optional per-entry `signature` + `publisher_key_id` (ed25519 minisign-style detached signature over the release zip, verified against the panel's pinned publisher keys at install \u2014 plan 55 D3). v1/v2 indexes without those fields remain valid; their entries are treated as unsigned.",
"extensions": [
{
@@ -21,7 +21,9 @@
"sha256": "432d31396075f8e72921d1c19564e1a819d7fdd674b8d73349e0c13feb51a5f5",
"homepage": "https://github.com/jhd3197/serverkit-gui",
"repo": "https://github.com/jhd3197/serverkit-gui",
- "logo": "assets/serverkit-gui/logo.svg"
+ "logo": "assets/serverkit-gui/logo.svg",
+ "signature": "RUSisf2r8uF4y69x4uD1hK2NC9RcJkB+LvogtQikyZopu0EYj5IZa0zsIRicPrdjNYd+/U/zzs7H9wPMZOLZk+1cHdBPqTTsVgY=",
+ "publisher_key_id": "serverkit-official"
},
{
"slug": "serverkit-cloud-provision",
@@ -79,7 +81,9 @@
"homepage": "https://github.com/jhd3197/serverkit-crowdsec",
"featured": false,
"feature_score": 0,
- "logo": "assets/serverkit-crowdsec/logo.png"
+ "logo": "assets/serverkit-crowdsec/logo.png",
+ "signature": "RUSisf2r8uF4y2Tefhv20k7/rrVaL4G5RTKLOpGWAuK8O8FTEp77to4eflBymtdP+OVEqEeXxSKRrcLzyWY4HUmf5H5pYWTUoQU=",
+ "publisher_key_id": "serverkit-official"
},
{
"slug": "serverkit-dns-server",
@@ -102,7 +106,9 @@
"homepage": "https://github.com/jhd3197/serverkit-dns-server",
"featured": false,
"feature_score": 0,
- "logo": "assets/serverkit-dns-server/logo.png"
+ "logo": "assets/serverkit-dns-server/logo.png",
+ "signature": "RUSisf2r8uF4ywe3uGID4sB1bZTMceurs140o+ECL+FtBNaeqGQwqXIN4jWoNj8tFK3HbhaH1jA5vdw6NIMgXyxvfkjxsJEhaAQ=",
+ "publisher_key_id": "serverkit-official"
},
{
"slug": "serverkit-email",
@@ -198,7 +204,9 @@
"homepage": "https://github.com/jhd3197/serverkit-gpu",
"featured": true,
"feature_score": 60,
- "logo": "assets/serverkit-gpu/logo.png"
+ "logo": "assets/serverkit-gpu/logo.png",
+ "signature": "RUSisf2r8uF4y0UJPkgjRvsayCY69ztjs1HLGyUKjrkdEsPLooabPjx/RcJLqijh7KGAeZMBbac8EMnLAULLD91UQ2nXNe5XLwk=",
+ "publisher_key_id": "serverkit-official"
},
{
"slug": "serverkit-mail",
@@ -223,7 +231,9 @@
"homepage": "https://github.com/jhd3197/serverkit-mail",
"featured": false,
"feature_score": 0,
- "logo": "assets/serverkit-mail/logo.png"
+ "logo": "assets/serverkit-mail/logo.png",
+ "signature": "RUSisf2r8uF4yyKC6Brnz9c/v28vlHtJlT3RV9JKMFJngHIln4/bvhMoipg5CErprtkBufKidxrbseW/6S+oQ+Zo7aEZusnx1AY=",
+ "publisher_key_id": "serverkit-official"
},
{
"slug": "serverkit-remote-access",
@@ -281,7 +291,9 @@
"homepage": "https://github.com/jhd3197/serverkit-wordpress",
"featured": true,
"feature_score": 80,
- "logo": "assets/serverkit-wordpress/logo.png"
+ "logo": "assets/serverkit-wordpress/logo.png",
+ "signature": "RUSisf2r8uF4y6cH1kZAl4Xvfjn+QxpOjtIA9wnWCzMS1RIbXwjsQnpvmf+uGQY8rI/gKTYWf/d95u2NGRRF/JyKVxuc0pGGVQc=",
+ "publisher_key_id": "serverkit-official"
},
{
"slug": "serverkit-k8s",
@@ -305,7 +317,9 @@
"homepage": "https://github.com/jhd3197/serverkit-k8s",
"featured": false,
"feature_score": 0,
- "logo": "assets/serverkit-k8s/logo.png"
+ "logo": "assets/serverkit-k8s/logo.png",
+ "signature": "RUSisf2r8uF4yytyUvgBJdz+138Xw41JuZU7UWMRzTAwbrNI/YMeNV5c8qbg3i5MnTqo2qqzLnQnQHD0ZfEkv8j3vnV6ERG0dQc=",
+ "publisher_key_id": "serverkit-official"
},
{
"slug": "serverkit-tramo",
@@ -330,7 +344,9 @@
"homepage": "https://github.com/jhd3197/serverkit-tramo",
"featured": true,
"feature_score": 90,
- "logo": "assets/serverkit-tramo/logo.png"
+ "logo": "assets/serverkit-tramo/logo.png",
+ "signature": "RUSisf2r8uF4y8X23TTjcunsp/YgbaKCaFg5rBKfE+Ww2ObDxjJbLGwxZhG0JhfHiXDPWd/mnKuYoLiUMbXnky0UUfajORlujg0=",
+ "publisher_key_id": "serverkit-official"
},
{
"slug": "serverkit-analytics",
@@ -354,7 +370,9 @@
"homepage": "https://github.com/jhd3197/serverkit-analytics",
"featured": true,
"feature_score": 88,
- "logo": "assets/serverkit-analytics/logo.png"
+ "logo": "assets/serverkit-analytics/logo.png",
+ "signature": "RUSisf2r8uF4y/IqEG8/YJsgSYZr6KoaoQ+qRjvufpOo/J35izl1RxtpyG6F2CaInK1FIk8Kc9VTmuZ2gyVzsgk3r19YwGyRDwg=",
+ "publisher_key_id": "serverkit-official"
},
{
"slug": "serverkit-faro",
@@ -374,33 +392,9 @@
"homepage": "https://github.com/jhd3197/serverkit-faro",
"featured": true,
"feature_score": 100,
- "logo": "assets/serverkit-faro/logo.png"
- },
- {
- "slug": "serverkit-redis",
- "display_name": "Redis Manager",
- "description": "Redis server management with a key browser, key inspector, guarded CLI terminal, config viewer, slow log, and real-time server stats. Community extension (author: Paong); the listed release is built from the jhd3197 fork, which carries security hardening on top of the original.",
- "version": "1.0.1",
- "category": "utility",
- "author": "Paong",
- "first_party": false,
- "permissions": [
- "shell"
- ],
- "min_panel_version": "1.7.0",
- "max_panel_version": null,
- "source": "https://github.com/jhd3197/serverkit-redis/releases/download/v1.0.1/serverkit-redis-1.0.1.zip",
- "sha256": "b1e8f6bfb4a15e5b86d40fd2e780f0b3ccd1bc38946ffdcf720e5810966f6b1c",
- "review": {
- "reviewer": "jhd3197",
- "date": "2026-07-23",
- "sha256": "b1e8f6bfb4a15e5b86d40fd2e780f0b3ccd1bc38946ffdcf720e5810966f6b1c",
- "commit": "6d709f2",
- "notes": "Full-file audit of v1.0.0 plus the fork's hardening diff. Fixed before stamping: admin-only RBAC on all routes (was any authenticated user), first-token command blocklist closing the CONFIG SET/EVAL/MODULE/REPLICAOF path to host code execution, slowlog input validation, and a working frontend bundle. Fixes offered upstream as farhanturu/serverkit-redis#1."
- },
- "repo": "https://github.com/jhd3197/serverkit-redis",
- "homepage": "https://github.com/jhd3197/serverkit-redis",
- "logo": "assets/serverkit-redis/logo.svg"
+ "logo": "assets/serverkit-faro/logo.png",
+ "signature": "RUSisf2r8uF4y0SdTvSDNBJHsTbpWumcmG7a9B7SoOsmhOOL3GhhExZJ1jdQpp2AwrPBtnTvwSb3f8C1f+J9OpG+2SspaHjSqA8=",
+ "publisher_key_id": "serverkit-official"
},
{
"slug": "serverkit-minecraft",
@@ -424,7 +418,9 @@
"homepage": "https://github.com/jhd3197/serverkit-minecraft",
"featured": true,
"feature_score": 85,
- "logo": "assets/serverkit-minecraft/logo.png"
+ "logo": "assets/serverkit-minecraft/logo.png",
+ "signature": "RUSisf2r8uF4y23+Ewf4eCC+2AToGfHNAUeu4+nTgnCK0J4saaHOBShtW2NNXZ/XaQE340LNNNLTEhCMdHax+rWzNuW5F2yf/Ag=",
+ "publisher_key_id": "serverkit-official"
}
]
}
diff --git a/backend/tests/test_registry_bundled_index.py b/backend/tests/test_registry_bundled_index.py
index b5c04436..fbb7f9f7 100644
--- a/backend/tests/test_registry_bundled_index.py
+++ b/backend/tests/test_registry_bundled_index.py
@@ -14,6 +14,7 @@ compares the pinned tuples. It skips when the network is unavailable so a plane
or a firewalled runner does not fail the suite, but it does NOT skip on a
mismatch.
"""
+import base64
import json
import os
from pathlib import Path
@@ -62,6 +63,27 @@ def test_installable_entries_pin_an_artifact(bundled):
), f'{slug}: sha256 must be 64 lowercase hex chars'
+def test_downloadable_first_party_entries_are_signed_by_a_pinned_key(bundled):
+ """The offline fallback must never reintroduce unsigned first-party code."""
+ from app.services import signing_service
+
+ trusted = signing_service.load_trusted_keys()
+ for entry in bundled['extensions']:
+ if entry.get('bundled') or not entry.get('first_party'):
+ continue
+ slug = entry['slug']
+ key_id = entry.get('publisher_key_id')
+ assert key_id in trusted, f'{slug}: publisher key {key_id!r} is not pinned'
+ try:
+ envelope = base64.b64decode(entry.get('signature') or '', validate=True)
+ except ValueError as exc:
+ raise AssertionError(f'{slug}: signature is not valid base64') from exc
+ assert len(envelope) == 74 and envelope[:2] == b'ED', (
+ f'{slug}: malformed ServerKit ed25519 signature envelope')
+ assert envelope[2:10] == trusted[key_id]['key_num'], (
+ f'{slug}: signature was made by a different key than {key_id}')
+
+
def test_source_url_agrees_with_the_declared_version(bundled):
"""A release-asset URL carries its version; it must not contradict `version`.
@@ -133,7 +155,10 @@ def test_matches_published_index(bundled):
def pinned(index):
return {
- e['slug']: (e.get('version'), e.get('source'), e.get('sha256'))
+ e['slug']: (
+ e.get('version'), e.get('source'), e.get('sha256'),
+ e.get('signature'), e.get('publisher_key_id'),
+ )
for e in index['extensions']
}
diff --git a/docs/EXTENSIONS.md b/docs/EXTENSIONS.md
index 072d7e9a..1eb18c0c 100644
--- a/docs/EXTENSIONS.md
+++ b/docs/EXTENSIONS.md
@@ -812,11 +812,11 @@ verification stays visible after install. The sha256 runtime-frontend hash
check is unaffected — signatures cover the zip, `_frontend_hashes` still pins
the served `.mjs` bundle bytes.
-Honesty note (D2): a signature verifies *when present*. An unsigned
-first-party registry entry installs only behind the explicit 409 consent step
-(acknowledge-risk), and the same gate covers the update path — but the
-acknowledgment itself still rests on the index's integrity (TLS + the
-registry repo's PR review) until every first-party release is signed.
+All current downloadable first-party releases publish a detached `.minisig`
+asset and carry the same signature in the registry index. Registry CI downloads
+the exact release bytes and verifies both SHA-256 and Ed25519 before accepting
+the catalog. The unsigned 409 path remains only for older cached indexes and
+third-party compatibility; it is not the normal first-party delivery path.
### Docker note
diff --git a/scripts/sync-registry-index.sh b/scripts/sync-registry-index.sh
index 930af698..5ffe36c5 100644
--- a/scripts/sync-registry-index.sh
+++ b/scripts/sync-registry-index.sh
@@ -116,7 +116,10 @@ current = json.loads(before)
def pinned(index):
return {
- e['slug']: (e.get('version'), e.get('source'), e.get('sha256'))
+ e['slug']: (
+ e.get('version'), e.get('source'), e.get('sha256'),
+ e.get('signature'), e.get('publisher_key_id'),
+ )
for e in index['extensions']
}