Download the PHP package cwilsn/laravel-aws-sso without Composer

On this page you can find all versions of the php package cwilsn/laravel-aws-sso. 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 laravel-aws-sso

Laravel AWS SSO

Start Laravel with a usable AWS IAM Identity Center session—and keep it usable without restarting your development stack.

Laravel AWS SSO makes authentication part of your normal php artisan dev workflow. You do not need to remember to run aws sso login first or restart every development process when your session expires.

What using it looks like

Run Laravel as usual:

The package handles the rest:

  1. Before Laravel starts, it checks whether the configured AWS profile can authenticate.
  2. If the session is missing or expired, it runs aws sso login and opens the Identity Center sign-in page in your browser. Laravel continues starting after you sign in.
  3. While you work, the aws-sso tab checks the session every 60 seconds without interrupting you or opening a browser.
  4. If the session expires later, select the aws-sso tab and press r. The watcher restarts, opens the sign-in page, and resumes monitoring after you authenticate. Your queues, logs, Vite server, and other development processes keep running.

Select the aws-sso tab and press r whenever an expired session needs to be refreshed.

Use a dedicated, least-privileged permission set for local development. Your application receives every permission granted to the selected profile.

Requirements

Dependency Version
PHP ^8.3
Laravel ^13.18
AWS CLI v2 with IAM Identity Center support

The package does not require aws/aws-sdk-php. Your application can continue using its existing AWS SDK dependencies.

Installation

1. Configure an Identity Center profile

Choose the least-privileged permission set your local application needs. See the AWS CLI IAM Identity Center guide for profile setup details.

2. Install the package

The service provider is auto-discovered. Install this package as a dev dependency; it is not intended for deployed applications.

3. Configure your environment

Remove static credentials from .env:

Set the profile you configured:

Then start Laravel normally:

The first run may open the Identity Center login page. Later runs start immediately while the session remains usable.

Configuration

The defaults work without publishing anything. To customise them:

Option Default Purpose
enabled true Enable automatic authentication checks.
profile AWS_PROFILE or default AWS CLI profile to verify.
commands ['dev'] Artisan commands checked before startup.
environments ['local'] Laravel environments where automatic checks run.
monitor true Add the aws-sso companion process to php artisan dev.
monitor_interval 60 Seconds between background checks.
fail_on_static_credentials true Fail when environment access keys would override the profile.
show_identity_after_login true Print the profile ARN after automatic login.
expected_account_id null Require an exact AWS account ID.
expected_role null Require an exact permission-set or role name.

Automatic checks run only for configured commands and environments. The manual commands remain available wherever the package is installed.

Laravel configuration caching freezes the selected profile. After changing AWS_PROFILE, run:

Identity guardrails

Pin the account and permission set your application is allowed to use:

Guardrails reduce wrong-account and wrong-role mistakes, but they do not replace least-privileged IAM permissions.

Commands

Login

Authenticate on demand. This does nothing when the profile is already usable.

Status

Inspect the CLI, profile, environment credentials, and current identity without opening a browser. The command exits non-zero when authentication is invalid.

Session monitoring details

The aws-sso process checks the profile every 60 seconds by default. Background checks never open a browser; an interactive login only happens before php artisan dev starts or when you restart the selected aws-sso tab with r.

If your terminal does not provide tab controls, sign in from another terminal:

The watcher resumes once the profile becomes usable. It does not stop Laravel's other development processes.

Security notes

See SECURITY.md for the full security model and vulnerability reporting instructions.

Troubleshooting

AWS CLI not found

Install AWS CLI v2, then configure your profile with aws configure sso.

Profile not found

Laravel uses old credentials or the wrong profile

Remove AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY from .env, your shell profile, and your editor environment. Check for AWS clients constructed with explicit credentials, then clear cached Laravel configuration:

Wrong account or role

Inspect the profile directly, correct its permission-set assignment, and consider enabling both identity guardrails:

Sign out

Development

The test suite never contacts AWS or reads your ~/.aws directory.

See LICENSE.md.


All versions of laravel-aws-sso with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
illuminate/console Version ^13.18
illuminate/contracts Version ^13.18
illuminate/process Version ^13.18
illuminate/support Version ^13.18
symfony/console Version ^7.4 || ^8.0
symfony/process Version ^7.4.5 || ^8.0.5
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 cwilsn/laravel-aws-sso contains the following files

Loading the files please wait ...