Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
665e84e
Initial migration to openSSL only version
mroest Apr 28, 2026
792c93d
Simplify backend/key configuration
mroest Apr 29, 2026
5962cae
Simplify backend/key configuration parameters and cleanup code
mroest Apr 29, 2026
b689deb
Refactor Dockerfile to use ARG for environment variables in cache warmup
mroest Apr 29, 2026
8294f86
Refactor configuration and enhance error handling
mroest Apr 29, 2026
242bdc3
Add ARG directives for APP_ENV and APP_DEBUG in Dockerfile
mroest Apr 29, 2026
1859371
perf: add benchmark script, debug timing logs, and performance report
mroest Apr 29, 2026
35f7641
fix: update README to clarify parameters for decrypt operation and CI…
mroest Apr 29, 2026
b605724
feat: enhance configuration validation and logging for exceptions
mroest Apr 29, 2026
eaf94a2
Implement brute-force rate limiting for authentication failures
mroest Apr 29, 2026
f6210dd
fix: clarify authentication method in documentation
mroest Apr 29, 2026
92fb50a
fix: improve stats collector cleanup in performance test script
mroest Apr 29, 2026
5eff67f
feat: add initial draft of OWASP ASVS 5.0 Level 1 security audit report
mroest Apr 29, 2026
66b9e4f
fix: use docker run in CI and protect vendor volume from bind mount
mroest Apr 29, 2026
01e327e
feat: add dev entrypoint that runs composer install on container start
mroest Apr 29, 2026
45a6302
fix: skip composer install in entrypoint when APP_ENV=prod
mroest Apr 29, 2026
113a3d8
fix: delegate to upstream /entrypoint.sh after composer install
mroest Apr 29, 2026
cc6febf
fix: include tests and dev config in image; avoid duplicate CI runs
mroest Apr 29, 2026
2a02bee
fix: keep test/dev files out of prod image via selective COPY
mroest Apr 29, 2026
4da142b
fix: update Dockerfile and entrypoint for production environment setup
mroest Apr 30, 2026
b433c07
fix: entrypoint now executes passed commands instead of always starti…
mroest Apr 30, 2026
b3609c6
fix: use canonical ENTRYPOINT+CMD pattern for entrypoint
mroest Apr 30, 2026
b666907
fix: resolve feedback, update configuration and error handling for im…
mroest Apr 30, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
.git
.worktrees
.phpunit.result.cache
.phplint.yml
.phplint.cache
phpcs.xml
phpunit.xml.dist
docs
tests
vendor
var/cache
var/log
Expand Down
17 changes: 17 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# editorconfig.org

root = true

[*]
charset = utf-8
end_of_line = lf
indent_size = 4
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true

[{compose.yaml,compose.*.yaml}]
indent_size = 2

[*.md]
trim_trailing_whitespace = false
14 changes: 13 additions & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,17 @@ APP_ENV=prod
APP_SECRET=changeme
APP_DEBUG=0
LOG_LEVEL=info
FRANKENPHP_LOOP_MAX=10000
PRIVATE_KEY_AGENT_CONFIG=/etc/private-key-agent/config.yaml
TRUSTED_PROXIES=

###> symfony/framework-bundle ###
APP_ENV=dev
APP_SECRET=
APP_SHARE_DIR=var/share
###< symfony/framework-bundle ###

###> symfony/routing ###
# Configure how to generate URLs in non-HTTP contexts, such as CLI commands.
# See https://symfony.com/doc/current/routing.html#generating-urls-in-commands
DEFAULT_URI=http://localhost
###< symfony/routing ###
4 changes: 4 additions & 0 deletions .env.dev
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@

###> symfony/framework-bundle ###
APP_SECRET=deb65b4c2d63d3c979e02e98151f1ca3
###< symfony/framework-bundle ###
3 changes: 3 additions & 0 deletions .env.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# define your env variables for the test env here
KERNEL_CLASS='App\Kernel'
APP_SECRET='$ecretf0rt3st'
31 changes: 0 additions & 31 deletions .github/agents/crypto-reviewer.agent.md

This file was deleted.

32 changes: 32 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: CI

on:
push:
branches:
- main
pull_request:

jobs:
lint-and-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
with:
install: true

- name: Build dev image
uses: docker/build-push-action@v6
with:
context: .
file: docker/Dockerfile
target: dev
load: true
tags: openconext-private-key-agent-app:latest
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Run checks
run: docker run --rm openconext-private-key-agent-app:latest composer check
15 changes: 15 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,18 @@
/.phplint.cache
/.phpunit.result.cache
/.php_cs.cache

###> symfony/framework-bundle ###
/.env.local
/.env.local.php
/.env.*.local
/config/secrets/prod/prod.decrypt.private.php
/public/bundles/
/var/
/vendor/
###< symfony/framework-bundle ###

###> phpunit/phpunit ###
/phpunit.xml
/.phpunit.cache/
###< phpunit/phpunit ###
4 changes: 2 additions & 2 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ description: General instructions for the OpenConext Private-key agent workspace

## Architecture

- **Purpose**: A REST API service that strictly executes cryptographic operations (signing, decrypting) using protected private keys (OpenSSL or PKCS#11), without exposing the keys themselves.
- **Purpose**: A REST API service that strictly executes cryptographic operations (signing, decrypting) using protected private keys (OpenSSL), without exposing the keys themselves.
- **Separation of Concerns**: The agent *only* performs private key operations. It does not process or hash the actual message/data (e.g., it expects the client to handle the DigestInfo structure).
- **Authentication**: Clients authenticate using OAuth 2.0 bearer tokens.
- **Authentication**: Clients authenticate using static pre-shared bearer tokens (RFC 6750). Tokens are compared with `hash_equals()` to prevent timing attacks. There is no OAuth 2.0 authorisation server involved.

## Build and Test

Expand Down
Loading
Loading