GithubHelp home page GithubHelp logo

cesnet / simplesamlphp-authgoogleoauth2 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from rgeyer/simplesamlphp-authgoogleoauth2

0.0 4.0 1.0 9 KB

An authentication module for simplesamlphp which authenticates against Google OAuth2

License: MIT License

PHP 100.00%

simplesamlphp-authgoogleoauth2's Introduction

simplesamlphp-authgoogleoauth2

This repository is forked from rgeyer

An authentication module for simplesamlphp which authenticates against Google OAuth2

I created this largely because of Google's OpenID 2.0 deprecation. I used OpenID for authentication to RightScale, among other things.

Installation

Git clone this repo into your modules/ directory, then be sure to install the dependencies with composer

cd /path/to/simplesaml/modules/
git clone https://github.com/rgeyer/simplesamlphp-authgoogleoauth2.git authgoogleoauth2 
cd authgoogleoauth2
# Install composer, skip this step if you've already got it
curl -s https://getcomposer.org/installer | php
# Install the authgoogleoauth2 module dependencies, you can just do `composer install` if you've already
# installed composer globally
php composer.phar install

Configuration

You'll first need to go to the Google developer console and create an application which your users will be asked to "trust" when they use this authentication mechanism. This is the same as the typical OAuth process when you enable an application to access your google account information. In this case, the only thing this application accesses about your account are your user details.

https://console.developers.google.com/project

Then, a simple entry in your simplesamlphp config is all you need.

config/authsources.php

  'authgoogleoauth2' => array(
      'authgoogleoauth2:authgoogleoauth2',
      'client_id' => 'yourclientid.apps.googleusercontent.com',
      'client_secret' => 'Your Secret',
      'developer_key' => 'Your API Key',
      # Optional value, default is 'profile' and 'email'
      'scopes' => array(
	'openid',
	'profile',
	'email',
    ),

simplesamlphp-authgoogleoauth2's People

Contributors

rgeyer avatar tauceti2 avatar melanger avatar vyskocilpavel avatar

Watchers

Miroslav Bauer avatar James Cloos avatar Petr Holub avatar  avatar

Forkers

dpenezic

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.