feat(gitea): DISABLE_REGISTRATION=true & Security-Memo draft
This commit is contained in:
@@ -0,0 +1,27 @@
|
|||||||
|
# Security Memo: Gitea Registrierung deaktivieren
|
||||||
|
|
||||||
|
## Status
|
||||||
|
**Aktuell:** Registrierung ist OFFEN (Standard-Gitea-Setup)
|
||||||
|
**Ziel:** `DISABLE_REGISTRATION = true` in `[security]` Abschnitt der app.ini setzen
|
||||||
|
|
||||||
|
## Risiko
|
||||||
|
- **DDNS-Endpunkt** (`git.tobisniceshomelab.ddnsfree.com`) ist öffentlich erreichbar
|
||||||
|
- **Version im Footer** (1.26.2) identifizierbar — potenziell anfällige Version
|
||||||
|
- Jeder kann sich ohne Genehmigung registrieren → potenzielle Angreifer/Spammer
|
||||||
|
|
||||||
|
## Empfohlene Maßnahme
|
||||||
|
1. Auf dem Gitea-Server (Proxmox LXC `192.168.178.153`) in `/etc/gitea/app.ini` im Abschnitt `[security]` die Zeile `DISABLE_REGISTRATION = true` hinzufügen
|
||||||
|
2. Gitea neu starten: `sudo systemctl restart gitea` (oder wie auch der Service heißt)
|
||||||
|
|
||||||
|
## Commander-Approval notwendig
|
||||||
|
- ⚠️ Diese Änderung ist **nur im laufenden Betrieb** auf dem Gitea-Server vorzunehmen
|
||||||
|
- **Branch `wartung/gitea-disable-registration`** enthält eine Beispielkonfiguration und Dokumentation
|
||||||
|
- **Bitte bestätige mit "JA", dass du die Änderung freigibst**, damit sie auf dem Server umgesetzt werden kann
|
||||||
|
|
||||||
|
## Hinweis
|
||||||
|
Ohne Commander-Ja: keine Änderung an der Gitea-Instanz vornehmen. Die Sicherheitslücke bleibt bestehen, bis die Freigabe erfolgt.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
*Erstellt am: 2026-07-17*
|
||||||
|
*Branch: `wartung/gitea-disable-registration`*
|
||||||
@@ -0,0 +1,65 @@
|
|||||||
|
# Gitea app.ini - Beispielkonfiguration mit DISABLE_REGISTRATION
|
||||||
|
# Speichere diese Datei auf dem Server unter /etc/gitea/app.ini
|
||||||
|
# und setze DISABLE_REGISTRATION=true im Abschnitt [security]
|
||||||
|
|
||||||
|
APP_NAME = TobisNicesGitTea
|
||||||
|
RUN_USER = git
|
||||||
|
RUN_MODE = prod
|
||||||
|
|
||||||
|
[server]
|
||||||
|
DOMAIN = git.tobisniceshomelab.ddnsfree.com
|
||||||
|
HTTP_PORT = 3000
|
||||||
|
APP_DATA_PATH = /var/lib/gitea
|
||||||
|
PROTOCOL = http
|
||||||
|
ROOT_URL = https://git.tobisniceshomelab.ddnsfree.com/
|
||||||
|
DISABLE_SSH = false
|
||||||
|
SSH_PORT = 22
|
||||||
|
LFS_START_SERVER = true
|
||||||
|
LFS_CONTENT_PATH = /var/lib/gitea/data/lfs
|
||||||
|
OFFLINE_MODE = false
|
||||||
|
|
||||||
|
[database]
|
||||||
|
DB_TYPE = sqlite3
|
||||||
|
PATH = /var/lib/gitea/gitea.db
|
||||||
|
MAX_OPEN_CONNS = 10
|
||||||
|
MAX_IDLE_CONNS = 5
|
||||||
|
MAX_CONN_LIFETIME = 30m
|
||||||
|
DSN = /var/lib/gitea/gitea.db
|
||||||
|
|
||||||
|
[security]
|
||||||
|
INSTALL_LOCK = true
|
||||||
|
SECRET_KEY = CHANGE_THIS_TO_A_RANDOM_SECRET_KEY
|
||||||
|
PASSWORD_HASH_ALGO = pbkdf2
|
||||||
|
DISABLE_REGISTRATION = true
|
||||||
|
REQUIRE_SIGNIN_VIEW = false
|
||||||
|
|
||||||
|
[service]
|
||||||
|
ENABLE_CAPTCHA = false
|
||||||
|
ENABLE_REGISTER_EMAIL_CONFIRM = false
|
||||||
|
ENABLE_NOTIFY_MAIL = false
|
||||||
|
ALLOW_ONLY_EXTERNAL_REGISTER_API = false
|
||||||
|
DEFAULT_KEEP_EMAIL_PRIVATE = false
|
||||||
|
DEFAULT_ALLOW_CREATE_ORGANIZATION = true
|
||||||
|
DEFAULT_ENABLE_TIMETRACKING = true
|
||||||
|
NO_REPLY_ADDRESS = noreply.example.org
|
||||||
|
|
||||||
|
[openid]
|
||||||
|
ENABLE_OPENID_SIGNIN = false
|
||||||
|
ENABLE_OPENID_SIGNUP = false
|
||||||
|
|
||||||
|
[session]
|
||||||
|
PROVIDER = file
|
||||||
|
COOKIE_NAME = gitea sessionId
|
||||||
|
COOKIE_SECURE = false
|
||||||
|
|
||||||
|
[mailer]
|
||||||
|
ENABLED = false
|
||||||
|
HOST =
|
||||||
|
FROM = gitea@example.com
|
||||||
|
|
||||||
|
[openid]
|
||||||
|
ENABLE_OPENID_SIGNIN = false
|
||||||
|
ENABLE_OPENID_SIGNUP = false
|
||||||
|
|
||||||
|
[security]
|
||||||
|
DISABLE_REGISTRATION = true
|
||||||
Reference in New Issue
Block a user