Giter Club home page Giter Club logo

lara-auth-bridge's Introduction

Allows phpBB (3.0 & 3.1) auth over Laravel 5

For Laravel 4.* see r-a-stone's work Auth driver to create/authenticate accounts.

Latest Stable Version Total Downloads License

Installation

Laravel

run composer
composer require callmenp/lara-auth-bridge
add service provider

Register the Service Provider by adding it to your project's providers array in app.php

'providers' => array(
    'CallMeNP\LaraAuthBridge\LaraAuthBridgeServiceProvider',
);
edit config

Change configs config/lara-auth-bridge.php

// Create a secret app key in 
'appkey' => 'yoursecretapikey'

// Update the column names used for the Laravel Auth driver 
'username_column' => 'user_login',
'password_column' => 'user_password'

// Set true if you use multiAuth, false if default Laravel Auth
'client_auth' => false
exclude URIs from CSRF protection

In file app/Http/Middleware/VerifyCsrfToken.php add

protected $except = [
        	'auth-bridge/*',
    	];

More info how to exclude uris on laravel site

phpBB 3.1

copy files

Copy all files in the phpBB 3.1 directory to your phpBB install

edit config

Edit the file located at {PHPBB-ROOT}/ext/laravel/bridgebb/auth/provider/bridgebb.php

define('LARAVEL_URL', 'http://www.example.com'); //your laravel application's url
define('BRIDGEBB_API_KEY', "yoursecretapikey"); //the same key you created earlier
define ('LARAVEL_CUSTOM_USER_DATA', serialize ([
    'email' => 'user_email',
    'dob' => 'user_birthday',
])); // Update the columns you want to come from Laravel user to phpBB user
setting

Login to the phpBB admin panel enable bridgebb extension and after set bridgebb as the authentication module

lara-auth-bridge's People

Contributors

bukashk0zzz avatar callmenp avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.