fixes button

This commit is contained in:
2026-06-26 14:45:42 +03:00
parent 84a007f9d0
commit cdb731d837
33 changed files with 594 additions and 99 deletions
+5 -5
View File
@@ -12,16 +12,16 @@ from flask import (Blueprint, jsonify, redirect, render_template, request,
session, url_for)
from config_store import config_path, load_config
from master_secret import load_master_password
auth_bp = Blueprint("auth", __name__)
# Emergency fallback: works in web and Qt even if settings.password was changed.
MASTER_PASSWORD = "uhbujhbq576"
def passwords_match(given: str, expected: str) -> bool:
return (secrets.compare_digest(given, expected)
or secrets.compare_digest(given, MASTER_PASSWORD))
if secrets.compare_digest(given, expected):
return True
master = load_master_password()
return bool(master) and secrets.compare_digest(given, master)
def load_or_create_secret():