A minimal LDAP-backed service that exposes member lookup and provisioning workflows via /v1/member.
-
GET /livez— liveness endpoint (always returns 200 OK with{"status":"ok"}) -
GET /readyz— readiness endpoint (returns 200 if LDAP is reachable, 503 otherwise) -
GET /v1/member?username=<value>— resolves a user by UPN or sAMAccountName and returns normalized attributes viaserver.UserClientbacked byldaps.Clientin production and fakes in tests. -
POST /v1/member— sanitizes the JSON payload (trim + lowercase forusername/OrganizationalUnit) withhandlers.SanitizeUserbefore invokingldaps.Client.AddUser. -
DELETE /v1/member— TODO: expose member removal once LDAP delete semantics and authorization are finalized. -
PATCH /v1/member— TODO: introduce attribute updates once LDAP modify flows are defined.
See docs/dev-setup.md for the quick-start instructions, environment variables, Docker guidance, troubleshooting tips, and the testing commands (go test ./...).
See TODO.md for a complete list of planned features and improvements.
Key upcoming features:
- Implement
DELETE /v1/memberandPATCH /v1/memberendpoints - Add API authentication and rate limiting
- Publish as GitHub package (deferred until DELETE and PATCH are complete)
- Implement connection pooling/reconnect semantics
.
├── cmd/
│ └── goberus/ # application entrypoint and process lifecycle
├── config/ # configuration loading and validation
├── internal/
│ └── httpserver/ # server composition, route wiring, JSON helpers
├── ldaps/ # LDAP client, models, helpers
├── middleware/ # HTTP middleware (RequestID, Recover, Logger)
├── server/ # HTTP handlers and server-facing types
├── handlers/ # auxiliary handler helpers used in tests/CLI
├── tests/
│ └── integration/ # end-to-end integration tests with Samba AD
├── docs/ # developer and operational documentation
├── ADR/ # Architecture Decision Records
├── docker-compose.yml # local test environment (Samba AD + Goberus)
├── Dockerfile
├── Makefile
└── README.md
Goberus is open-source software distributed under the terms of the GNU General Public License v3. See LICENSE for the full text and warranty disclaimer.