aaugustyniak/params-codec-bundle
Symfony 2/3 bundle that AES-encrypts route parameters. Adds a param_codec service and Twig helpers to generate encrypted URLs, plus a @DecryptParams annotation to automatically decrypt controller arguments using a secret passphrase.
AppKernel.php → config/bundles.php) would be required.ParamCodec interface and AesCodec implementation provide a clear separation between encryption logic and routing, enabling future swaps (e.g., for performance or compliance reasons).parameters.yml config) with no major refactoring. Existing Twig path()/url() calls remain unchanged; the bundle intercepts and encrypts params transparently.@DecryptParams annotation simplifies controller-level opt-in/opt-out for decryption, reducing boilerplate.encodeParam()/decodeParam() filters for manual use cases (e.g., encrypting dynamic values in templates).openssl_encrypt/openssl_decrypt. Risks include:
AesCodec class for secure defaults. Consider wrapping with a custom codec if compliance (e.g., FIPS) is required.RouteCollection vs. Route objects).path() helper signature).parameters.yml (plaintext in var/ if not excluded from Git). Risk of exposure in deployment artifacts.%env% or Vault integration for secrets management./user/{id}) contain sensitive data.ParamCodec logic to a standalone library or integrating via a micro-framework adapter (e.g., Slim, Lumen).spatie/laravel-honeypot (for CSRF) or custom middleware for URL encryption./profile/{user_id}, /reset/{token}).@DecryptParams or Twig filters.composer.json (prefer stable tag over dev-master).parameters.yml with a strong passphrase (32+ chars, random).config/bundles.php (Symfony 4+) or AppKernel.php.encodeParam().assertEquals($rawValue, $decryptedParam)).AppKernel with config/bundles.php.RouteCollection; ensure ParamCodec handles new route object structures.path()/url() helpers for signature changes.symfony/twig-bundle).php -m | grep openssl).parameters.yml before modifying.@DecryptParams to critical controllers (test decryption).encodeParam().bundles.php if issues arise.parameters.yml in staging.aaugustyniak/params-codec-bundle to a specific version in composer.json to avoid dev-master instability.AesCodec exceptions to identify corrupt/missing keys.Symfony\Component\HttpFoundation\Cache).How can I help you explore Laravel packages today?