Weave Code
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

Spdx Licenses Laravel Package

composer/spdx-licenses

PHP library providing the official SPDX license and exception lists plus validation for SPDX license expressions. Look up licenses by identifier or name, check OSI approval or deprecation status, and validate license strings for Composer and tooling.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Compliance Automation: Integrate license validation into CI/CD pipelines (e.g., GitHub Actions, GitLab CI) to block non-compliant dependencies during build. Example: Fail PRs if composer.json contains deprecated or non-OSI licenses.
  • Dependency Governance: Standardize license checks across all Laravel/PHP projects to eliminate ad-hoc validation and reduce technical debt. Aligns with shift-left security by enforcing compliance at dependency resolution.
  • Open-Source Governance: Enable automated SPDX reporting for distributed software (e.g., Laravel packages, SaaS APIs). Supports supply chain transparency (e.g., SPDX-RDF generation for compliance with EU regulations like DORA).
  • Tooling Roadmap:
    • Composer Plugin: Extend composer validate with a --check-licenses flag to enforce SPDX compliance during dependency installation.
    • Audit CLI: Build a spdx-audit command-line tool to scan projects for deprecated/non-OSI licenses (e.g., ./vendor/bin/spdx-audit --fail-on=deprecated).
    • Laravel Integration: Create a SpdxServiceProvider to validate licenses in config/app.php or middleware (e.g., block requests from non-compliant dependencies).
  • Vendor Risk Mitigation: Prevent "license bombs" by validating third-party dependencies (e.g., reject GPLv3 in proprietary modules). Critical for SaaS platforms hosting multi-tenant Laravel applications.
  • Build vs. Buy: Replace custom license parsers (e.g., regex-based solutions) with a maintained, SPDX-aligned library (used by Composer) to reduce maintenance overhead and ensure accuracy.
  • Regulatory Alignment: Meet compliance requirements for government contracts, open-source contributions, or supply chain transparency (e.g., SPDX 3.0+ support for SBOMs).
  • Laravel Ecosystem Expansion: Enable package validation for Laravel Forge, Envoyer, or Vapor deployments by embedding license checks in deployment workflows.
  • Developer Experience: Add license validation hints to Laravel IDE Helpers (e.g., PhpStorm) to warn developers about deprecated or non-compliant licenses during coding.

When to Consider This Package

Adopt if:

  • Your PHP/Laravel project uses Composer for dependency management (primary use case).
  • You need to validate SPDX license identifiers in:
    • composer.json files (e.g., license field).
    • Package metadata (e.g., Packagist submissions).
    • CI/CD pipelines (e.g., GitHub Actions, GitLab CI).
  • Your team requires OSI approval checks or deprecation warnings (e.g., for open-source distributions or proprietary software).
  • You’re building compliance tools, audit scripts, or license governance features (e.g., a "License Compliance Dashboard").
  • You want to avoid maintaining a custom SPDX license list (this package auto-updates with SPDX releases).
  • Your project must comply with SPDX standards (e.g., for government contracts, open-source contributions, or supply chain transparency).
  • You need lightweight, zero-maintenance license validation with battle-tested code (used by Composer).
  • You’re developing Laravel packages distributed via Packagist or private repositories and need to enforce license consistency.
  • Your organization requires automated SPDX reporting for audits or regulatory filings (e.g., DORA, NIST SP 800-218).

Look elsewhere if:

  • You’re not using PHP/Composer/Laravel (this package is PHP-specific).
  • You need advanced legal analysis (e.g., interpreting license terms beyond SPDX identifiers).
  • Your use case requires non-SPDX license formats (e.g., Apache 2.0 in a custom format).
  • You’re building a non-PHP ecosystem (e.g., Node.js, Python, or Java) where SPDX validation is handled by other tools.
  • You need real-time license compliance monitoring (consider integrating with tools like FOSSA, Snyk, or Black Duck).
  • Your project has legacy systems that use hardcoded license lists (refactoring may be required for integration).
  • You require custom license templates beyond SPDX (e.g., internal corporate licenses).

How to Pitch It (Stakeholders)

For Executives: "This package lets us automate license compliance in our PHP/Laravel stack—just like Composer does internally. By integrating it into our CI/CD pipelines, we can block non-compliant dependencies before they reach production, reducing legal and security risks. It’s lightweight, maintained by the Composer team, and aligns with open-source governance and regulatory requirements (e.g., SPDX for supply chain transparency). Think of it as a ‘license firewall’ for our dependencies—no more surprises from GPLv3 or deprecated licenses."

For Engineering/DevOps: *"We can use this to:

  1. Fail builds if composer.json has invalid/non-OSI licenses (e.g., via GitHub Actions).
  2. Audit dependencies in CI with a custom spdx-audit CLI tool.
  3. Enforce compliance in Laravel deployments (e.g., block proprietary modules with GPL dependencies).
  4. Replace manual checks with automated validation—saves time and reduces human error. It’s zero-maintenance (updates with SPDX) and battle-tested (used by Composer). Let’s prototype a Composer plugin or Laravel service provider to integrate it."*

For Legal/Compliance: *"This gives us real-time visibility into license risks across our PHP dependencies. We can:

  • Flag deprecated licenses (e.g., MIT → MIT-0) before they cause issues.
  • Enforce OSI approval for open-source projects.
  • Generate SPDX reports for audits or regulatory filings (e.g., EU DORA). It’s a proactive way to manage license compliance—no more last-minute scrambles to fix license violations in production."*
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.
nexmo/api-specification
capell-app/block-library
axium/identity
cetria/laravel-dummy-models
cetria/reflection-helper
agropredict/sso-auth-bundle
evolvestudio/spam-protection
datacore/hub-sdk
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony
develia/geo-bundle
dreamzy/livewire-charts
touchestate-sdk/php-sdk
22h/doctrine-garbage-collection-bundle
agtp/agtp-php
agtp/mod-php
splash/sonata-admin
splash/metadata
splash/openapi