bewaking-2110c3e7-ee40

job succeeded

starting new job...


→ running command: dir='/etc/byggsteg/job-clone//bewaking/trunk'
branch='trunk'
if ! command -v git >/dev/null 2>&1; then
  echo 'byggsteg: git is not on this deployment PATH, so the clone cannot be updated' >&2
  exit 1
fi
if ! cd "$dir"; then
  echo "byggsteg: cannot enter the clone $dir" >&2
  exit 1
fi
root=$(git rev-parse --show-toplevel 2>/dev/null)
if [ "$root" != "$(pwd -P)" ]; then
  echo "byggsteg: $dir is not a git checkout; remove it and the next run clones it again" >&2
  exit 1
fi
if ! origin=$(git remote get-url origin 2>/dev/null); then
  echo "byggsteg: $dir has no origin remote to fetch $branch from" >&2
  exit 1
fi
before=$(git rev-parse --short HEAD 2>/dev/null) || before=none
attempt=1
while :; do
  if GIT_TERMINAL_PROMPT=0 git fetch --quiet origin "+refs/heads/$branch:refs/remotes/origin/$branch"; then
    break
  fi
  if [ "$attempt" -ge 3 ]; then
    echo "byggsteg: could not fetch $branch from $origin after 3 attempts; is the branch still there, and is the remote reachable?" >&2
    exit 1
  fi
  echo "byggsteg: fetching $branch from $origin failed; retrying in $((attempt * 2))s" >&2
  sleep $((attempt * 2))
  attempt=$((attempt + 1))
done
if ! git checkout --quiet --force -B "$branch" FETCH_HEAD; then
  echo "byggsteg: fetched $branch from $origin but could not check it out" >&2
  exit 1
fi
after=$(git rev-parse --short HEAD)
if [ "$before" = "$after" ]; then
  echo "byggsteg: $branch was already at $after"
else
  echo "byggsteg: $branch moved from $before to $after"
fi


byggsteg: trunk moved from c41b09b to b811505

→ running command: cd /etc/byggsteg/job-clone/bewaking/trunk && uname -a

Linux wolk-jjba 7.2.11-gnu #1 SMP PREEMPT_DYNAMIC 1 x86_64 GNU/Linux

→ running command: cd /etc/byggsteg/job-clone/bewaking/trunk && git log --name-status HEAD^..HEAD

commit b8115053fb74ff78358062e1b4411631cac0c515
Merge: c41b09b 5b5c67d
Author: Josep Bigorra (Joe) <jjbigorra@gmail.com>
Date:   Thu Nov 5 08:59:08 2026 +0100

    Merge pull request 'README.org bijwerken' (#1) from jjba23-patch-1 into trunk
    
    Reviewed-on: https://codeberg.org/jjba23/bewaking/pulls/1

commit 5b5c67de437eacdb9907db7e3888c069f302378c
Author: jjba23 <jjbigorra@gmail.com>
Date:   Thu Nov 5 08:58:31 2026 +0100

    README.org bijwerken

M       README.org

→ running command: cd /etc/byggsteg/job-clone/bewaking/trunk && maak test


scanning directories for unit tests...
scanning present working directory for unit tests...

shuffled the files with seed 41251088 (replay with VERITAS_SEED=41251088)

found unit tests: (bewaking-spec.scm crypto-spec.scm web-spec.scm cli-spec.scm password-spec.scm)


running unit tests from file: bewaking-spec.scm, entrypoint: spec


ℹ️ info - shuffled with seed 41251088 (replay with VERITAS_SEED=41251088)
+----------------------------------------------+
[📑 suite] Sealed envelope (versioned, authenticated)
  [🧪 test] knowing the format is not knowing the plaintext
    [⚙️ assert] the plaintext, its Base16 and its Base64 do not appear in the envelope
    ✅ got: #t
    [⚙️ assert] the format is not hidden, only the content is
    ✅ got: #t
    [⚙️ assert] the public metadata is exactly what is authenticated
    ✅ got: (version key-id created-at expires-at)
  [🧪 test] data that is not a BWK3 envelope is refusederror decrypting token: misc-error: (#f ~A (open-envelope: not a bewaking envelope (expected BWK3).) #f)error decrypting object: misc-error: (#f ~A (open-envelope: not a bewaking envelope (expected BWK3).) #f)
    [⚙️ assert] arbitrary text is not an envelope
    ✅ got: #f
    [⚙️ assert] an unknown envelope version is not recognised
    ✅ got: #f
    [⚙️ assert] a truncated envelope is refused when it is opened
    ✅ got: #t
    [⚙️ assert] recognition is a version-tag check, not a structure check
    ✅ got: #t
    [⚙️ assert] a BWK3 envelope carrying an extra MAC field is refused
    ✅ got: #t
    [⚙️ assert] an unsupported version raises rather than being guessed at
    ✅ got: #t
    [⚙️ assert] a pre-versioning bare Base16 token is refused
    ✅ got: #f
    [⚙️ assert] a bare Base16 object is refused
    ✅ got: #f
  [🧪 test] key rotation with a keyringerror decrypting object: misc-error: (#f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)error decrypting object: misc-error: (#f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)
    [⚙️ assert] a keyring seals and opens by key id
    ✅ got: #t
  [🧪 test] no reader is left for the earlier formatserror decrypting token: misc-error: (#f ~A (open-envelope: not a bewaking envelope (expected BWK3).) #f)error decrypting object: misc-error: (#f ~A (open-envelope: not a bewaking envelope (expected BWK3).) #f)
    [⚙️ assert] a BWK1 envelope is not recognised
    ✅ got: #f
    [⚙️ assert] a BWK2 envelope is not recognised
    ✅ got: #f
    [⚙️ assert] a BWK2 envelope with no expiry is not recognised
    ✅ got: #f
    [⚙️ assert] no metadata is read out of a BWK1 envelope
    ✅ got: #f
    [⚙️ assert] no metadata is read out of a BWK2 envelope
    ✅ got: #f
    [⚙️ assert] an unreadable envelope is never reported as live
    ✅ got: #f
    [⚙️ assert] a BWK2 token is refused even with the keys that sealed it
    ✅ got: #f
    [⚙️ assert] a BWK1 object is refused likewise
    ✅ got: #f
  [🧪 test] the requested key id is embedded in generated tokens
    [⚙️ assert] the token carries the key id
    ✅ got: #t
  [🧪 test] the same plaintext never seals to the same value
    [⚙️ assert] a fresh salt and nonce make each envelope unique
    ✅ got: #t
    [⚙️ assert] equal objects seal to different strings
    ✅ got: #f
  [🧪 test] seal-envelope and open-envelope
    [⚙️ assert] the result is a versioned envelope
    ✅ got: #t
    [⚙️ assert] the envelope starts with the version tag
    ✅ got: #t
    [⚙️ assert] the module exposes the current format version
    ✅ got: BWK3
    [⚙️ assert] BWK3 is the only version produced and read
    ✅ got: (BWK3)
    [⚙️ assert] the plaintext round-trips
    ✅ got: top secret payload
    [⚙️ assert] a tampered envelope fails the integrity check
    ✅ got: #t
    [⚙️ assert] a wrong signing key fails the cipher check
    ✅ got: #t
    [⚙️ assert] passing a MAC key to open-envelope is refused, not ignored
    ✅ got: #t
  [🧪 test] tokens and objects are envelopes and reject tamperingerror decrypting token: misc-error: (#f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)error decrypting object: misc-error: (#f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)
    [⚙️ assert] generated tokens are enveloped
    ✅ got: #t
    [⚙️ assert] sealed objects are enveloped
    ✅ got: #t
    [⚙️ assert] a tampered token is rejected
    ✅ got: #t
    [⚙️ assert] a tampered object is rejected
    ✅ got: #t
  [🧪 test] a refusal never says which key id the keyring configures
    [⚙️ assert] the refusal is a refusal, not an accidental success
    ✅ got: #t
    [⚙️ assert] an unknown key id and a tampered body fail identically
    ✅ got: (misc-error #f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)
    [⚙️ assert] a keyring with no matching entry fails identically
    ✅ got: (misc-error #f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)
    [⚙️ assert] a retired key fails identically
    ✅ got: (misc-error #f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)
    [⚙️ assert] a key that is not active yet fails identically
    ✅ got: (misc-error #f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)
    [⚙️ assert] the refusal does not name the key id it could not resolve
    ✅ got: #f
    [⚙️ assert] and it does not name a configured key id either
    ✅ got: #f
    [⚙️ assert] nor does it carry any key material
    ✅ got: #f
    [⚙️ assert] an expired genuine envelope is still told apart, since it authenticated first
    ✅ got: #f
  [🧪 test] editing a genuine envelope never yields a plaintext
    [⚙️ assert] every single-digit mutation of a real envelope is refused
    ✅ got: #t
    [⚙️ assert] and every mutation of a real sealed object too
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Generic object encryption
  [🧪 test] decrypted data is data, never code
    [⚙️ assert] Guile refuses the #. read-eval syntax
    ✅ got: #t
    [⚙️ assert] a sealed payload that looks like code stays a string
    ✅ got: #.(+ 1 2)
  [🧪 test] encrypt-object and decrypt-objecterror decrypting object: misc-error: (#f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)
    [⚙️ assert] sealing produces a non-empty string
    ✅ got: #t
    [⚙️ assert] round-trips an arbitrary alist payload
    ✅ got: ((user . joe) (age . 42) (roles admin editor) (tags a b) (nested (x . 1) (y . 2)))
    [⚙️ assert] fails gracefully with a wrong signing key
    ✅ got: #f
    [⚙️ assert] round-trips a plain string payload
    ✅ got: just a string
    [⚙️ assert] round-trips a number payload
    ✅ got: 1234
    [⚙️ assert] round-trips a list payload
    ✅ got: (1 2 3)
+----------------------------------------------+
[📑 suite] generate-token
  [🧪 test] works properly with correct details
owner-details: ((id . "444959d3-7a8e-455e-b608-31e35145a2fa") (email . "someone@jointhefreeworld.org") (name . "Legolas son of Thandruil") (permissions byggsteg:modify-permissions byggsteg:job-create byggsteg:job-delete byggsteg:profile-create byggsteg:profile-delete byggsteg:user-create byggsteg:user-delete))

generate-token: BWK3.default.1793865558.-.017d767fd8dd26daf90d08f0e57ea117354b57c77af2690358362c016e1823b1ee25d63c0bc9f757feaa13de920f3e703536bb008ac2aac135a453ec5c16246b97e29324bd2e04bf01c0176eab0629f1a3501c224268785f013d29fd7ad65b01c778bf819ef5d2227c7565873fb23c5f111f94b5b793f5d70062ba60e2c20806fbf1b9e2bd3e40105d147646e53bd03e6d3306f623808d0dcf4bb3a67e28b17c8e4c7f9b88bb5c3e0f3d7844fa79e2bd835bc82bd83d90d1fb59e06cc318549965de593c35f6278f45223457accfb6242546a7dd48b70cb47cffbb4886ae7b494cd6d0fdb7251cf6aab853b6cf82010322832b59f1b6abf16e0bf9d4eb31e326ba91c5cd5b32b289d6c03a9446d7649cdeb4edec9ff98a5ad41dfc1982472328183b44166ad94faa55811ddb3e0afba4c85e752cb3266f4779597646ec2dcc57dc25552a374b9a9a4c96166033c787b91096cd920bc2075c5ff6a99e13435616d89cd33a41d1c3198d28c24e94e8120784e80f9306b04dea60c00f553e0c53af8664b6086824fd44d8a066d9eced20f4e5c2e8b21733b4b5c59c20c67c8b3428ab3b650ddc7321b87fa3beb74f0291effe013f65133f5872527cda493f8875c45690932023d78d9a1494fede9f30dc1ea1d63844ef1784f99f644e3416d77e1e746ab6cd29829042c83fd70758d8eb0b82b422b3304e971739617668ab4b1e7c51598de1d730814f4b75808c10025dfc61dafd1c850d1179b18c642a93bd581a078430c42eb8e157c2665c8fbb4de8d2f6bd904de321b2d48a080ec855394541bb29896b4b9d3200e275b94b11de1e54979ae8b9ec71642d0573e6c711e6d34bd15e857b79e77ccff74d852cd00a0cd0694c8d6481e1565126cc2eed8916647b9d10c5f32efdfa6a2eb3ac8c2a1eeb8ad7fe14974c70e27b122575aac6def45e1bffeef2c2c805761d307582b7fa76e031c8f9fe9d6f366a9b2a3784b970688d8ce88889b11d2d45199f3759dda900c24a6713b386fea73dd82b4d8e93733e625d33bba2bc4a5437666b7acb3a0928faa2ed7873aa7bfddcea3e7e9088cde4e3f246f65cc254096ae7cb85d159d6f3fd392f7c1611e7eb4994dab43913a74d21cba246fb620e932c1150386ee6dfb338b343302ea1e5184d103b948254d0c49714ea3a262d536c3363b853a75b2652ea129969155c314daffa084dff06439b7b2fbf05a5d7d6c77e34d10371e778af3486e4555b1510e07b8b9a83b1f7d137e89ee2ecbefdab5cf97e21c553f110ebd685b00c194d0c6d03ea

    ✅ got: #t
+----------------------------------------------+
[📑 suite] Permissions
  [🧪 test] has-needed-permissions?
    ✅ got: #f
    ✅ got: #t
    ✅ got: #f
    ✅ got: #t
    ✅ got: #t
    ✅ got: #t
    ✅ got: #f
    ✅ got: #f
+----------------------------------------------+
[📑 suite] Lossless Token Decryption
  [🧪 test] lossless-token
owner-details: ((id . "444959d3-7a8e-455e-b608-31e35145a2fa") (email . "someone@jointhefreeworld.org") (name . "Legolas son of Thandruil") (permissions byggsteg:modify-permissions byggsteg:job-create byggsteg:job-delete byggsteg:profile-create byggsteg:profile-delete byggsteg:user-create byggsteg:user-delete))

generate-token: BWK3.default.1793865558.-.018657f1180b9f258d24ec1c1331916f99214844013bc3f67dacbb2b925f33db4e04501a865c9228207c0f7dd67000cf1c69eeb3cde06084d1a278dab58e64f93de1d10fd21365d818cac83939e8f25bbcfede83a5742082b5b4e4f7ffe7d4ab9a14234ed400d8e172f3c6c4cc9da0c66908bf4388c50e7a156327dfdaab26a4bee4bd52cff6829f9d5c0b0f48ca5c6e5481880b82fc55df2c07914bea0e8e006a5cc7337622aecdf93e9fa94a5c51f5ab0a5a21d546fe842b0bd26f4b50459036038008e2e6e8813522190b7dd15c58927495c342099eb5d6e3b12f2e83fc74d0ef8c48fc365b68e77d5f289381046af7a8e4b73c4acda0a43f51b4fa36c226a3fcf01ce509f11a9b975347a96db7f5c25536bcce6f1dbd91185412375fce0a0f32eefdbea52977bb1b969b618809f662f79656515567bf800c5c94ac45dd3a40063fb20afc26250cd5743c8596a86fbaff547a25c423beafa8be69da8bffcfd7c398cbfbadda7810060ed850deb7fef0c10cd18f9ceccef00497af9250b91fa32f1be6be771116e59f4482030afccf12a15123b8c8ff18f7f9f48f81f33fd6c7b6a64c1cf6d39670d1e86006b3569767cd16c75e6be77620814c0bcb470327b36e69557f51efd5b988c63b4a429dfffea9fb3cc81766fb4125e37d7a85c10f94541bfc2446d0ef5bb4a9929a824d00407eb71dc245db66d465178325321e329ab7e2f4632d521d26ad01fa50c0d82dcb0ad3803dee26119e7ef78e9424e89ea370bb0da09b87f2154bfeac4e414aade1ea75ff89e283cffe2a5c62fd505a8568f2d11c67527d9c385cad00f8a4bd17f5cd514875376e846dab8b3d3fe7f4fd50fc17b1eb8786e319bfd408272291cec1b2060dfc1678437c619ab365d3363882f0147a829c401da9efb95acff4468f274b39946b0540bd0bcaeafa3ba92fa25971032c1f138ca670a4b190eb35f90164c23c282a9009eb04641113be3d4795fdd27a05cf462d32d7e476aa604617e46438542fcd7e378d2887d7c536c459bfc333aa60300080376a215b8e991ff2c5bd6968c43c60513afecd261f15f5dc48a0464022f713bcc78683ab74e1d98634a83e88d2ee701118f2e56628bba2b167196fb8fa36866949bb2c019827ddf5e816d8824f4b2a66f51224757de08b2845e8053b30aaea94800188a559481abac3e9ff86990857d1afcd064e1e5c777bc75d0be9f7d6a2c711e6078eaddadd80b8f5fd0cdf507701d69b1283beab393d7051ac56e8ece8aa8cfce6748ef4d1ea809a49f2c79b00e00d46

decoded: ((token-type . bewaking-token) (token-id . b9d73b17-6fb9-4066-b049-24890d804cc4) (token-created-at . 1793865558) (token-expires-at . 1794470358) (owner-id . 444959d3-7a8e-455e-b608-31e35145a2fa) (owner-email . someone@jointhefreeworld.org) (owner-name . Legolas son of Thandruil) (owner-permissions byggsteg:modify-permissions byggsteg:job-create byggsteg:job-delete byggsteg:profile-create byggsteg:profile-delete byggsteg:user-create byggsteg:user-delete))

    [⚙️ assert] works properly with correct details
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Token validity helpers
  [🧪 test] token-remaining-seconds and token-valid?
    [⚙️ assert] remaining seconds is positive for a live token
    ✅ got: #t
    [⚙️ assert] remaining seconds is negative for an expired token
    ✅ got: #t
    [⚙️ assert] a missing expiry raises an error
    ✅ success catching error: misc-error: (#f token-remaining-seconds: Token is invalid. Missing or malformed 'token-expires-at' () #f)
    [⚙️ assert] a freshly generated token is valid
    ✅ got: #t
    [⚙️ assert] a freshly generated token is not expired
    ✅ got: #f
+----------------------------------------------+
[📑 suite] Envelope metadata (key id, created-at, expiry)
  [🧪 test] invalid sealing options are rejected
    [⚙️ assert] expires-at and ttl-seconds are mutually exclusive
    ✅ got: #t
    [⚙️ assert] a non-integer ttl-seconds is rejected
    ✅ got: #t
    [⚙️ assert] a key id containing a dot is rejected
    ✅ got: #t
  [🧪 test] a malformed envelope is rejected
    [⚙️ assert] a missing body is refused
    ✅ got: #t
    [⚙️ assert] a non-numeric created-at is refused
    ✅ got: #t
    [⚙️ assert] a body that is not hexadecimal is refused
    ✅ got: #t
    [⚙️ assert] a truncated body is refused
    ✅ got: #t
    [⚙️ assert] sealing a non-string plaintext is refused
    ✅ got: #t
    [⚙️ assert] sealing without a signing key is refused
    ✅ got: #t
    [⚙️ assert] an empty key id is refused
    ✅ got: #t
  [🧪 test] metadata is reported without any key
    [⚙️ assert] created-at is a Unix timestamp
    ✅ got: #t
    [⚙️ assert] the key id is reported
    ✅ got: default
    [⚙️ assert] there is no expiry unless one was requested
    ✅ got: #f
    [⚙️ assert] the format version is reported
    ✅ got: BWK3
    [⚙️ assert] metadata is only read from envelopes
    ✅ got: #f
    [⚙️ assert] an envelope of a dropped format reports no metadata
    ✅ got: #f
    [⚙️ assert] a malformed BWK3 envelope reports no metadata
    ✅ got: #f
  [🧪 test] expired tokens and objects are refusederror decrypting token: misc-error: (#f ~A (open-envelope: the sealed data expired at 1000 (key 'default').) #f)error decrypting object: misc-error: (#f ~A (open-envelope: the sealed data expired at 1000 (key 'default').) #f)
    [⚙️ assert] a token sealed with a past expiry is refused
    ✅ got: #t
    [⚙️ assert] an object sealed with a past expiry is refused
    ✅ got: #t
    [⚙️ assert] expiry auditing ignores non-envelopes
    ✅ got: #f
  [🧪 test] ttl-seconds records an absolute expiry
    [⚙️ assert] created-at is the requested timestamp
    ✅ got: 1000
    [⚙️ assert] expires-at is created-at plus the ttl
    ✅ got: 4600
    [⚙️ assert] the envelope is live before its expiry
    ✅ got: #f
    [⚙️ assert] the envelope is expired after its expiry
    ✅ got: #t
  [🧪 test] keyring validity windows enforce rotation
    [⚙️ assert] a key inside its window seals and opens
    ✅ got: #t
    [⚙️ assert] a key past not-after cannot open data
    ✅ got: #t
    [⚙️ assert] a key before not-before cannot seal data
    ✅ got: #t
    [⚙️ assert] no keyring is needed to read metadata
    ✅ got: #t
  [🧪 test] expiry is enforced when opening
    [⚙️ assert] an expired envelope is refused
    ✅ got: #t
    [⚙️ assert] enforce-expiry? #f still opens it
    ✅ got: ttl payload
    [⚙️ assert] max-age-seconds enforces a rotation policy
    ✅ got: #t
  [🧪 test] the metadata is authenticated
    [⚙️ assert] editing created-at in a BWK3 envelope breaks its tag
    ✅ got: #t
    [⚙️ assert] editing the key id breaks the tag
    ✅ got: #t
    [⚙️ assert] extending the expiry in the envelope breaks the tag
    ✅ got: #t
    [⚙️ assert] removing the expiry marker breaks the tag
    ✅ got: #t
    [⚙️ assert] relabelling the version is refused
    ✅ got: #t
    [⚙️ assert] backdating created-at breaks the tag
    ✅ got: #t
    [⚙️ assert] editing the body breaks the tag
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Decryption
  [🧪 test] decrypt-tokenerror decrypting token: misc-error: (#f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)error decrypting token: misc-error: (#f ~A (open-envelope: not a bewaking envelope (expected BWK3).) #f)
    [⚙️ assert] fails gracefully when signing key is not valid
    ✅ got: #f
    [⚙️ assert] fails gracefully when token is not valid
    ✅ got: #f
    [⚙️ assert] works properly with valid token
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Garbling and Ungarbling
  [🧪 test] garble-ungarble
    ✅ got: dlrow
    ✅ got: lrow
    ✅ got: row
    ✅ got: ow
    ✅ got: w
    ✅ got: dlrow olleh
    ✅ got: hello world
    ✅ got: 2bstpgl2m57qpy1rxr7axw8i4fzyndoetjj8t8724ff70oo3czcwquddvj5epr52p3c8qal3g9urfrs9stw5zvxqfcbw6ocysx13obdmnvpme7vtv729fd4fsj2rqhwy
+----------------------------------------------+
[📑 suite] Token expiry
  [🧪 test] is-token-expired?
    [⚙️ assert] a token whose expiry is in the past is expired
    ✅ got: #t
    [⚙️ assert] a token whose expiry is in the future is not expired
    ✅ got: #f
    [⚙️ assert] a far-future token is not expired
    ✅ got: #f
    [⚙️ assert] a missing token-expires-at raises an error
    ✅ success catching error: misc-error: (#f is-token-expired?: Token is invalid. Missing or malformed 'token-expires-at' () #f)
    [⚙️ assert] a malformed token-expires-at raises an error
    ✅ success catching error: misc-error: (#f is-token-expired?: Token is invalid. Missing or malformed 'token-expires-at' () #f)
ℹ️ info - ran 10 tasks in: 1 seconds, 122726 microseconds

running unit tests from file: crypto-spec.scm, entrypoint: spec


ℹ️ info - shuffled with seed 41251088 (replay with VERITAS_SEED=41251088)
+----------------------------------------------+
[📑 suite] Authenticated payloads (AES-256-GCM)
  [🧪 test] hexadecimal that stands for bytes decodes to bytes
    [⚙️ assert] base16->bytes returns a bytevector
    ✅ got: #t
    [⚙️ assert] and keeps the raw octets, which base16-decode cannot
    ✅ got: 255
  [🧪 test] the payload records which derivation to use
    [⚙️ assert] PBKDF2 is identified by its own id
    ✅ got: 1
    [⚙️ assert] Argon2id is identified by a different id
    ✅ got: 2
    [⚙️ assert] the memory cost is recorded, in KiB
    ✅ got: 8192
    [⚙️ assert] the pass count is recorded
    ✅ got: 1
    [⚙️ assert] the lane count is recorded
    ✅ got: 1
  [🧪 test] the tag refuses every alteration
    [⚙️ assert] a flipped ciphertext digit is refused
    ✅ got: #t
    [⚙️ assert] a flipped tag digit is refused
    ✅ got: #t
    [⚙️ assert] an unknown key-derivation id is refused, not guessed at
    ✅ got: #t
    [⚙️ assert] different associated data is refused
    ✅ got: #t
    [⚙️ assert] the wrong key is refused
    ✅ got: #t
    [⚙️ assert] a truncated payload is refused
    ✅ got: #t
  [🧪 test] the payload is byte for byte the reference implementation's
    [⚙️ assert] PBKDF2-HMAC-SHA256, as Python's cryptography seals it
    ✅ got: 010707070707070707070707070707070709090909090909090909090915d0ed647041883a00a39c1a98153992e43396ca2ef78f30cf603552820a8ed81e320d38a87aee14ad4a7f41b2df7b369d6614500294e59e58
    [⚙️ assert] Argon2id with its parameters recorded, likewise
    ✅ got: 020000200000000001000000010707070707070707070707070707070709090909090909090909090996b424d50c29974261cc56650752a5237f7528271202d70046f0bc49c8c0bfefb86150c0b946a554a1590bec6d5f03409bbff197af7d782651
  [🧪 test] fresh salt and nonce still round-trip
    [⚙️ assert] a payload sealed with random salt and nonce opens
    ✅ got: #t
    [⚙️ assert] and so does an Argon2id one
    ✅ got: #t
    [⚙️ assert] associated data is optional: empty means none
    ✅ got: #t
    [⚙️ assert] a payload sealed without it does not open with it
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Randomness
  [🧪 test] random-bytes returns genuinely fresh bytes
    [⚙️ assert] the default length is the OpenSSL salt length
    ✅ got: 8
    [⚙️ assert] the requested length is honoured
    ✅ got: 32
    [⚙️ assert] two calls do not return the same bytes
    ✅ got: #t
    [⚙️ assert] a draw is not a constant
    ✅ got: #f
    [⚙️ assert] a draw is not all zeroes
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Sealed payloads (key derivation is recorded)
  [🧪 test] both readers keep their contracts
    [⚙️ assert] openssl-decrypt refuses what the OpenSSL CLI could not read
    ✅ got: #t
    [⚙️ assert] kdf-decrypt opens payloads produced by OpenSSL
    ✅ got: #t
  [🧪 test] the default KDF keeps the OpenSSL layout byte for byte
    [⚙️ assert] a fixed-salt PBKDF2 payload equals OpenSSL's own output
    ✅ got: #t
  [🧪 test] sizes and headers are validated
    [⚙️ assert] an 8-byte Argon2id salt is refused
    ✅ got: #t
    [⚙️ assert] a 16-byte PBKDF2 salt is refused
    ✅ got: #t
    [⚙️ assert] a payload with no known header is refused
    ✅ got: #t
  [🧪 test] tampering with the recorded parameters is not honoured
    [⚙️ assert] a changed pass count no longer decrypts
    ✅ got: #t
  [🧪 test] an Argon2id payload records its derivation and parameters
    [⚙️ assert] the header names the derivation
    ✅ got: Argon2id
    [⚙️ assert] the memory cost is recorded, in KiB
    ✅ got: 8192
    [⚙️ assert] the pass count is recorded
    ✅ got: 1
    [⚙️ assert] the lane count is recorded
    ✅ got: 1
  [🧪 test] an Argon2id payload round-trips and resists the wrong key
    [⚙️ assert] the same key opens it
    ✅ got: #t
    [⚙️ assert] another key does not
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Base16 encoding
  [🧪 test] known encodings
    [⚙️ assert] the empty string encodes to nothing
    ✅ got: 
    [⚙️ assert] lowercase hex digits are produced
    ✅ got: 68656c6c6f
    [⚙️ assert] a word encodes byte per byte
    ✅ got: 626577616b696e67
  [🧪 test] malformed input is rejected
    [⚙️ assert] an odd number of digits raises
    ✅ success catching error: misc-error: (#f bewaking: malformed hexadecimal input (odd number of digits). () #f)
    [⚙️ assert] non-hexadecimal characters raise
    ✅ success catching error: misc-error: (#f bewaking: malformed hexadecimal input. () #f)
    [⚙️ assert] embedded whitespace raises
    ✅ success catching error: misc-error: (#f bewaking: malformed hexadecimal input (odd number of digits). () #f)
  [🧪 test] decoding accepts both cases
    [⚙️ assert] lowercase hex decodes
    ✅ got: hello
    [⚙️ assert] uppercase hex decodes too
    ✅ got: hello
    [⚙️ assert] encoding then decoding is lossless
    ✅ got: hello
+----------------------------------------------+
[📑 suite] Encodings of raw bytes
  [🧪 test] Base16 round-trips arbitrary bytevectors
    [⚙️ assert] the empty bytevector round-trips
    ✅ got: #t
    [⚙️ assert] bytes that are not valid UTF-8 survive the round trip
    ✅ got: #t
  [🧪 test] Base64 round-trips arbitrary bytevectors
    [⚙️ assert] bytes that are not valid UTF-8 survive the round trip
    ✅ got: 3
+----------------------------------------------+
[📑 suite] OpenSSL-compatible sealing
  [🧪 test] data produced by OpenSSL itself can be opened
    [⚙️ assert] an openssl-encrypted string, random salt and all
    ✅ got: a secret that openssl sealed
  [🧪 test] a fixed-salt vector matches OpenSSL byte for byte
    [⚙️ assert] the ciphertext of a known salt and key
    ✅ got: U2FsdGVkX18AAQIDBAUGByAGpafcjamTQUX3eOyvQUE=
    [⚙️ assert] and it decrypts back
    ✅ got: bewaking
  [🧪 test] the salt must be 8 bytes
    [⚙️ assert] a short salt raises
    ✅ success catching error: misc-error: (#f bewaking: a PBKDF2 salt must be 8 bytes long. () #f)
  [🧪 test] failures are reported rather than ignored
    [⚙️ assert] the wrong key raises
    ✅ got: #t
    [⚙️ assert] the wrong key raises for OpenSSL-produced data too
    ✅ got: #t
    [⚙️ assert] input that is not Base64 raises
    ✅ got: #t
    [⚙️ assert] Base64 without a Salted__ header raises
    ✅ got: #t
    [⚙️ assert] a truncated body raises rather than returning garbage
    ✅ got: #t
  [🧪 test] round-trips
    [⚙️ assert] the empty string round-trips
    ✅ got: 
    [⚙️ assert] a longer payload round-trips
    ✅ got: a secret that openssl sealed
    [⚙️ assert] one padded block follows the 16-byte Salted__ header
    ✅ got: 32
+----------------------------------------------+
[📑 suite] Argon2id key derivation (RFC 9106)
  [🧪 test] the RFC 9106 Argon2id vector is reproduced
    [⚙️ assert] password 32x01, salt 16x02, secret 8x03, data 12x04, m=32, t=3, p=4
    ✅ got: 0d640df58d78766c08c037a34a8b53c9d01ef0452d75b65eb52520e96b01e659
  [🧪 test] invalid parameters are rejected
    [⚙️ assert] less than 8 KiB per lane is refused
    ✅ got: #t
    [⚙️ assert] zero passes is refused
    ✅ got: #t
    [⚙️ assert] zero lanes is refused
    ✅ got: #t
    [⚙️ assert] a non-integer memory cost is refused
    ✅ got: #t
    [⚙️ assert] a non-bytevector secret is refused
    ✅ got: #t
    [⚙️ assert] this libgcrypt provides Argon2
    ✅ got: #t
  [🧪 test] every parameter changes the derived bytes
    [⚙️ assert] a different pass count gives a different tag
    ✅ got: #f
    [⚙️ assert] a different salt gives a different tag
    ✅ got: #f
    [⚙️ assert] a different passphrase gives a different tag
    ✅ got: #f
+----------------------------------------------+
[📑 suite] HMAC-SHA256 (RFC 4231)
  [🧪 test] RFC 4231 test case 1
    [⚙️ assert] a 20-byte key of 0x0b over "Hi There"
    ✅ got: b0344c61d8db38535ca8afceaf0bf12b881dc200c9833da726e9376c2e32cff7
  [🧪 test] the digest is 32 bytes and key-sensitive
    [⚙️ assert] 64 hexadecimal digits, i.e. 32 bytes
    ✅ got: 64
    [⚙️ assert] changing the key changes the MAC
    ✅ got: #f
  [🧪 test] RFC 4231 test case 2
    [⚙️ assert] the key "Jefe" over its test message
    ✅ got: 5bdcc146bf60754e6a042426089575c75a003f089d2739839dec58b964ec3843
+----------------------------------------------+
[📑 suite] Derived key material
  [🧪 test] an unknown derivation is refused
    [⚙️ assert] no other function can be named
    ✅ got: #t
  [🧪 test] PBKDF2 key material is the PBKDF2 derivation's
    [⚙️ assert] derive-key-material agrees with the primitive it names
    ✅ got: 25ff9d4852ea4ea0ff9caf7aa33ed9e25f8d8a4eb2915445e0ff398292d67473
    [⚙️ assert] the requested length is produced
    ✅ got: 32
  [🧪 test] Argon2id key material honours its parameters
    [⚙️ assert] the full key-and-IV length can be derived
    ✅ got: 48
    [⚙️ assert] changing the pass count changes the material
    ✅ got: #t
    [⚙️ assert] changing the passphrase changes the material
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Authenticated payload hygiene
  [🧪 test] the associated data is authenticated but not stored
    [⚙️ assert] the associated data does not appear in the payload
    ✅ got: #f
    [⚙️ assert] one extra associated-data byte breaks the tag
    ✅ got: #t
  [🧪 test] the salt and the nonce are used, not decorative
    [⚙️ assert] editing a salt digit breaks the tag
    ✅ got: #t
    [⚙️ assert] editing a nonce digit breaks the tag
    ✅ got: #t
    [⚙️ assert] editing an Argon2id parameter digit is refused
    ✅ got: #t
  [🧪 test] every payload uses a fresh salt and nonce
    [⚙️ assert] sealing the same plaintext twice does not repeat the payload
    ✅ got: #f
    [⚙️ assert] the recorded salts differ, so the derived keys do too
    ✅ got: #f
    [⚙️ assert] the recorded nonces differ as well
    ✅ got: #f
  [🧪 test] an empty plaintext is still authenticated
    [⚙️ assert] the empty plaintext round-trips
    ✅ got: #t
    [⚙️ assert] even an empty payload carries a salt, a nonce and a tag
    ✅ got: #t
  [🧪 test] the recorded derivation cost is bounded before it is spent
    [⚙️ assert] a memory cost above the cap is refused, not allocated
    ✅ got: #t
    [⚙️ assert] a lane count above the cap is refused
    ✅ got: #t
    [⚙️ assert] a zero pass count is refused
    ✅ got: #t
    [⚙️ assert] less than 8 KiB per lane is refused
    ✅ got: #t
    [⚙️ assert] a cost inside the bounds is derived, then fails the tag: the bound is not a blanket refusal
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Base64 encoding
  [🧪 test] decoding is tolerant of line breaks
    [⚙️ assert] a trailing newline is ignored
    ✅ got: hello
    [⚙️ assert] encoding then decoding is lossless
    ✅ got: hello world
  [🧪 test] malformed input is rejected
    [⚙️ assert] non-alphabet characters raise
    ✅ success catching error: misc-error: (#f bewaking: malformed base64 input. () #f)
    [⚙️ assert] a truncated group raises
    ✅ success catching error: misc-error: (#f bewaking: malformed base64 input (bad length or padding). () #f)
    [⚙️ assert] data after padding raises
    ✅ success catching error: misc-error: (#f bewaking: malformed base64 input (data after padding). () #f)
    [⚙️ assert] an impossible amount of padding raises
    ✅ success catching error: misc-error: (#f bewaking: malformed base64 input (bad length or padding). () #f)
  [🧪 test] RFC 4648 test vectors
    [⚙️ assert] empty
    ✅ got: 
    [⚙️ assert] one byte of input
    ✅ got: Zg==
    [⚙️ assert] two bytes of input
    ✅ got: Zm8=
    [⚙️ assert] three bytes of input
    ✅ got: Zm9v
    [⚙️ assert] four bytes of input
    ✅ got: Zm9vYg==
    [⚙️ assert] five bytes of input
    ✅ got: Zm9vYmE=
    [⚙️ assert] six bytes of input
    ✅ got: Zm9vYmFy
+----------------------------------------------+
[📑 suite] PBKDF2-HMAC-SHA256
  [🧪 test] the key and IV material OpenSSL derives
    [⚙️ assert] 48 bytes over 10000 iterations, as `openssl kdf' reports
    ✅ got: cb14e1e1f7ac2fe57f2fcaa462d4ad903867450d9778d2ccf939d8ad3cb99982e0edbd06820c0a636f6fd53d4be339fd
  [🧪 test] published password/salt vectors
    [⚙️ assert] one iteration
    ✅ got: 120fb6cffcf8b32c43e7225256c4f837a86548c92ccc35480805987cb70be17b
    [⚙️ assert] two iterations
    ✅ got: ae4d0c95af6b46d32d0adff928f06dd02a303f8ef3c251dfd6e2d85a95474c43
    [⚙️ assert] 4096 iterations
    ✅ got: c5e478d59288c841aa530db6845c4c8d962893a001ce4e11a4963873aa98134a
+----------------------------------------------+
[📑 suite] Key-derivation specifications
  [🧪 test] unsupported specifications are refused
    [⚙️ assert] an unknown KDF name is refused
    ✅ got: #t
    [⚙️ assert] a string is not a KDF specification
    ✅ got: #t
    [⚙️ assert] a PBKDF2 cost the OpenSSL format cannot record is refused
    ✅ got: #t
    [⚙️ assert] an out-of-range Argon2id memory cost is refused
    ✅ got: #t
  [🧪 test] Argon2id defaults are filled in and reported
    [⚙️ assert] the defaults are 64 MiB, 3 passes, 1 lane
    ✅ got: ((kdf . argon2id) (memory-kib . 65536) (iterations . 3) (parallelism . 1))
    [⚙️ assert] given parameters are kept and the rest defaulted
    ✅ got: ((kdf . argon2id) (memory-kib . 262144) (iterations . 4) (parallelism . 1))
  [🧪 test] the default is PBKDF2 with its fixed cost
    [⚙️ assert] the module default names PBKDF2
    ✅ got: pbkdf2
    [⚙️ assert] its iteration count is the OpenSSL one
    ✅ got: 10000
ℹ️ info - ran 13 tasks in: 1 seconds, -662777 microseconds

running unit tests from file: web-spec.scm, entrypoint: spec


ℹ️ info - shuffled with seed 41251088 (replay with VERITAS_SEED=41251088)
+----------------------------------------------+
[📑 suite] Web chapter: sign-in seals a session into a cookie
  [🧪 test] bad credentials get no cookie at all
    [⚙️ assert] a wrong password is a plain 401
    ✅ got: 401
    [⚙️ assert] no session is created for a failed sign-in
    ✅ got: #f
    [⚙️ assert] the failure is reported, not swallowed
    ✅ got: invalid credentials
  [🧪 test] the cookie lifetime can be aligned with the token's
    [⚙️ assert] the requested lifetime is recorded in the cookie
    ✅ got: 86400
    [⚙️ assert] the envelope is sealed now
    ✅ got: #t
    [⚙️ assert] the payload lifetime is separate from the cookie's
    ✅ got: #f
  [🧪 test] a verified user gets a sealed session cookie
    [⚙️ assert] sign-in redirects, as the README's controller does
    ✅ got: 302
    [⚙️ assert] the redirect target is the dashboard
    ✅ got: /dashboard
    [⚙️ assert] the cookie value is a BWK3 envelope
    ✅ got: #t
    [⚙️ assert] the cookie is named as documented
    ✅ got: x-bewaking-session
    [⚙️ assert] (a) HttpOnly puts the cookie out of reach of JavaScript
    ✅ got: #t
    [⚙️ assert] (b) Secure keeps it off plain HTTP
    ✅ got: #t
    [⚙️ assert] (c) path "/" applies the cookie to the whole site
    ✅ got: /
    [⚙️ assert] (d) the cookie's lifetime matches #:token-validity-seconds
    ✅ got: 604800
+----------------------------------------------+
[📑 suite] Web chapter: sealed objects as stateless state
  [🧪 test] a cursor or half-finished form can be sealed the same way
    [⚙️ assert] a sealed cursor round-trips
    ✅ got: page-3
    [⚙️ assert] a client cannot page anywhere it was not sent
    ✅ got: #t
  [🧪 test] the link answers only to the key that sealed iterror decrypting object: misc-error: (#f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)
    [⚙️ assert] a link sealed elsewhere does not open here
    ✅ got: #f
  [🧪 test] a password-reset link round-trips with no table row
    [⚙️ assert] the link is a sealed envelope
    ✅ got: #t
    [⚙️ assert] the state comes back as an ordinary alist
    ✅ got: ((user . u-1) (action . reset-password))
    [⚙️ assert] the user id is not readable in the link
    ✅ got: #f
    [⚙️ assert] the hour-long lifetime is recorded in the header
    ✅ got: #t
  [🧪 test] an edited link is worth nothing
    [⚙️ assert] the link was edited in the mail client
    ✅ got: #f
    [⚙️ assert] and garbage is not a link either
    ✅ got: #f
  [🧪 test] an expired link is refused by the server, not by the client
    [⚙️ assert] before the expiry the link opens
    ✅ got: ((user . u-1) (action . reset-password))
    [⚙️ assert] after the expiry the server refuses it
    ✅ got: #f
    [⚙️ assert] and the header says so, for the log
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Web chapter: auditing what is safe to log
  [🧪 test] an expiry is reported as a time, and its absence as nothing
    [⚙️ assert] the audit reports no envelope expiry by default
    ✅ got: #f
    [⚙️ assert] a token sealed with a TTL records its expiry
    ✅ got: #t
    [⚙️ assert] and the audit helper agrees it is live
    ✅ got: #f
  [🧪 test] auditing garbage is #f, not an exception
    [⚙️ assert] an unparseable cookie yields no metadata
    ✅ got: #f
    [⚙️ assert] a missing cookie yields no metadata
    ✅ got: #f
    [⚙️ assert] a malformed BWK3 value yields no metadata
    ✅ got: #f
  [🧪 test] the envelope header is readable with no keys at all
    [⚙️ assert] the version is reported for the log
    ✅ got: BWK3
    [⚙️ assert] the key id is reported, which is what rotation is keyed on
    ✅ got: default
    [⚙️ assert] the creation time is reported
    ✅ got: #t
    [⚙️ assert] a fresh session is not expired
    ✅ got: #f
    [⚙️ assert] the audit output carries no key material
    ✅ got: #f
    [⚙️ assert] not the encryption key and not the signing key either
    ✅ got: #f
+----------------------------------------------+
[📑 suite] Web chapter: protecting a route
  [🧪 test] the payload is the identity, not the request
    [⚙️ assert] the owner id comes from the sealed payload
    ✅ got: u-1
    [⚙️ assert] a client-supplied user id is a hint, never the identity
    ✅ got: #f
  [🧪 test] the same session works as an API bearer token
    [⚙️ assert] the API route admits the header token
    ✅ got: 200
    [⚙️ assert] the token identifies the caller without a database round-trip
    ✅ got: u-1
    [⚙️ assert] the granted permissions are what the token says
    ✅ got: (read-only access-files)
  [🧪 test] an expired session is refused, and sign-out clears the cookie
    [⚙️ assert] a token whose payload lifetime has passed is refused
    ✅ got: 302
    [⚙️ assert] and the helper returns #f for it
    ✅ got: #f
    [⚙️ assert] sign-out redirects to the login page
    ✅ got: 302
    [⚙️ assert] sign-out deletes the cookie, the only cleanup there is
    ✅ got: 
    [⚙️ assert] the deletion cookie expires immediately
    ✅ got: 0
  [🧪 test] every failure mode is a refusal, never an admissionerror decrypting token: misc-error: (#f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)error decrypting token: misc-error: (#f ~A (bewaking: malformed BWK3 envelope (created-at)) #f)error decrypting token: misc-error: (#f ~A (open-envelope: not a bewaking envelope (expected BWK3).) #f)error decrypting token: misc-error: (#f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)
    [⚙️ assert] a request with no cookie is redirected to /login
    ✅ got: 302
    [⚙️ assert] an empty cookie is refused
    ✅ got: 302
    [⚙️ assert] a tampered cookie is refused
    ✅ got: 302
    [⚙️ assert] a cookie that is not a real envelope is refused
    ✅ got: 302
    [⚙️ assert] arbitrary text is refused
    ✅ got: 302
    [⚙️ assert] a second user's genuine session is admitted, as that user
    ✅ got: 200
    [⚙️ assert] and it admits the *second* user, not the first
    ✅ got: u-2
    [⚙️ assert] a keyring that cannot resolve the key id is refused
    ✅ got: 302
  [🧪 test] a permission that was never granted is refused on the server
    [⚙️ assert] the browser route refuses a route the user may not use
    ✅ got: 302
    [⚙️ assert] the API route answers 401 rather than 403-by-omission
    ✅ got: 401
    [⚙️ assert] the helper returns #f, not a partially authorized payload
    ✅ got: #f
    [⚙️ assert] the permission the user does have is enough
    ✅ got: #t
    [⚙️ assert] a route needing nothing is open to a valid session
    ✅ got: #t
  [🧪 test] the signed-in user is admitted
    [⚙️ assert] the browser route runs the handler
    ✅ got: 200
    [⚙️ assert] the handler sees the owner id from the payload
    ✅ got: u-1
    [⚙️ assert] the thunk's 'email' came back as 'owner-email'
    ✅ got: joe@example.com
    [⚙️ assert] and 'name' came back as 'owner-name'
    ✅ got: Joe
    [⚙️ assert] permissions travel inside the token
    ✅ got: (read-only access-files)
    [⚙️ assert] the payload carries its own token id
    ✅ got: #t
    [⚙️ assert] and its own payload expiry
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Web chapter: keys, rotation and revocation
  [🧪 test] retiring a key logs every session sealed with it out at onceerror decrypting token: misc-error: (#f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)
    [⚙️ assert] the retired key id stops opening sessions
    ✅ got: #f
    [⚙️ assert] the current key keeps working
    ✅ got: #t
  [🧪 test] keys stay secret and distinct, which is the whole requirementerror decrypting token: misc-error: (#f ~A (bewaking: the sealed data could not be opened: unknown, retired or wrong key, or the data was altered.) #f)
    [⚙️ assert] the encryption key does not appear in the token
    ✅ got: #f
    [⚙️ assert] nor does the signing key
    ✅ got: #f
    [⚙️ assert] swapping the two keys does not open the session
    ✅ got: #f
  [🧪 test] rotation needs no downtime and no forced logout
    [⚙️ assert] the key id is embedded in the envelope
    ✅ got: #t
    [⚙️ assert] new logins are sealed with the current key
    ✅ got: #t
    [⚙️ assert] an old token still opens: nothing to migrate
    ✅ got: #t
    [⚙️ assert] and so does a new one
    ✅ got: #t
ℹ️ info - ran 5 tasks in: 0 seconds, 559583 microseconds

running unit tests from file: cli-spec.scm, entrypoint: spec


ℹ️ info - shuffled with seed 41251088 (replay with VERITAS_SEED=41251088)
+----------------------------------------------+
[📑 suite] CLI dispatch
  [🧪 test] help and exit codes
    [⚙️ assert] help exits successfully
    ✅ got: 0
    [⚙️ assert] help prints the usage banner
    ✅ got: #t
    [⚙️ assert] help lists the token generate command
    ✅ got: #t
    [⚙️ assert] help documents the keyring option
    ✅ got: #t
    [⚙️ assert] help documents the rotation metadata options
    ✅ got: #t
    [⚙️ assert] help lists the token inspect command
    ✅ got: #t
    [⚙️ assert] version exits successfully
    ✅ got: 0
    [⚙️ assert] an unknown command exits with 1
    ✅ got: 1
    [⚙️ assert] a token subcommand is required
    ✅ got: 1
    [⚙️ assert] decrypting without keys fails
    ✅ got: 1
+----------------------------------------------+
[📑 suite] CLI object commands
  [🧪 test] object round-trip
    [⚙️ assert] object encrypt then decrypt round-trips a datum
    ✅ got: #t
  [🧪 test] object expiry policy
    [⚙️ assert] an object sealed with a past expiry is refused
    ✅ got: #t
+----------------------------------------------+
[📑 suite] CLI rotation metadata
  [🧪 test] token inspect audits the header without keys
    [⚙️ assert] inspect reports version, key id and expiry
    ✅ got: #t
    [⚙️ assert] inspect reports an expired envelope
    ✅ got: #t
    [⚙️ assert] inspect rejects a non-envelope token
    ✅ got: #t
  [🧪 test] expiry is sealed into tokens and enforced
    [⚙️ assert] an expired token exits with 1
    ✅ got: #t
    [⚙️ assert] --allow-expired opens it anyway
    ✅ got: #t
    [⚙️ assert] --max-age-seconds accepts fresh data
    ✅ got: #t
    [⚙️ assert] --ttl-seconds and --expires-at conflict
    ✅ got: #t
+----------------------------------------------+
[📑 suite] CLI token commands
  [🧪 test] wrong keys are rejected
    [⚙️ assert] a wrong signing key exits with 1
    ✅ got: #t
  [🧪 test] key id and keyring rotation
    [⚙️ assert] a keyring round-trips and rejects the wrong key
    ✅ got: #t
  [🧪 test] token round-trip
    [⚙️ assert] generate then decrypt preserves the payload
    ✅ got: #t
+----------------------------------------------+
[📑 suite] CLI password commands
  [🧪 test] password generate
    [⚙️ assert] generation exits successfully
    ✅ got: 0
    [⚙️ assert] the requested length is honoured
    ✅ got: 32
    [⚙️ assert] symbols are excluded on request
    ✅ got: (lowercase uppercase digit)
  [🧪 test] password strength
    [⚙️ assert] strength exits successfully
    ✅ got: 0
    [⚙️ assert] a common password is reported weak
    ✅ got: #t
+----------------------------------------------+
[📑 suite] CLI key derivation and dropped formats
  [🧪 test] a refusal does not reveal which key ids the keyring configures
    [⚙️ assert] an unknown key id and an edited body give the same message and exit code
    ✅ got: #t
  [🧪 test] tampering and missing arguments are refused
    [⚙️ assert] an edited token exits with 1
    ✅ got: #t
    [⚙️ assert] generating without an owner id exits with 1
    ✅ got: #t
    [⚙️ assert] sealing an object without keys exits with 1
    ✅ got: #t
  [🧪 test] envelopes of dropped formats are refused
    [⚙️ assert] a BWK1 token cannot be decrypted or inspected
    ✅ got: #t
    [⚙️ assert] a BWK2 token cannot be decrypted or inspected
    ✅ got: #t
    [⚙️ assert] an empty token is refused
    ✅ got: #t
  [🧪 test] the key derivation is chosen when sealing and read back when opening
    [⚙️ assert] an Argon2id token round-trips through the CLI
    ✅ got: #t
    [⚙️ assert] a KDF parameter without --kdf is refused
    ✅ got: #t
ℹ️ info - ran 6 tasks in: 1 seconds, -787440 microseconds

running unit tests from file: password-spec.scm, entrypoint: spec


ℹ️ info - shuffled with seed 41251088 (replay with VERITAS_SEED=41251088)
+----------------------------------------------+
[📑 suite] Password character classes
  [🧪 test] password-character-classes
    [⚙️ assert] lowercase letters only
    ✅ got: (lowercase)
    [⚙️ assert] uppercase letters only
    ✅ got: (uppercase)
    [⚙️ assert] digits only
    ✅ got: (digit)
    [⚙️ assert] all four classes are detected
    ✅ got: (lowercase uppercase digit symbol)
    [⚙️ assert] an empty password has no classes
    ✅ got: ()
+----------------------------------------------+
[📑 suite] Password entropy
  [🧪 test] password-entropy
    [⚙️ assert] an empty password has zero entropy
    ✅ got: 0
    [⚙️ assert] eight lowercase letters are ~37.6 bits
    ✅ got: #t
    [⚙️ assert] adding a character class increases the entropy
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Password strength
  [🧪 test] password-strength
    [⚙️ assert] a common numeric password scores 0
    ✅ got: 0
    [⚙️ assert] score 0 is labelled very weak
    ✅ got: very weak
    [⚙️ assert] a very short password scores 0
    ✅ got: 0
    [⚙️ assert] a long passphrase scores 4
    ✅ got: 4
    [⚙️ assert] score 4 is labelled very strong
    ✅ got: very strong
    [⚙️ assert] an empty password scores 0
    ✅ got: 0
    [⚙️ assert] stronger passwords have higher entropy
    ✅ got: #t
    [⚙️ assert] feedback is returned as a list
    ✅ got: #t;;; note: source file ./src/bewaking/bewaking.scm
;;;       newer than compiled /gnu/store/sd0a7gds2rgyzsb6rrds90vqypndfijj-profile/lib/guile/3.0/site-ccache/bewaking/bewaking.go
;;; note: source file ./src/bewaking/bewaking.scm
;;;       newer than compiled /run/current-system/profile/lib/guile/3.0/site-ccache/bewaking/bewaking.go
;;; found fresh local cache at /root/.cache/guile/ccache/3.0-LE-8-4.7/etc/byggsteg/job-clone/bewaking/trunk/src/bewaking/bewaking.scm.go
;;; note: source file ./src/bewaking/crypto.scm
;;;       newer than compiled /gnu/store/sd0a7gds2rgyzsb6rrds90vqypndfijj-profile/lib/guile/3.0/site-ccache/bewaking/crypto.go
;;; note: source file ./src/bewaking/crypto.scm
;;;       newer than compiled /run/current-system/profile/lib/guile/3.0/site-ccache/bewaking/crypto.go
;;; found fresh local cache at /root/.cache/guile/ccache/3.0-LE-8-4.7/etc/byggsteg/job-clone/bewaking/trunk/src/bewaking/crypto.scm.go
;;; note: source file ./src/bewaking/cli.scm
;;;       newer than compiled /gnu/store/sd0a7gds2rgyzsb6rrds90vqypndfijj-profile/lib/guile/3.0/site-ccache/bewaking/cli.go
;;; note: source file ./src/bewaking/cli.scm
;;;       newer than compiled /run/current-system/profile/lib/guile/3.0/site-ccache/bewaking/cli.go
;;; found fresh local cache at /root/.cache/guile/ccache/3.0-LE-8-4.7/etc/byggsteg/job-clone/bewaking/trunk/src/bewaking/cli.scm.go
;;; note: source file ./src/bewaking/password.scm
;;;       newer than compiled /gnu/store/sd0a7gds2rgyzsb6rrds90vqypndfijj-profile/lib/guile/3.0/site-ccache/bewaking/password.go
;;; note: source file ./src/bewaking/password.scm
;;;       newer than compiled /run/current-system/profile/lib/guile/3.0/site-ccache/bewaking/password.go
;;; found fresh local cache at /root/.cache/guile/ccache/3.0-LE-8-4.7/etc/byggsteg/job-clone/bewaking/trunk/src/bewaking/password.scm.go

    [⚙️ assert] common passwords get a specific warning
    ✅ got: #t
    [⚙️ assert] sequential runs are flagged in the feedback
    ✅ got: #t
  [🧪 test] strong-password?
    [⚙️ assert] a common word is not strong
    ✅ got: #f
    [⚙️ assert] a short mixed password is not strong
    ✅ got: #f
    [⚙️ assert] a long passphrase is strong
    ✅ got: #t
    [⚙️ assert] min-score lowers the bar
    ✅ got: #t
+----------------------------------------------+
[📑 suite] Password generation
  [🧪 test] generate-strong-password
    [⚙️ assert] default length is 24
    ✅ got: 24
    [⚙️ assert] a generated password is strong
    ✅ got: #t
    [⚙️ assert] default generated passwords use every class
    ✅ got: (lowercase uppercase digit symbol)
    [⚙️ assert] length is respected
    ✅ got: 32
    [⚙️ assert] symbols can be excluded
    ✅ got: (lowercase uppercase digit)
    [⚙️ assert] too-short a request raises an error
    ✅ success catching error: misc-error: (#f ~A (generate-strong-password: length must be at least 4 to cover every character class.) #f)
ℹ️ info - ran 4 tasks in: 0 seconds, 19839 microseconds

finished running tests


--------------------------------------------------------------

Maak 0.14.0: the infinitely extensible command runner

Loading tasks from Maak file: /etc/byggsteg/job-clone/bewaking/trunk/maak.scm

Executing Maak tasks: test


--------------------------------------------------------------

=> Running Maak task: test

  Run the project's tests.

  Execute command:
guix time-machine --channels=channels.scm -- shell -m manifest.scm -- guile -L ./src -L ./test -c '((@ (veritas runner) run-tests))'

Executing: guix time-machine --channels=channels.scm -- shell -m manifest.scm -- guile -L ./src -L ./test -c '((@ (veritas runner) run-tests))'

→ running command: cd /etc/byggsteg/job-clone/bewaking/trunk && sudo maak deploy



--------------------------------------------------------------

Maak 0.14.0: the infinitely extensible command runner

Loading tasks from Maak file: /etc/byggsteg/job-clone/bewaking/trunk/maak.scm

Executing Maak tasks: deploy


--------------------------------------------------------------

=> Running Maak task: deploy

  Generate documentation for the project and publish to the web directory.
API documentation saved to doc/api
index.texi: warning: must specify a title with a title command or @top

  Execute command:
guix time-machine --channels=channels.scm -- shell -m manifest.scm -- documenta api ./src/bewaking

Executing: guix time-machine --channels=channels.scm -- shell -m manifest.scm -- documenta api ./src/bewaking

  Execute command:
guix time-machine --channels=channels.scm -- shell -m manifest.scm -- texi2any -v --html --css-ref=https://jointhefreeworld.org/static/css/jointhefreeworld.css ./doc/api/index.texi

Executing: guix time-machine --channels=channels.scm -- shell -m manifest.scm -- texi2any -v --html --css-ref=https://jointhefreeworld.org/static/css/jointhefreeworld.css ./doc/api/index.texi
renamed './index' -> './doc/api-dist'
removed '/srv/http/jointhefreeworld.org/api-docs/bewaking/API.html'
removed '/srv/http/jointhefreeworld.org/api-docs/bewaking/bewaking_005fbewaking.html'
removed '/srv/http/jointhefreeworld.org/api-docs/bewaking/bewaking_005fcli.html'
removed '/srv/http/jointhefreeworld.org/api-docs/bewaking/bewaking_005fcrypto.html'
removed '/srv/http/jointhefreeworld.org/api-docs/bewaking/bewaking_005fpassword.html'
removed directory '/srv/http/jointhefreeworld.org/api-docs/bewaking'
mkdir: created directory '/srv/http/jointhefreeworld.org/api-docs/bewaking'
renamed 'doc/api-dist/API.html' -> '/srv/http/jointhefreeworld.org/api-docs/bewaking/API.html'
renamed 'doc/api-dist/bewaking_005fbewaking.html' -> '/srv/http/jointhefreeworld.org/api-docs/bewaking/bewaking_005fbewaking.html'
renamed 'doc/api-dist/bewaking_005fcli.html' -> '/srv/http/jointhefreeworld.org/api-docs/bewaking/bewaking_005fcli.html'
renamed 'doc/api-dist/bewaking_005fcrypto.html' -> '/srv/http/jointhefreeworld.org/api-docs/bewaking/bewaking_005fcrypto.html'
renamed 'doc/api-dist/bewaking_005fpassword.html' -> '/srv/http/jointhefreeworld.org/api-docs/bewaking/bewaking_005fpassword.html'

Executing: mv -v doc/api-dist/* /srv/http/jointhefreeworld.org/api-docs/bewaking
removed 'doc/api/index.texi'
removed directory 'doc/api'
removed directory 'doc/api-dist'
removed directory 'doc'
inspect the job's lambda expression
(lambda()
  `((task . ("maak-test" "maak-deploy"))
    (project . "bewaking")
    (branch-name . "trunk")
    (clone-url . "https://codeberg.org/jjba23/bewaking.git")))