← Back to issue list

repo: key management refactor

View original Github issue

Metadata

Project
snapcraft
Number
#3359
Type
pull request
State
merged
Author
cjp256
Labels
—
Created
Updated
Closed

Current evaluation

Merged #3359 in commit 8272e54e3, decoupling key handling into AptKeyManager, enforcing 40-character key IDs, and tightening key-asset validation and tests.

Resolution: closed resolved

Reason: PR #3359 was approved and merged as commit 8272e54e3. The commit introduced AptKeyManager and updated validation and tests for key IDs and asset paths.

Evaluated by: mr-cal-bot

No scores available.

Issue body

- Decouple key management from _deb.Ubuntu, introducing a new apt_key_manager.AptKeyManager class. - Improve unit test coverage of key management. - Pivot to enforcing the 40-character key ID. Update the schema and package repository validation checks to enforce this. Update the spread tests to comply. - Update the key asset search to require matching keys to be found in snap/keys/12345678.asc, where 12345678 is the first eight characters of the key ID. Update the schema and package repository validation checks to enforce this. Update the spread tests to comply. This functionality should finalize key management for the stabilization of package-repositories, with the exception of a related change to ensure all key assets are used. Signed-off-by: Chris Patterson <chris.patterson@canonical.com> - [ ] Have you followed the [guidelines for contributing](https://github.com/snapcore/snapcraft/blob/master/CONTRIBUTING.md)? - [ ] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)? - [ ] Have you successfully run `./runtests.sh static`? - [ ] Have you successfully run `./runtests.sh tests/unit`? -----

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved Merged #3359 in commit 8272e54e3, decoupling key handling into AptKeyManager, enforcing 40-character key IDs, and tightening key-asset validation and tests.
stealth/space-bunny-alpha — closed resolved Merged PR #3359 (commit 0062d1c), introducing AptKeyManager and enforcing 40-character key IDs and matching snap/keys/<ID-prefix>.asc asset paths.
stealth/space-bunny-alpha — closed resolved Merged key-management refactor introducing AptKeyManager, enforcing 40-character key IDs and key asset paths, and expanding tests; landed in commit 8272e54e3.
stealth/space-bunny-alpha — closed resolved Merged PR #3359 (commit 8272e54e3), introducing AptKeyManager, enforcing 40-character key IDs, validating key asset paths, and expanding key-management tests.
stealth/space-bunny-alpha — closed resolved Merged to master as commit 8272e54e3 ("repo: key management refactor with key ID handling changes (#3359)"). Decoupled key management from _deb.Ubuntu into a new apt_key_manager.AptKeyManager, enforcing 40-char key IDs and snap/keys/12345678.asc asset lookup.
stealth/space-bunny-alpha — closed resolved Merged PR #3359 decoupled key handling into AptKeyManager, enforced 40-character key IDs, and updated key-asset validation and tests.
stealth/space-bunny-alpha — closed resolved Merged #3359 via 8272e54e3, extracting AptKeyManager, enforcing 40-character key IDs, and validating key asset paths. Follow-up #3486 later changed the filename suffix to the last eight key-ID characters.
qwen/qwen3.6-35b-a3b — — Merged a key management refactor that decouples logic into a new AptKeyManager class. Enforces 40-character key IDs, updates schema validation, and adjusts asset search paths. Approved, passed CI, and increased test coverage by 0.10%.
qwen3.6-35b-a3b-mtp-q6 — — PR #3359 merged, refactoring key management into AptKeyManager and decoupling it from _deb.Ubuntu. It enforces 40-character key IDs, updates schema validation, and improves test coverage. The changes finalize package-repositories key management.

Update history

No update history recorded yet.

Related work

  • Related To: snapcraft#3486 (confidence 90%)

    Follow-up PR changed the key-asset filename convention from the first eight key-ID characters to the last eight.

Related issues

Issue Project State Summary Similarity
#85 keys: make AptKeyManager.install_key() more robust craft-archives closed Closed unmerged; the intended AptKeyManager.install_key() robustness work landed in craft-archives#86 via commit 9a9706b.
72%
#86 keys: make AptKeyManager.install_key() more robust craft-archives merged Merged as 9a9706b: AptKeyManager.install_key() now accepts multi-key input, tolerates GPG diagnostics, and can verify a target fingerprint.
71%