Download the PHP package psalm/plugin-laravel without Composer

On this page you can find all versions of the php package psalm/plugin-laravel. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package plugin-laravel

Laravel Psalm Plugin

Laravel static analysis with built-in security scanning.

Psalm Laravel Example

Packagist version Packagist downloads Type coverage Tests

The only free tool that combines deep Laravel type analysis with taint-based vulnerability detection. Catches SQL injection, XSS, SSRF, shell injection, file traversal, and open redirects, without running your code.

[!NOTE] Already using Larastan? psalm-laravel complements it with security analysis that PHPStan cannot provide.

Security scanning

Plugin ships Laravel-specific taint stubs that track user input from source to sink across your entire codebase. Unlike pattern-matching tools, Psalm follows dataflow across function boundaries, catching vulnerabilities that simpler scanners miss.

Taint analysis also works across helper functions, service classes, and any number of call layers.

You can read more about how the plugin's taint analysis works and what vulnerabilities it detects in docs/security.md.

Quickstart

Step 1: Install

Since Psalm 7.x is currently in beta, allow dev (or beta) packages first:

Step 2: Generate a Laravel-tailored psalm.xml

This writes a psalm.xml at the project root with the plugin already enabled, sensible errorLevel, and Laravel-friendly issue handler defaults. Pass --level 1 (strictest) through --level 8 (most lenient) to pick a starting strictness. Pass --force to overwrite an existing psalm.xml without prompting.

Step 3: Run

analyze delegates to vendor/bin/psalm and passes the exit code through, so you can also invoke ./vendor/bin/psalm directly. Security taint analysis runs automatically, no extra flags needed.

Existing projects: the first run will likely report many issues. Create a baseline to suppress them and focus only on new code:

From here, gradually increase errorLevel (start at 4, work toward 1) and shrink the baseline over time.

Optional: wire up CI in one command

Writes a ready-to-commit .github/workflows/psalm.yml that runs the plugin on every push and pull request. See docs/github-actions.md for what the generated workflow does and how to customize it.

Configuration

You can customize Psalm configuration using XML config and/or cli parameters.

See docs/config.md for all configuration options.

Custom checks

The plugin ships advanced Laravel-aware static analysis checks that extend Psalm's built-in diagnostics. See docs/issues/index.md for the full catalog.

Versions & Dependencies

Maintained versions:

Laravel Psalm Plugin PHP Laravel Psalm Plugin Status
4.x ^8.2 12, 13 7-beta Stable
3.x (upgrade to v4) ^8.2 11, 12, 13 6 Stable
2.12+ ^8.0 9, 10, 11 5, 6 Legacy

(Older versions of Laravel, PHP, and Psalm were supported by version 1.x of the plugin, but they are no longer maintained)

See releases for more details about supported PHP, Laravel and Psalm versions.

How it works

Under the hood it reads Laravel's native @method annotations on facade classes and generates alias stubs based on Illuminate\Foundation\AliasLoader (including aliases from your config/app.php and package discovery). It also ships hand-crafted stubs for taint analysis and special cases.

It also parses SQL schema dumps (php artisan schema:dump) and PHP migration files to infer column names and types in your database models.

Psalm-Laravel or Larastan?

Use both. They solve different problems:

Psalm and PHPStan use almost the same annotation syntax, so they work side by side without conflicts.

Larastan checks your types. We check your security. Use both.

Contributing

Maintained by @alies-dev. There are contributing docs that may help you (and your agents) with contributions.

Areas where help is especially needed:


All versions of plugin-laravel with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
ext-simplexml Version *
illuminate/config Version ^12.0 || ^13.0
illuminate/container Version ^12.0 || ^13.0
illuminate/contracts Version ^12.0 || ^13.0
illuminate/database Version ^12.0 || ^13.0
illuminate/events Version ^12.0 || ^13.0
illuminate/http Version ^12.0 || ^13.0
illuminate/routing Version ^12.0 || ^13.0
illuminate/support Version ^12.0 || ^13.0
illuminate/view Version ^12.0 || ^13.0
nikic/php-parser Version ^5.0
orchestra/testbench-core Version ^10.0 || ^11.0
psalm/psalm-plugin-api Version ^0.1.0
symfony/console Version ^7.2 || ^8.0
vimeo/psalm Version ^7.0.0-beta19 || dev-master
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package psalm/plugin-laravel contains the following files

Loading the files please wait ...