Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Parameter Encryption Bundle Laravel Package

picodexter/parameter-encryption-bundle

Encrypts request and URL parameters so sensitive values never travel in plain text. A simple bundle for PHP applications that helps protect IDs, tokens, and other data exposed in links, forms, or query strings.

View on GitHub
Deep Wiki
Context7

Getting Started

v1.2.0 is a maintenance/tooling release, but it changes your runtime floor, so start there before touching any feature code.

  1. Check your runtime first. Support for PHP 5.6 and 7.0 was removed. Confirm php -v reports 7.1+ (the Travis matrix now defaults to 7.3) and that your composer.json require.php constraint is ^7.1 or higher. On Laravel versions still pinned to old PHP, stay on the previous package tag.
  2. Pull the release and clear caches.
    composer update vendor/package
    php artisan config:clear && php artisan cache:clear
    
  3. Look first at src/Configuration.php (or the DependencyInjection/Configuration equivalent). The release fixes a TreeBuilder instantiation deprecation here, which is the one place the upgrade can change behaviour for anyone who subclasses or extends configuration.
  4. Publish any config if you haven't already, then diff the published file against the stub in config/ — a TreeBuilder refactor occasionally shifts a node’s default or path.
    php artisan vendor:publish --provider="Vendor\Package\PackageServiceProvider"
    
  5. First use case: instantiate the package through the container (app(YourClass::class)) and make one representative call in php artisan tinker. Because the codebase now uses strict typing, this is the fastest way to surface any TypeError caused by passing integers as strings (very common when values come from config() or .env).

Implementation Patterns

Resolve from the container, don’t new things up. The package now declares strict_types=1, so constructor arguments must match their declared scalar types. Binding to interfaces in a service provider keeps the type contract in one place:

$this->app->singleton(YourContract::class, fn ($app) => new YourClass(
    (int) config('package.timeout'),      // cast config values explicitly
    (array) config('package.options'),
));

Config-driven workflow. Keep tunables in config/package.php, but cast at the boundary ((int), (bool), (string)) — env() returns strings even for numeric-looking values, and strict typing will no longer coerce them for you.

Test with deprecations visible. The new symfony/phpunit-bridge dependency is the headline developer-facing addition. Use it to fail builds on deprecations that would otherwise be lost:

SYMFONY_DEPRECATIONS_HELPER=1 vendor/bin/phpunit

Set it to weak while you triage, max[direct]=0 once clean. This catches deprecations from the TreeBuilder family before they become hard breaks in a future major.

Upgrade your test base class. The package now requires PHPUnit 6.2+. If your suite still extends PHPUnit_Framework_TestCase, switch to PHPUnit\Framework\TestCase. In setUp()/tearDown() always call parent::setUp() — the newer base class enforces it in more places than before.

Extending configuration? If you override a Configuration class, mirror the fix landed in v1.2.0 and use the node-name-then-getRootNode() form rather than the deprecated positional TreeBuilder constructor:

$treeBuilder = new TreeBuilder('your_root');
$root = $treeBuilder->getRootNode();

Integration tip: register the provider via package discovery where supported; verify with php artisan about (Laravel 9+) or by dumping app()->getLoadedProviders().

Gotchas and Tips

  • Dropped PHP 5.6/7.0 is the breaking change. Composer will hard-fail resolution on those runtimes. Audit CI images (Docker, Travis, GitHub Actions) as well as local dev boxes — Travis users should note the bundled config moved off EOL versions and off HHVM entirely.
  • Strict typing is a behavioural break, not just a style change. Calls that previously worked via juggling — $service->setLimit("10"), method(true) where an int was expected, null into a non-nullable scalar — now throw TypeError. Grep your call sites for values coming from config(), env(), request input, and database columns (all strings).
  • Native constant/function invocation (CS Fixer) can surprise you in edge cases. Calls like \strlen() and \PHP_EOL are now fully qualified. If your tests mock or namespace-shadow global functions, re-run the suite rather than assuming parity.
  • TreeBuilder deprecation fix: if you see Passing a tree builder name as first argument warnings, you're on an old subclass pattern — adopt new TreeBuilder('name') + getRootNode(). The deprecation was silenced internally in this release, so third-party extensions are the usual remaining source.
  • error_reporting(-1) is set for the package's own tests, not yours. Don't infer that your app is configured that way; enable it deliberately in phpunit.xml if you want deprecations surfaced locally.
  • Debugging TypeError from strict typing: stack traces will point at the package method, not your caller. Work backwards to the argument source and cast it at the boundary rather than loosening the package.
  • Extension points remain the service provider and configuration tree. There is no new public API in v1.2.0 — if you were relying on untyped coercion or a specific TreeBuilder call signature, treat that as the migration surface.
  • Pin versions in CI: with the old PHPs dropped and PHPUnit bumped, a floating ^1.1 can silently jump you into the new requirements. Lock the constraint and bump deliberately.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
tequilarapido/trackit
gregsphotography/site-builder-filament
cabaoctavio/laravel-query-log
gregsphotography/site-builder-components
io-digital/clickatell
snowsoft/laravel-admin
oxygen/auth
relicsoftware/barakah-payment-gateway
tobya/work-with-composer
equipc/laravel-email-validator
equipc/laravel-email-database-log
adedsec/nova-translated-labels
wazza/laravel-db-encryption
hokny/laravel-generator
vonsogt/backup
jengo/queues
jeremykenedy/laravel-observability
coleus/frame
thtg88/journalism
filagora/filagora-ai-forums