- Use validator and jwks packages for JWT validation
- Replace manual JWKS caching with jwks.NewCachingProvider
- Add CustomClaims struct for https://unbound.se/roles claim
- Rename TokenFromContext to ClaimsFromContext
- Update middleware/auth.go to use new claims structure
- Update tests to use core.SetClaims and validator.ValidatedClaims
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Update git remote to git.unbound.se
- Add Gitea workflows: ci.yaml, pre-commit.yaml, release.yaml, goreleaser.yaml
- Delete .gitlab-ci.yml
- Update Go module path to gitea.unbound.se/unboundsoftware/schemas
- Update all imports to new module path
- Update Docker registry to oci.unbound.se
- Update .goreleaser.yml for Gitea releases with internal cluster URL
- Remove GitLab CI linter from pre-commit config
- Use shared release workflow with tag_only for versioning
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Introduce `AddUserToOrganization`, `RemoveAPIKey`, and
`RemoveOrganization` commands to enhance organization
management. Implement validation for user addition and
API key removal. Update GraphQL schema to support new
mutations and add caching for the new events, ensuring
that organizations and their relationships are accurately
represented in the cache.
Adds a new hashed key storage mechanism for API keys in the cache.
Replaces direct mapping to API keys with composite keys based on
organizationId and name. Implements searching of API keys using
hash comparisons for improved security. Updates related tests to
ensure correct functionality and validate the hashing. Also,
adds support for a new dependency `golang.org/x/crypto`.
Adds unit tests for the WebSocket initialization function to validate
behavior with valid, invalid, and absent API keys. Introduces a mock
cache implementation to simulate organization retrieval based on
hashed API keys. Ensures proper context value setting upon
initialization, enhancing test coverage and reliability for API key
handling in WebSocket connections.
Refactor API key processing to improve clarity and reduce code
duplication. Introduce detailed logging for schema updates and
initializations, capturing relevant context information. Use
background context for async operations to avoid blocking.
Implement organization lookup logic in the WebSocket init
function for consistent API key handling across connections.