mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #4483] [Benchmark] bench run takes a credential-env value of "none" as a real key and redacts the word everywhere #2006
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#2006
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @coryjett on GitHub (Oct 28, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/4483
Area
Benchmark
Desktop app, Terminal or source?
Terminal (Linux release 0.2.7, Control 0.1.52); the same code is on
mainat46c152a1.What happened
Our server runs without a key: the run config has
"api_key": "none", whichserve/server.pydefines as "no key".strata bench run --profile <run config> --no-start --credential-env STRATA_KEYwithSTRATA_KEY=nonein theenvironment then:
Bearer noneon every request (results.jsonsays"api_key_sent": true), and"Client monotonic time from request dispatch to the first mpty reasoning" for "nonempty".
Cause:
strata_cli/cli.py(bench run, ~line 1255) takesos.environ.get(a.credential_env)as the key as it is; the"none means no key" check (~line 1264) runs only for the config's own
api_key. Thenstrata_cli/bench_facts.pyredactor()(add(key, "<key>"), ~lines 45-50 and 61) replaces the key as a case-insensitive substring with no wordboundary (the
wordflag is used for the user and host names, not for the key). Any key of 4 or more characters thatis also a common word, or a short hex string that occurs inside a hash, corrupts the README, outputs.jsonl,
config.json and engine.log.
tools/strata_bench.py(~line 91) has the same substring replacement.Suggested fix: treat a credential value of "none" (case-insensitive) as no key in both places; redact the key only
on word boundaries and case-sensitively; and warn when a key is shorter than, say, 8 characters instead of lowering
the 4-character floor. Happy to send a PR with tests (
bench_facts.redactorhas no test today).Smallest steps or command that reproduce it
With a run config whose
api_keyis"none":STRATA_KEY=none strata bench run --profile <run config> --no-start --credential-env STRATA_KEY, then grep the output folder for<key>.Reproduction status
Reproduced locally: the folder in #4468 (
bench/results/2026-10-28-standard-rtx-3090-plus-rtx-3090-5250594b/,README corrected by hand, noted there).
Strata version
0.2.7 (engine 0.1.52, Control 0.1.52); code checked on
main46c152a1.Graphics card, memory and system
2x RTX 3090 24 GB, 2x Xeon E5-2620 v3, 256 GB, Ubuntu 26.10. Not hardware-specific.
Model, size and settings
Flash-Next IQ3_S; see #4468.
Logs
See above.
@Niko1221 commented on GitHub (Nov 5, 2026):
Hello coryjett,
Thank you. In Strata 0.2.11 a credential of "none" (any case) from
--credential-env, from the serving suite ofbench run, frommodels list --servedand fromtools/strata_bench.pyis treated as no key: it is not sent as a Bearer token,api_key_sentis false, and the word "none" is no longer redacted. A real key is now replaced as a whole word in its own case, so it no longer eats ordinary words or parts of hashes. We kept the existing 4-character floor rather than 8 so that a short real key is still removed from the files. If it still goes wrong on 0.2.11, tell us which command you ran and where the word appeared.The Strata project