22 Commits
Author SHA1 Message Date
Bertrand Gouny 5c36ee75f3 fix(bootstrap): allow management changes with old password 2026-10-27 15:45:57 +01:00
Bertrand Gouny 1dd24956f8 fix(ci): update Go toolchain and satisfy staticcheck
Use Go 1.26.10 across build tooling and Actions to resolve GO-2026-6809. Replace the password-history mode if/else chain with a tagged switch required by golangci-lint.

Validated with golangci-lint 2.14.0, go test -race, and govulncheck 1.9.0.
2026-10-27 13:12:37 +01:00
Bertrand Gouny 2761670739 feat(bootstrap): add scoped directory administrator
Create an optional administrator for user/group CRUD and password resets while protecting service accounts, password hashes/history and cn=config. Document the distinct data root, config root, admin and management roles.

Keep conditional history ACLs in their account directories as optional templates, activated by feature scripts after rendering in a temporary copy. Cover read-only sources, admin permissions, readonly history privacy and custom overrides.
2026-10-27 13:05:36 +01:00
Bertrand Gouny 02b5f0354d feat(bootstrap): configure management ACLs and align feature names
Expose management hidden attribute lists through bootstrap environment defaults and keep ACL rendering in the LDIF template. Align management assets with database-readonly naming and drop the MONITOR and AUDITLOG flag suffixes.

Update documentation, migration notes and integration coverage for custom hidden attributes, empty effective lists, audit logging and monitoring.
2026-10-27 11:10:13 +01:00
Bertrand Gouny b7c12e1c78 Add optional directory tree and scoped management account 2026-10-26 21:54:40 +01:00
Bertrand Gouny 18917aaf73 fix(ppolicy): hide password history from readonly accounts
Load a targeted pwdHistory deny rule only when ppolicy and the data read-only
account are enabled. Continue normal ACL evaluation for other identities so
administrator access, replication and later custom grants remain available.

Add regression scenarios for default permissions, disabled features, replicated
history and password reuse, custom grants and bootstrap fragment replacement.
Document that existing databases require an explicit ACL update.
2026-10-25 20:23:30 +01:00
Bertrand Gouny 89dbc0177c feat(ctl): validate LDIF files and directories without importing 2026-10-19 20:21:01 +02:00
Bertrand Gouny b1a45fe17b feat(bootstrap): expose global request limits 2026-10-19 20:10:01 +02:00
Bertrand Gouny c10e2054f2 feat(ppolicy): add progressive account lockouts 2026-10-19 20:06:16 +02:00
Bertrand Gouny 553632f663 feat(ctl): hash passwords from files and stdin 2026-10-19 20:00:43 +02:00
Bertrand Gouny 5f7b2aa315 feat(ppolicy): add optional account inactivity limit 2026-10-19 19:46:36 +02:00
Bertrand Gouny 6cf97026b6 feat(bootstrap): load enabled feature modules automatically 2026-10-19 19:24:34 +02:00
Bertrand Gouny bb946e50eb feat: restart openldap when tls file contents change
Add an optional TLS watcher with content fingerprints to ignore duplicate
notifications and unchanged Kubernetes projections.

Use explicit paths under /run/container/tmp for runtime temporary files
and require baseimage 2.1.0. Cover TLS renewal and read-only /tmp.
2026-10-19 14:59:54 +02:00
Bertrand Gouny bd8218b8a5 Fix bootstrap templates on read-only volumes 2026-10-19 10:11:50 +02:00
Bertrand Gouny 946c017bfd feat(auditlog): add optional file-based auditing 2026-10-18 23:56:50 +02:00
Bertrand Gouny 8e34fdbc19 feat(bootstrap): add last successful bind tracking 2026-10-18 23:29:58 +02:00
Bertrand Gouny d7fd334797 feat(refint): add automatic empty-group placeholder 2026-10-18 22:41:54 +02:00
Bertrand GounyandClaude Opus 5.5 5df4f23a40 ci: build each arch natively and publish them together
Build and test each arch on its own runner (ubuntu-latest and
ubuntu-24.04-arm) instead of under QEMU, with osixia/dagger-build OCI
archives: on tags, build jobs export them as artifacts, and the publish
job deploys them as a single multi-arch image per tag.

Integration scenarios now run on every built image, so on arm64 too:
each runner builds its own arch, so the engine platform filter never
skipped anything.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 23:47:50 +02:00
Bertrand GounyandClaude Opus 5.5 e50450d74d fix(restore): roll back to the previous data when the restore fails
openldap-ctl restore --force deleted existing config and data before
loading the backup: a failing slapadd left OpenLDAP stopped with empty or
partial databases. Existing data is now moved to a hidden
.restore-previous directory in the same volume, removed when the restore
succeeds, and put back otherwise. OpenLDAP is restarted in both cases if
it was running. A leftover .restore-previous directory from an
interrupted restore blocks the next restore.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 21:25:20 +02:00
Bertrand GounyandClaude Opus 5.5 8660345710 fix(replication): quote syncrepl credentials and reject double quotes
The replication password was not quoted in olcSyncRepl: a password with
spaces made the bootstrap fail. The default sync repl template now quotes
credentials. slapd can not store an escaped double quote followed by a
space in olcSyncRepl, so passwords with double quotes are rejected with an
explicit error.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 21:12:58 +02:00
Bertrand GounyandClaude Opus 5.5 8c6617e0d2 fix(backup): limit --clean to backup files and add --clean-prefix
openldap-ctl backup --clean removed every file older than N days in the
backup directory, including manual and pre-upgrade backups. It now only
removes backup files, and --clean-prefix limits it to backups starting
with a prefix.

Cron backups are named openldap-cron-<date>-<version> and cleaned with
--clean-prefix openldap-cron-.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 20:58:36 +02:00
Bertrand GounyandClaude Opus 5.5 52230d6cd7 feat: update to osixia/baseimage 2.0.0 and add integration tests
- Update the base image to osixia/baseimage:alpine-2.0.0 and build the
  CI/CD tool with osixia/dagger-build (Go 1.26.9).
- Add Dagger integration tests: default bootstrap, alternative schemas,
  all compatible modules and schemas with every bootstrap feature on a
  3-node replicated cluster with TLS required, backup/restore, simulated
  upgrade and upgrade from previous releases.
- Fix bootstrap failing with "Argument list too long" with large schemas:
  load them with LDIF include: lines, fail on missing schemas.
- Default OPENLDAP_BOOTSTRAP_PPOLICY_DEFAULT_CHECK_QUALITY to 1 so
  pwdMinLength is enforced.
- Align the CI workflow with osixia/container-baseimage and add Dependabot.
- Document available schemas and modules and their incompatibilities.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 20:37:20 +02:00