liberusoftware/ecommerce-laravel
Liberu eCommerce for Laravel is a modular package for building online stores with product catalogs, shopping carts, checkout, order management, and payment workflows. Configurable, extensible, and Laravel-native, it gives developers a practical foundation for custom storefronts and ecommerce applica...
Architecture fit. This is a Laravel e-commerce starter/monolith built on the standard stack: Fortify for authentication, Filament for the admin and app panels, Spatie Permission (via Shield) for authorization, and Socialstream for social login. v1.0.3 does not change the architecture, but it corrects the authorization model that the architecture depends on. The two panels now answer distinct questions — admin → super_admin, app → team membership — which is the correct shape for a multi-tenant merchant storefront. That said, the intended model (roles scoped per team) is not actually active: config('permission.teams') is false, so roles are global. Code that reads as team-scoped is currently decorative. Any integration design that assumes per-tenant role isolation is building on sand.
Integration feasibility. The release is a bug fix, not a feature release, and is straightforward to adopt on a Laravel codebase already aligned to the v1 line. The blocker is not code, it is version resolution. The release notes explicitly state that the tag immediately preceding v1.0.0 was v13.0.0 (which tracked the Laravel major), and Packagist still resolves that as highest. composer create-project and any unconstrained composer require will therefore pull v13.0.0 — a different, older-than-v1.0.0 codebase — while the v1 tag now points at 1.0.3. This is a non-monotonic version history. It must be pinned explicitly (1.0.3 or a ^1.0 constraint with a floor), and the pin must be verified in a clean environment, not inherited from a working local composer.lock.
Technical risk. Several items move from "latent" to "live" depending on configuration, which makes the risk profile environment-dependent rather than version-dependent:
| Risk | State in v1.0.3 | Trigger to becoming exploitable |
|---|---|---|
canAccessPanel authorization bypass |
Fixed | — |
Registration → merchant team + staff role escalation |
Fixed | — |
ArticleResource / CollectionResource missing policies (strictAuthorization off) |
Latent | Any user who obtains team membership; tenant member can CRUD articles/collections incl. price with no permission check |
| SVG stored XSS via product upload to public disk | Latent | Running php artisan storage:link |
/user/profile null connectedAccounts → ->map() on null |
Latent | Enabling social login (HasConnectedAccounts is commented out in User) |
Weak password policy (Password::default(), min 8, no complexity, no breach check) |
Live | — |
Demo storefront ships sold-out (inventory_count = 0) |
Live | — |
RoleBasedRedirect dead code, 6 targets 404; global roles despite team-scoped reading |
Live (cosmetic/confusing) | — |
The authorization fix deserves specific credit: the two bugs were coupled, and fixing registration alone would have opened the door, because a newly created zero-role/zero-team user would still have passed return true; // TODO. Whoever sequenced that fix understood the dependency. Note also the subtle correction from auth()->user() to $this in canAccessPanel — the previous code authorized the session user rather than the user being checked, which is a class of bug that tends to reappear elsewhere.
Key questions.
composer create-project + composer install (no lockfile) to confirm v13.0.0 is not resolved?storage:link part of the deploy runbook? If yes, the SVG XSS is live on day one and needs an allowlist on the upload MIME types before go-live./user/profile is broken and requires re-enabling HasConnectedAccounts in User — an application-level patch, not something the package will fix.ArticleResource / CollectionResource in scope for our tenant users? If yes, we must author policies and seed the corresponding article_* / collection_* permissions ourselves, since the Shield permission set contains none.permission.teams = false must be corrected — a materially larger piece of work.FortifyActionsTest::makeTeam() helper created both the team and the staff role, so the test asserted against a fixture that real registration could never produce. What other tests share fixtures that diverge from production paths?Stack fit. Standard Laravel + Filament + Fortify + Spatie/Shield. Nothing exotic, no new runtime dependencies introduced by this release. It slots into a conventional Laravel deployment (PHP-FPM, queue worker, MySQL/Postgres, S3-or-local storage). The main stack-level caveat is that this package is a full application, not a library: adopting it means adopting its panels, its seeders, and its opinionated auth flow, and then patching around the gaps listed above. Budget for the "patch around the gaps" portion — it is the dominant cost, not the install.
Migration path. For a greenfield deployment: pin 1.0.3 explicitly in composer.json before the first create-project, then run the seeders and verify that a fresh registration produces a user with no team and no role, and that /app rejects that user. That single end-to-end check is the acceptance test for this release. For an existing v1.0.2 installation: this is a patch-level upgrade with no schema or API changes called out, so a standard composer update with the constraint bumped is sufficient — but re-run the registration/panel-access check, because any local workaround for the old registration failure (e.g. seeding a staff role, pre-creating a default team) will now conflict with the corrected behaviour and must be removed.
Compatibility. PHP and Laravel version requirements are unchanged within the v1 line. The compatibility hazard is entirely the version-number collision with v13.0.0 — a consumer that treats the major number as meaningful will conclude v13.0.0 supersedes v1.0.3, which is exactly backwards. Any dependency tooling, SBOM generation, or vulnerability scanner that ranks by semver will report the wrong version as current. Flag this to whoever owns dependency hygiene.
Sequencing.
/app denied, storefront allowed.intended() behaviour: interrupt a shopper mid-checkout and confirm return to the storefront rather than a panel redirect loop.storage:link. If it is required, restrict product image uploads to a non-SVG allowlist before enabling it.article_* / collection_* permissions in the same change, and enable strictAuthorization. Doing one without the other locks out or leaves open, depending on order.HasConnectedAccounts and test /user/profile before announcing the feature.Password::default() and seed non-zero inventory_count before any demo or UAT environment is shown to stakeholders.Maintenance. The release removes a test helper that was masking a production-breaking bug, which is the right call but reduces coverage of the real registration path until equivalent tests are written against production-shaped fixtures. Expect to own that gap: add a test that registers through the actual Fortify action with an unseeded database and asserts no team and no role are assigned. More broadly, this package requires ongoing in-house patching — the missing policies, the commented-out trait, the dead RoleBasedRedirect, and the permission.teams = false mismatch are all things upstream has documented but not fixed. Plan for a maintained fork or a patch layer rather than passive dependency updates.
Support. Upstream responsiveness looks reasonable — the notes are unusually candid, and the release includes a live end-to-end verification. But the known-issues list is essentially a backlog handoff, and items like "needs policies and seeded permissions together" are invitations for the integrator to do the work. Escalation paths for authorization defects should go to your own security owner, not upstream, given the severity of what was just found.
Scaling. No scaling-relevant changes. The authorization checks added are per-request role/team lookups on a user object and are cacheable in the ordinary Spatie way. The larger scaling consideration is tenancy correctness: with global roles, a user who is a team member in one store is a member everywhere the role check passes, so any growth in tenant count increases the blast radius of the missing resource policies.
Failure modes. Watch for these specifically:
strictAuthorization is enabled or policies are added without seeding the matching permissions, tenant users lose access to articles and collections with a generic 403.storage:link turns the SVG upload into a stored XSS vector with no code change and no deploy to correlate against./user/profile on a null connectedAccounts, again with no change to this package.staff role grants) now re-introduces the exact privilege escalation this release closed.Ramp-up. Low for a Laravel-fluent engineer: the stack is conventional and the diff is small and well explained. The ramp-up cost is not in understanding the change, it is in understanding the surrounding system well enough to know which of the latent issues are live for your configuration — specifically whether you run storage:link, whether social login is on, whether tenant users touch articles/collections, and whether anyone believes roles are team-scoped. Budget roughly a day for the upgrade and verification, and a separate, larger estimate for the policy and permission work if articles/collections are in scope. Brief the team explicitly on the version-numbering trap; it is the single most likely way this integration fails quietly.
How can I help you explore Laravel packages today?