diff --git a/common/tools.py b/common/tools.py new file mode 100644 index 0000000..d89bbdf --- /dev/null +++ b/common/tools.py @@ -0,0 +1,5 @@ +import re + + +def check_sha256_hex_format(value): + return isinstance(value, str) and re.search(r"^[0-9A-Fa-f]{64}$", value) is not None