Download the PHP package ghostcompiler/laravel-auth without Composer

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

Laravel Auth

Laravel Auth

Premium, headless Laravel authentication hardening library for TOTP 2FA, passkeys, recovery codes, multi-channel OTP, trusted devices, and social authentication.

Laravel PHP Version Security Hardened Ghost Compiler


Headless Laravel authentication hardening with:

This package does not replace your login system. It adds security layers on top of your existing auth flow.

Requirements

Installation

Force republishing if you want to overwrite previously published files:

What ghost:laravel-auth publishes:

Publish only OTP assets later if needed:

Local Package Development

To test this package from another Laravel app through a local path repository:

Then in the app:

If the app does not pick up local changes automatically:

What The Package Adds

Middleware aliases:

Published config:

Main facade contract:

Single package migration:

Database objects created:

Current Defaults

From the package config:

Recommended Base Route Protection

Add throttling to sensitive verification endpoints:

TOTP 2FA Setup

Enable 2FA for a user:

Confirm setup:

Disable 2FA:

Demo 2FA Controller

Verifying 2FA During Login

TOTP or recovery code:

You can also verify without fully marking the session:

Recovery Codes

Generate or regenerate recovery codes:

Recovery codes are consumed automatically when passed through verifyOTP() or attemptOtp().

Passkeys / WebAuthn

Begin passkey registration:

Finish registration:

Begin assertion:

Verify assertion only:

Attempt assertion and fully authenticate:

OTP Channels

Email OTP

Send:

Verify only:

Attempt and mark session:

SMS OTP

Send:

Verify:

Attempt:

WhatsApp OTP

Enable it first in config/laravel-auth.php or your published config.

Send:

Verify:

Attempt:

Demo OTP Controller

Trusted Devices

Trusted devices are created automatically when you use:

Relevant config keys:

Social Login

LaravelAuth supports two social-login modes:

  1. static/global provider config
  2. runtime provider config for tenant-specific OAuth credentials

Backward compatibility is preserved. Existing static Socialite-based setups continue to work.

Static Social Login Setup

Enable providers in your published config/laravel-auth.php.

Example:

Discover configured providers:

Redirect:

Callback:

Link:

Find local user:

List linked accounts:

Unlink:

Demo Static Social Controller

Runtime Tenant Social Login

Use runtime config when each tenant stores its own OAuth credentials.

Supported runtime keys:

Tenant provider discovery:

Named-parameter redirect:

Positional redirect:

Named-parameter callback resolution:

Positional callback resolution:

Demo Tenant Social Controller

Suggested routes:

Suggested tenant credential table in your app:

Important Tenant Limitation

Runtime tenant credentials are supported, but linked social identities are still globally unique by:

That means the same Google or GitHub identity cannot currently be linked separately in multiple tenants through the package table.

Current package fit:

Not yet built into the package:

Session State Helpers

Enforce manually if needed:

Rate Limiting Helpers

Buckets used by the package:

Strict Preset

Apply the built-in strict preset:

This tightens:

OTP Provider Configuration

Mail

Enabled by default.

Relevant config:

SMS providers

Supported built-ins:

Set the provider in config:

WhatsApp providers

Supported built-ins:

WhatsApp is disabled by default. Enable it in your published config before use.

Custom transports

Publish stubs:

Then wire your own classes in the published config:

Troubleshooting

2FA required unexpectedly

Passkey challenge invalid or expired

Social provider missing

Runtime config named parameter error in IDE

If your app or IDE says Unknown named parameter $runtimeConfig, refresh the package in the app:

Or use positional arguments:

OTP verification keeps failing

Testing & Quality Control

To run the automated test suite and ensure all quality gates pass, use the following commands:

Public API Reference

2FA / TOTP / Recovery

Passkeys

OTP Channels

Social Helpers

State / Enforcement / Utility


License

The MIT License (MIT). Please see License File for more information.


All versions of laravel-auth with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2 || ^8.3 || ^8.4 || ^8.5
illuminate/http Version ^10.0 || ^11.0 || ^12.0 || ^13.0
illuminate/mail Version ^10.0 || ^11.0 || ^12.0 || ^13.0
illuminate/support Version ^10.0 || ^11.0 || ^12.0 || ^13.0
illuminate/view Version ^10.0 || ^11.0 || ^12.0 || ^13.0
laravel/socialite Version ^5.0
lbuchs/webauthn Version ^2.2
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 ghostcompiler/laravel-auth contains the following files

Loading the files please wait ...