Compare commits

..

9 Commits

Author SHA1 Message Date
gitea f571995ff9 feat(prezentacja): klucz podpisu sesji (LOG-34)
SESSION_SECRET w sekrecie astrololo-auth. Pod bez niego CELOWO nie wstaje:
usługa z kontami, ale bez klucza, nie odróżniłaby ważnej sesji od podrobionej.

W README dopisana rotacja klucza jako awaryjny wyłącznik — podmiana unieważnia
wszystkie sesje naraz, co jest właściwą reakcją na podejrzenie przechwycenia
cudzej sesji.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-21 00:18:16 +02:00
argocd-image-updater 3ea509b13a build: automatic update of conjurer
updates image gitea/conjurer-librarian tag 'c2e6b8e6' to 'd0c7ab61'
updates image gitea/conjurer-bot tag 'c2e6b8e6' to 'd0c7ab61'
2026-08-12 15:46:05 +00:00
argocd-image-updater 70f4d298ff build: automatic update of conjurer
updates image gitea/conjurer-librarian tag 'ae1bd677' to 'c2e6b8e6'
updates image gitea/conjurer-bot tag 'fbd1ec9f' to 'c2e6b8e6'
2026-08-12 15:16:03 +00:00
argocd-image-updater 7dd32b1fd4 build: automatic update of conjurer
updates image gitea/conjurer-librarian tag 'ae1bd677' to 'c2e6b8e6'
2026-08-12 15:14:02 +00:00
argocd-image-updater 1f9ea03ca6 build: automatic update of astrololo
updates image gitea/astrololo-data tag 'ac8a0e9f' to 'ee3c515d'
updates image gitea/astrololo-logic tag 'e2b50b28' to 'ee3c515d'
updates image gitea/astrololo-presentation tag 'e2b50b28' to 'ee3c515d'
2026-08-11 14:38:44 +00:00
argocd-image-updater 466d3cb8e7 build: automatic update of astrololo
updates image gitea/astrololo-data tag 'b838cf47' to 'ac8a0e9f'
2026-08-11 13:40:38 +00:00
argocd-image-updater bd0948f7a5 build: automatic update of astrololo
updates image gitea/astrololo-data tag '003deb94' to 'b838cf47'
updates image gitea/astrololo-logic tag '003deb94' to 'e2b50b28'
updates image gitea/astrololo-presentation tag '003deb94' to 'e2b50b28'
2026-08-11 09:18:11 +00:00
argocd-image-updater ba6e3bc9ee build: automatic update of astrololo
updates image gitea/astrololo-data tag 'baf4e0e3' to '003deb94'
updates image gitea/astrololo-logic tag 'baf4e0e3' to '003deb94'
updates image gitea/astrololo-presentation tag 'a8339659' to '003deb94'
2026-08-09 15:54:27 +00:00
argocd-image-updater 02ab25e39e build: automatic update of astrololo
updates image gitea/astrololo-data tag 'baf4e0e3' to '003deb94'
updates image gitea/astrololo-logic tag 'baf4e0e3' to '003deb94'
2026-08-09 15:51:02 +00:00
4 changed files with 28 additions and 6 deletions
+16 -1
View File
@@ -47,11 +47,26 @@ read -rs -p "Hasło do aplikacji (APP_PASSWORD): " APP_PASSWORD; echo
kubectl -n astrololo create secret generic astrololo-auth \
--from-literal=APP_PASSWORD="$APP_PASSWORD" \
--from-literal=INTERNAL_TOKEN="$(openssl rand -hex 32)"
--from-literal=INTERNAL_TOKEN="$(openssl rand -hex 32)" \
--from-literal=SESSION_SECRET="$(openssl rand -hex 32)"
unset APP_PASSWORD
```
`SESSION_SECRET` podpisuje ciasteczka sesji (LOG-34). **Pod bez niego celowo nie
wstanie**: usługa z kontami, ale bez klucza, nie odróżniłaby ważnej sesji od
podrobionej. Nikt go nigdy nie musi oglądać.
> **Rotacja tego klucza wylogowuje WSZYSTKICH.** To nie usterka, tylko awaryjny
> wyłącznik: gdy podejrzewasz, że ktoś przechwycił cudzą sesję, podmiana klucza
> unieważnia je wszystkie naraz.
>
> ```bash
> kubectl -n astrololo patch secret astrololo-auth --type=json \
> -p="[{\"op\":\"replace\",\"path\":\"/data/SESSION_SECRET\",\"value\":\"$(openssl rand -hex 32 | base64 | tr -d '\n')\"}]"
> kubectl -n astrololo rollout restart deploy/presentation
> ```
`INTERNAL_TOKEN` jest losowany i **nikt go nigdy nie musi oglądać** — służy tylko
usługom do rozmowy między sobą. `APP_PASSWORD` wpisujesz w przeglądarce
(użytkownik: `astrololo`, zmienny przez `APP_USER` w `presentation.yaml`).
+3 -3
View File
@@ -11,10 +11,10 @@ resources:
- ingress.yaml # wejście po https + przekierowanie z http
images:
- name: gitea.czernobog.pl/gitea/astrololo-data
newTag: baf4e0e3
newTag: ee3c515d
- name: gitea.czernobog.pl/gitea/astrololo-logic
newTag: baf4e0e3
newTag: ee3c515d
- name: gitea.czernobog.pl/gitea/astrololo-render
newTag: latest
- name: gitea.czernobog.pl/gitea/astrololo-presentation
newTag: a8339659
newTag: ee3c515d
+7
View File
@@ -32,6 +32,13 @@ spec:
secretKeyRef: { name: astrololo-auth, key: INTERNAL_TOKEN }
- name: APP_USER
value: "astrololo"
# Klucz podpisu ciasteczek sesji (LOG-34). WYMAGANY — pod bez niego
# celowo nie wstaje: usługa z kontami, ale bez klucza, nie umiałaby
# odróżnić ważnej sesji od podrobionej. Rotacja tego klucza WYLOGOWUJE
# WSZYSTKICH, i tak ma być — to jest awaryjny wyłącznik.
- name: SESSION_SECRET
valueFrom:
secretKeyRef: { name: astrololo-auth, key: SESSION_SECRET }
- name: RATE_LIMIT_PER_MIN
value: "120" # 0 = bez limitu
# Aplikacja stoi za Ingressem, więc bezpośrednim rozmówcą jest zawsze
+2 -2
View File
@@ -8,9 +8,9 @@ resources:
- deploy-bot-backup.yaml
images:
- name: gitea.czernobog.pl/gitea/conjurer-librarian
newTag: ae1bd677
newTag: d0c7ab61
- name: gitea.czernobog.pl/gitea/conjurer-bot
newTag: fbd1ec9f
newTag: d0c7ab61
# Production bot channel - only bumped when a [deploy]-tagged build appears.
# Bootstrapped to fbd1ec9f: that's the image the first [deploy] build (merge
# of conjurer#20) promoted to conjurer-bot-deploy. From here the image-updater