GithubHelp home page GithubHelp logo

isabella232 / idp-pw-api-passwordstore-google Goto Github PK

View Code? Open in Web Editor NEW

This project forked from silinternational/idp-pw-api-passwordstore-google

0.0 0.0 0.0 44 KB

Password store component for IdP PW API that uses Google as the backend.

License: MIT License

Shell 2.66% PHP 88.35% Makefile 4.53% Gherkin 4.45%

idp-pw-api-passwordstore-google's Introduction

This repository is no longer maintained. It has been incorporated into idp-pw-api.

idp-pw-api-passwordstore-google

Password store component for IdP PW API that uses Google as the backend.

To Use

  1. Create a project on https://console.developers.google.com/.
  2. Still in the Google Developers Console, create a Service Account.
  3. Check "Furnish a new private key" and "Enable G Suite Domain-wide Delegation".
  4. Save the JSON file it provides (containing your private key), but DO NOT store it in public version control (such as in a public GitHub repo).
  5. Enable the "Admin SDK" API for your project in the Google Developers Console.
  6. Have an admin for the relevant Google Apps domain go to http://admin.google.com/ and, under Security, Advanced, Manage API Client Access, grant your Client ID access to the following scope:
    https://www.googleapis.com/auth/admin.directory.user
  7. Set up a delegated admin account in Google Apps, authorized to make changes to users. You will use that email address as the value for an env. var.
  8. See the local.env.dist file to know what environment variables to provide when using this library.

Example Configuration

$googlePasswordStore = new GooglePasswordStore([
    
    // Required config fields (dummy values are shown here):
    'applicationName' => 'Name of Your Application',
    'delegatedAdminEmail' => '[email protected]',
    
    // You must provide one of these two fields:
    'jsonAuthConfigBase64' => '...', // A base64-encoded string of the JSON
                                     // auth file provided by Google.
    'jsonAuthFilePath' => '/somewhere/in/your/filesystem/google-auth.json',
    
    // Optional config fields (current defaults are shown here):
    'emailFieldName' => 'email',
    'employeeIdFieldName' => 'employee_id',
    'userActiveRecordClass' => '\common\models\User',
]);

For details about what each of those fields is used for, see the documenting comments in the /src/Google.php file.

idp-pw-api-passwordstore-google's People

Contributors

briskt avatar fillup avatar forevermatt 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.