v1.2.0 + v1.3.0: Localization, About dialog, TOTP/2FA, stability improvements

v1.2.0:
- GUI localization (EN/RU/ZH) with language switcher and persistent selection
- About dialog (ⓘ) with app info, features, quick start guide
- core/i18n.py — internationalization module with t() function
- All GUI components translated via t() keys

v1.3.0:
- TOTP/2FA tab — Google Authenticator compatible codes with live 30s countdown,
  one-click copy, per-server secret management
- core/totp.py — TOTP module (pyotp, RFC 6238)
- core/logger.py — rotating file logger (5MB, 3 backups)
- Stronger Fernet encryption key with automatic migration from old key
- Thread-safe server store with locks, atomic writes, auto-restore on corruption
- Parallel status checks via ThreadPoolExecutor (up to 10 concurrent)
- SSH client: explicit channel cleanup, Unix key permissions
- Server dialog: port validation (1-65535), TOTP secret field
- Language change preserves active tab and server selection
- pyotp dependency added

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
chrome-storm-c442
2026-02-23 11:07:51 -05:00
parent f86d6a7214
commit bf39fd7b67
26 changed files with 2029 additions and 246 deletions

77
gui/about_dialog.py Normal file
View File

@@ -0,0 +1,77 @@
"""
About dialog — application info, features, quick start.
"""
import customtkinter as ctk
from version import __version__, __author__
from core.i18n import t
class AboutDialog(ctk.CTkToplevel):
def __init__(self, master):
super().__init__(master)
self.title(f"{t('about_title')}{t('version')} {__version__}")
self.geometry("500x480")
self.resizable(False, False)
self.transient(master)
self.grab_set()
# ── Header ──
ctk.CTkLabel(
self, text=t("about_title"),
font=ctk.CTkFont(size=24, weight="bold")
).pack(padx=20, pady=(25, 2))
ctk.CTkLabel(
self, text=f"v{__version__}",
font=ctk.CTkFont(size=13), text_color="#9ca3af"
).pack()
ctk.CTkLabel(
self, text=f"by {__author__}",
font=ctk.CTkFont(size=11), text_color="#6b7280"
).pack(pady=(0, 10))
# ── Separator ──
ctk.CTkFrame(self, height=1, fg_color="gray40").pack(fill="x", padx=30, pady=5)
# ── Description ──
ctk.CTkLabel(
self, text=t("about_desc"),
font=ctk.CTkFont(size=12), text_color="#9ca3af",
justify="center", wraplength=440
).pack(padx=20, pady=(8, 5))
# ── Separator ──
ctk.CTkFrame(self, height=1, fg_color="gray40").pack(fill="x", padx=30, pady=5)
# ── Features ──
ctk.CTkLabel(
self, text=t("about_features_title"),
font=ctk.CTkFont(size=14, weight="bold"), anchor="w"
).pack(fill="x", padx=35, pady=(8, 3))
ctk.CTkLabel(
self, text=t("about_features"),
font=ctk.CTkFont(size=12), anchor="w", justify="left"
).pack(fill="x", padx=40, pady=(0, 5))
# ── Separator ──
ctk.CTkFrame(self, height=1, fg_color="gray40").pack(fill="x", padx=30, pady=5)
# ── Quick Start ──
ctk.CTkLabel(
self, text=t("about_howto_title"),
font=ctk.CTkFont(size=14, weight="bold"), anchor="w"
).pack(fill="x", padx=35, pady=(8, 3))
ctk.CTkLabel(
self, text=t("about_howto"),
font=ctk.CTkFont(size=12), anchor="w", justify="left"
).pack(fill="x", padx=40, pady=(0, 10))
# ── Close button ──
ctk.CTkButton(
self, text=t("close"), width=120, command=self.destroy
).pack(pady=(10, 20))