Download the PHP package lameck/manuser without Composer

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

PL5-Manuser-JWT

Packager Manager User com JWT

Packagers são interessantes para otimização de trabalho com programação. Eventos que são comuns a cada projeto poderão ser reaproveitados. Para evitar programar sempre a mesma rotina, os packagers ajudam a acelerar esse processo mantendo você ocupado com o que é realmente necessário. Em resumo, trata-se de otimização das rotinas.

Este packager tem o objetivo de otimizar o roteamento, controllers e middleware para credenciamento utilizando RestFull com JWT.


Assinatura: Packagerlist


INSTALAÇÃO

  • 1. composer require lameck/manuser
  • 2. php artisan vendor:publish --provider="Lameck\Manuser\ManuserServiceProvider"

  • PROVIDER: app/config/app.php
    ...
      Lameck\Manuser\ManuserServiceProvider::class,
        Tymon\JWTAuth\Providers\LaravelServiceProvider::class
    

    ALIAS: app/config/app.php
      'JWTAuth'   => Tymon\JWTAuthFacades\JWTAuth::class,
        'JWTFactory' => Tymon\JWTAuthFacades\JWTFactory::class
    

    KERNEL: app/http/kernel.php

    Comente a linha:

    //\App\Http\Middleware\VerifyCsrfToken::class,

    Adicione em routemiddlware:

    'jwt.auth' => Tymon\JWTAuth\MiddlewareGetUserFromToken::class,
    'jwt.refresh' => TymonJWTAuth\MiddlewareRefreshToken::class

    Comente:

    //'throttle' => \Illuminate\Routing\Middleware\ThrottleRequests::class,

    Adicione:

    'throttle' => \Lameck\Manuser\ThrottleRequestsMiddleware::class,

    MODEL USER

    Adicione em na classe:

    use Tymon\JWTAuth\Contracts\JWTSubject;
    class User extends Authenticatable implements JWTSubject{...}
    public function getJWTCustomClaims(): array {
            return [];
        }
    public function getJWTIdentifier(){
            return $this->getKey();
        }
    
    


    Pare o servidor, se estiver rodando e limpe o cache. Após, reinicie:
    php artisan cache:clear;php artisan serve


    Se não fizer isso é possivel que a mensagem de erro seja: "Acesso negado"
    ### EXEMPLO Crie um banco de dados e carregue um seeder:
    php artisan migrate
    php artisan make:seeder UsersTableSeeder
    DB::table('users')->delete();
      $users = array(
              ['name' => 'Jerry Cantrell', 'email' => '[email protected]', 'password' => Hash::make('secret')],
              ['name' => 'Ozzy Osbuorne', 'email' => '[email protected]', 'password' => Hash::make('secret')],
              ['name' => 'Leney Stanley', 'email' => '[email protected]', 'password' => Hash::make('secret')],
              ['name' => 'Kurtney Love', 'email' => '[email protected]', 'password' => Hash::make('secret')],
      );
      DB::table('users')->insert($users);
    
    php artisan db:seed
    php artisan jwt:secret Utilize o postman para testar a api.

    POST

    localhost:8000/manuser/[email protected]&password=secret

    GET

    localhost:8000/manuser/users?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwOlwvXC9sb2NhbGhvc3Q6ODAwMFwvbWFudXNlclwvYXV0aGVudGljYXRlIiwiaWF0IjoxNTIyMDIwNTc5LCJleHAiOjE1MjIwMjQxNzksIm5iZiI6MTUyMjAyMDU3OSwianRpIjoidzA0YnRpejU3Q1NZRjRuZyIsInN1YiI6MSwicHJ2IjoiODdlMGFmMWVmOWZkMTU4MTJmZGVjOTcxNTNhMTRlMGIwNDc1NDZhYSJ9.xMWZb27t-VgyE5BbR0N5l1Iyf4Y4n5QBF-IuBA_CJgQ


    Em resumo, o packager trata-se de uma automação de uso com API RestFull utilizando JWT - não utilizamos mais o token nativo VerifyCsrfToken - principalmente para cross-site-script, em seu lugar estamos usando JWT. Para utilizarmo-lo, faz-se necessário a configuração manual - comum para quem já é veterano com o framework laravel.

    Estarei disponibilizando mais detalhes na wiki


    ### Detalhe

    O numero de requisições por default esta 1,1 (1 requisição por minuto - throttle:1,1). Para auterar este valor, basta acessar as dependencias vendor/lameck/manuser/route.php. O primeiro valor é o numero de requisiçes e o segundo é o tempo decorrido até a próxima requisição.

    Route::group(['prefix' => 'manuser'], function()
    {
        Route::post('authenticate', '\Lameck\Manuser\ManuserController@authenticate');
        Route::middleware('jwt.auth','throttle:1,1')->get('users','\Lameck\Manuser\ManuserController@users');
    });
    

    All versions of manuser with dependencies

    PHP Build Version
    Package Version
    Requires tymon/jwt-auth Version dev-develop
    php Version ^5.5.9 || ^7.0
    illuminate/auth Version 5.1.* || 5.2.* || 5.3.* || 5.4.* || 5.5.* || 5.6.*
    illuminate/contracts Version 5.1.* || 5.2.* || 5.3.* || 5.4.* || 5.5.* || 5.6.*
    illuminate/http Version 5.1.* || 5.2.* || 5.3.* || 5.4.* || 5.5.* || 5.6.*
    illuminate/support Version 5.1.* || 5.2.* || 5.3.* || 5.4.* || 5.5.* || 5.6.*
    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 lameck/manuser contains the following files

    Loading the files please wait ....