1
0
mirror of https://github.com/aziascreations/BakaShrot.git synced 2026-11-23 20:58:46 +01:00

Added bench.ps1, Made a CRL file not there yet revoke nothing for clients too

- bench.ps1 runs the benchmarks (push_rate, replication_rate,
  compare_with_old) in release mode: -Only, -Sync full|normal. Plan
  step 13 done, every step of the plan is.
- A CRL file named in client.toml that isn't there yet: nothing revoked
  (the tool, Python's from_file), as on the server, which now warns in
  its log. A path given to the DLL's SetCrl or Client(crl=...) stays a
  FileError. Decided in revamp.md, dropped from known-issues.md.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-16 10:36:59 +01:00
parent 34eb6f4600
commit 39ba7fce6c
18 changed files with 115 additions and 31 deletions
+9
View File
@@ -227,6 +227,15 @@ check("None of its roles allowed: AuthError, NOT_ALLOWED", ok, detail)
missing = Client(f"{kitchen.host}:{kitchen.port}", os.path.join(folder, "missing.crt"), *pem[1:], dll_path=dll_path)
ok, detail = raises(missing.connect, BakaShrotError, "missing.crt", ErrorCode.FILE_ERROR)
check("A certificate file that isn't there: FILE_ERROR", ok, detail)
missing = Client(f"{kitchen.host}:{kitchen.port}", *pem, crl=os.path.join(folder, "missing.crl"), dll_path=dll_path)
ok, detail = raises(missing.connect, BakaShrotError, "missing.crl", ErrorCode.FILE_ERROR)
check("A CRL file given that isn't there: FILE_ERROR", ok, detail)
with open(os.path.join(folder, "kitchen.toml")) as settings:
no_crl_yet = settings.read() + '\ncrl = "missing.crl"\n'
with open(os.path.join(folder, "no-crl-yet.toml"), "w") as settings:
settings.write(no_crl_yet)
with Client.from_file(os.path.join(folder, "no-crl-yet.toml"), dll_path) as again:
check("A client.toml's CRL file not there yet: none, connected", again.connected, again.crl)
with Client(f"{kitchen.host}:{kitchen.port}", *pem, dll_path=dll_path) as again:
check("The same identity from PEM text: connected", again.connected and again.node == "kitchen", again.node)