Skip to content

hashserv: tighten unihash handling

Anders Heimer bitbake-devel 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2hashserv/tests: use valid 64-character unihasheslib/hashserv/tests.py+110 -540 replies
2/2hashserv: validate unihash valueslib/bb/siggen.py lib/bb/tests/siggen.py lib/hashserv/__init__.py +2 more+114 -60 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/2] hashserv: tighten unihash handling

This series tightens unihash handling so hashserv accepts and stores only valid lowercase 64-character hexadecimal unihash values, and BitBake treats BB_UNIHASH as literal hash data when reading it from the datastore.

The first patch updates existing hashserv test fixtures to use valid 64-character unihash-shaped values.

The second patch adds unihash validation and focused coverage for hashserv report paths and BitBake siggen handling. Invalid unihashes reported to hashserv, or returned by hashserv to BitBake, are rejected before use.

Validation:
- py_compile on touched Python files
- focused hashserv/siggen tests
- broader hashserv and siggen regression tests

Anders Heimer (2):
hashserv/tests: use valid 64-character unihashes
hashserv: validate unihash values

 lib/bb/siggen.py         |   9 +-
 lib/bb/tests/siggen.py   |  47 ++++++++++
 lib/hashserv/__init__.py |   7 ++
 lib/hashserv/server.py   |  27 +++++-
 lib/hashserv/tests.py    | 194 ++++++++++++++++++++++++++++-----------
 5 files changed, 224 insertions(+), 60 deletions(-)
Signature · 1 line
2.34.1