R-516: the formal forms in Go literals move into the bundle in the te-form
gates / gates (push) Successful in 50s

22 Go-literal messages (escrow handler, share password page, export
upload, network-storage uid/remove/attach failures) are bundle keys with
te-form Hungarian and English; a detached attach failure renders in the
reader's language. The NAS refusal says „Válassz". Setup wizard,
recovery-info.txt (R-554) and the SMART/fill-watch wire texts are left.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0159rPz1ZhFKsS53msqPYxtS
This commit is contained in:
2026-10-06 21:40:02 +02:00
parent f65ace0ca6
commit 3d6ba2852f
14 changed files with 254 additions and 51 deletions
+6 -6
View File
@@ -181,13 +181,13 @@ func (s *Server) escrowStartAPIHandler(w http.ResponseWriter, r *http.Request) {
// this state; a legacy-open box must claim/set a password first).
hash := s.effectivePasswordHash()
if hash == "" {
escrowJSON(w, http.StatusForbidden, nil, "A vezérlőpult jelszava nincs beállítva — előbb állítson be jelszót.")
escrowJSON(w, http.StatusForbidden, nil, s.msg(r, "api.escrow.dashboard_password_missing"))
return
}
ip := rateKey(r)
if s.escrowRateLimited(ip) {
s.logger.Printf("[WARN] [web] escrow start rate limited for %s", ip)
escrowJSON(w, http.StatusTooManyRequests, nil, "Túl sok sikertelen próbálkozás, próbálja újra 1 perc múlva.")
escrowJSON(w, http.StatusTooManyRequests, nil, s.msg(r, "api.escrow.too_many_attempts"))
return
}
if err := bcrypt.CompareHashAndPassword([]byte(hash), []byte(r.FormValue("password"))); err != nil {
@@ -212,7 +212,7 @@ func (s *Server) escrowStartAPIHandler(w http.ResponseWriter, r *http.Request) {
if s.backupMgr != nil && s.backupMgr.OffboxConfigured() {
if err := s.escrowStage(r.Context()); err != nil {
s.logger.Printf("[WARN] [web] escrow start: re-stage failed (ceremony NOT started): %v", err) // err carries no secret
escrowJSON(w, http.StatusBadGateway, nil, "A távoli mentés jelszavának letéti előkészítése nem sikerült — a folyamat nem indult el. Próbálja újra.")
escrowJSON(w, http.StatusBadGateway, nil, s.msg(r, "api.escrow.stage_failed"))
return
}
}
@@ -232,7 +232,7 @@ func (s *Server) escrowStartAPIHandler(w http.ResponseWriter, r *http.Request) {
resp, status, err := agent.EscrowCeremonyStart(r.Context())
if err != nil {
if status == http.StatusConflict {
escrowJSON(w, http.StatusConflict, nil, "Egy kódkészítés már folyamatban van — várja meg, míg befejeződik.")
escrowJSON(w, http.StatusConflict, nil, s.msg(r, "api.escrow.already_running"))
return
}
s.logger.Printf("[WARN] [web] escrow start: agent trigger: %v", err)
@@ -277,11 +277,11 @@ func (s *Server) escrowClaimAPIHandler(w http.ResponseWriter, r *http.Request) {
if err != nil {
switch status {
case http.StatusGone: // 410 — the code was minted but never shown; permanently void.
escrowJSON(w, http.StatusGone, nil, "A kód létrejött, de nem lett megjelenítve — biztonsági okból újra nem kérhető le. Indítsa újra a folyamatot: az új kód a régit érvényteleníti.")
escrowJSON(w, http.StatusGone, nil, s.msg(r, "api.escrow.code_not_shown"))
case http.StatusNotFound: // 404 — no ceremony has run (e.g. phase:none post-reboot). F-C:
// this used to fall through to a 502; a bad-gateway class code for "nothing to claim"
// is wrong. Relay a clean, honest 4xx.
escrowJSON(w, http.StatusNotFound, nil, "Nincs aktív helyreállítási folyamat — előbb indítsa el a kódkészítést.")
escrowJSON(w, http.StatusNotFound, nil, s.msg(r, "api.escrow.no_active_job"))
case http.StatusConflict: // 409 — the ceremony state doesn't allow a claim right now. F-C.
escrowJSON(w, http.StatusConflict, nil, "A folyamat jelenlegi állapotában a kód nem kérhető le.")
default: // status 0 (agent unreachable / transport error) or a genuine agent 5xx — a real