Skip to content

feat: release Buncker v1.0.0#16

Merged
Romain-Grosos merged 15 commits intomainfrom
feat/release-1.0.0
Mar 9, 2026
Merged

feat: release Buncker v1.0.0#16
Romain-Grosos merged 15 commits intomainfrom
feat/release-1.0.0

Conversation

@Romain-Grosos
Copy link
Contributor

Summary

  • Docker Compose analysis (buncker analyze on docker-compose.yml)
  • RPM packaging for RHEL/Fedora alongside existing .deb
  • Logrotate configuration for /var/log/buncker/
  • --restrict-oci flag to require Bearer auth on OCI /v2/* endpoints
  • Manifest cache TTL with staleness detection and stale_manifests in status/analyze
  • Security hardening: TLS 1.2 minimum, RSA-4096, PBKDF2 600k iterations, tar path traversal protection, blob symlink rejection, HTTP security headers, file permissions 0600
  • Version bump to 1.0.0, changelog, README, and documentation updates

Changes

Features

  • Compose support (buncker/compose.py, buncker/resolver.py): parse docker-compose.yml and resolve all image references
  • RPM packaging (packaging/*/rpm/): .spec files + build-in-docker-rpm.sh build script
  • Logrotate (packaging/buncker/logrotate): daily rotation, 30 days retention, mode 0640
  • OCI restricted mode (buncker/handler.py, buncker/__main__.py): --restrict-oci CLI flag with WWW-Authenticate: Bearer on 401
  • Manifest TTL (buncker/registry_client.py): configurable manifest_ttl (default 30 days), stale manifest reporting

Security (10 fixes)

  • Tar zip-slip protection (Python < 3.12 path validation, 3.12+ filter="data")
  • TLS: minimum 1.2, restricted cipher suites (ECDHE+AESGCM/CHACHA20)
  • API tokens: warn on insecure file permissions, reject empty Bearer tokens
  • X-Buncker-Checksum hex format validation
  • Blob/metadata files chmod 0600, symlink detection before write
  • PBKDF2 iterations: 100k -> 600k
  • RSA key size: 2048 -> 4096 for self-signed certs
  • HTTP headers: X-Content-Type-Options, X-Frame-Options, Cache-Control

Tests

  • 560 unit/integration tests passing (+ 9 skipped platform-specific)
  • 40/40 Docker integration tests (3-container air-gapped simulation)
  • New test coverage for Compose, RPM, OCI restricted mode, manifest TTL, and all security fixes

Test plan

  • ruff check - all checks passed
  • ruff format --check - 56 files formatted
  • pytest - 560 passed, 9 skipped
  • Docker integration (3 containers) - 40/40 PASS across 3 phases:
  • Phase 1: USB flow (setup, pair, fetch, import, OCI serve)
  • Phase 2: LAN client with auth (tokens, TLS, PUT import)
  • Phase 3: OCI restricted mode (Bearer auth on /v2/*)

PRD v3.0: add In Scope V3, FR27-FR30, update NFR1 for python3-yaml.
Roadmap updated: remove Windows/GPG, add RPM packaging.
5 stories: Compose analysis (7.1), RPM packaging (7.2),
log rotation (7.3), OCI auth restriction (7.4),
manifest cache TTL (7.5).
New buncker/compose.py module parses docker-compose.yml files,
extracting image: refs and build.dockerfile paths from services.
Integrated with resolver pipeline via resolve_compose() with
blob deduplication. CLI --compose flag and API compose_content
field added. python3-yaml dependency added to .deb packaging.
RPM spec files for buncker and buncker-fetch with same file layout
as .deb. Makefile build-rpm target, CI build-rpm + test-rpm-install
jobs on Fedora, build-in-docker-rpm.sh helper script. RPM spec
tests added. Also fixed .deb install list for auth.py and compose.py.
Daily rotation, 30 days retention, copytruncate, compress.
Shipped in .deb via conffiles and .rpm via %config(noreplace).
Makefile updated to include logrotate in deb build.
When enabled, /v2/* endpoints require a valid Bearer token (readonly
or admin). Returns 401 with WWW-Authenticate challenge header per
OCI Distribution Spec. Guard prevents starting with --restrict-oci
when API auth is not configured. Also supports oci.restrict config.
Add ManifestCache.is_stale() and count_stale() methods. Resolver
now emits warnings for stale manifests during analyze. New config
option manifest_ttl (default 30 days). Generate-manifest supports
refresh_stale parameter to include stale manifests for re-download.
GET /admin/status now includes stale_manifests count.
All Epic 7 features (Compose analysis, RPM packaging, logrotate,
OCI auth restriction, manifest TTL) are implemented and tested.
534 tests pass across the full suite.
- Add QA gate files for stories 7.1-7.5 (all PASS)
- Add QA Results sections to all Epic 7 story files
- Fix RPM spec versions 0.9.0 -> 1.0.0 (PKG-001)
- Add test for buncker-fetch refresh:true manifest re-download (TEST-001)
- Update README: v1.0.0 badge, RPM install section, RHEL/Fedora support,
  --compose/--restrict-oci/--refresh-stale flags, manifest_ttl/oci.restrict
  config, hosts.toml example, roadmap marked Done, make build-rpm
- Add TestGlobalFlowOciRestricted e2e test: full cycle with --restrict-oci
  (401 without token, 200 with RO/admin, WWW-Authenticate header, blob/manifest/HEAD auth)
- Add Phase 3 to integration test-full-flow.sh: 9 OCI restriction checks
  across 3 containers (buncker-offline, client, online)
- Add python3-yaml dependency to offline Dockerfile for v1.0.0 Compose support
Add python3-yaml to requirements and deps, mention .rpm packaging in
CONTRIBUTING.md, add Compose/staleness to Key Features, document
automated 3-phase integration test script in integration README.
SEC-01: validate tar member paths for zip-slip on Python < 3.12
SEC-02: enforce TLS 1.2 minimum and restrict cipher suites
SEC-03: warn on insecure api-tokens.json file permissions at load
SEC-04: reject empty Bearer token value early
SEC-05: validate X-Buncker-Checksum as strict sha256:<64 hex>
SEC-06: set blob and metadata files to mode 0600
SEC-07: bump PBKDF2 env key iterations from 100k to 600k
SEC-08: use RSA-4096 for self-signed CA and server certificates
SEC-09: add X-Content-Type-Options, X-Frame-Options, Cache-Control
SEC-10: reject symlinks at blob destination before write

Also: document rate limiting, bind address, cert SANs in README,
add explicit mode to logrotate config.
@Romain-Grosos Romain-Grosos added this to the v1.0.0 milestone Mar 9, 2026
@Romain-Grosos Romain-Grosos self-assigned this Mar 9, 2026
- Add pyyaml to CI pip install (fixes ModuleNotFoundError on yaml)
- Fix symlink check in store.py (check before exists() for Linux)
- Add tests for handler GC endpoints, compose analysis, logs edge cases,
  disk space check, import/generate without crypto keys, HEAD /v2/
- Add tests for compose edge cases (invalid YAML, non-dict services)
- Add tests for resolver staleness, internal images, compose Dockerfile
- Add python3-yaml to deb-install test Dockerfile (new buncker dependency)
- Add make to Fedora container for rpm build step
@Romain-Grosos Romain-Grosos merged commit bc0e744 into main Mar 9, 2026
7 checks passed
@Romain-Grosos Romain-Grosos deleted the feat/release-1.0.0 branch March 9, 2026 21:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant