Rename Flask template app to pbpl

Signed-off-by: Arija A. <ari@ari.lt>
This commit is contained in:
2025-10-23 20:38:04 +03:00
parent caf4ac7c06
commit 56aee59790
15 changed files with 11 additions and 352 deletions

18
src/pbpl/const.py Normal file
View File

@@ -0,0 +1,18 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""Constants"""
import os
from typing import Final
TEXT_SIZE_MAX: Final[int] = 2048
POW_DIFFICULTY: Final[int] = 5
POW_DIFFICULTY_STR: Final[str] = "0" * POW_DIFFICULTY
POW_EXPIRES: Final[int] = 60 * 16 # 16 minutes
POW_NONCE_SIZE: Final[int] = 12
KEY_FILENAME: Final[str] = ".key"
KEY_SIZE: Final[int] = 128
SOURCE: Final[str] = os.environ.get("SOURCE", "http://127.0.0.1/")