cosmonova-rnd/jwt-guard

Guard JWT Authenticator for Symfony

1.1.0 2018-05-17 06:56 UTC

This package is not auto-updated.

Last update: 2024-05-26 03:27:46 UTC


README

Installing

  • Install package using composer

composer require cosmonova-rnd/jwt-guard

Configuring

  • Configure environment variables JWT_PUBLIC_KEY and JWT_PASSPHRASE with public key and passphrase

  • Add to your firewall new authenticator

example:

security:
    main:
        anonymous: ~
        guard:
            authenticators:
                - CosmonovaRnD\JWTGuard\Security\JwtAuthenticator

Usage

Use symfony UserInterface to get authenticated user

@ Cosmonova | Research & Development