Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/city-of-helsinki/passport-helsinki-example
Express 4.x app using Passport for authentication with City of Helsinki SSO.
https://github.com/city-of-helsinki/passport-helsinki-example
Last synced: 6 days ago
JSON representation
Express 4.x app using Passport for authentication with City of Helsinki SSO.
- Host: GitHub
- URL: https://github.com/city-of-helsinki/passport-helsinki-example
- Owner: City-of-Helsinki
- License: unlicense
- Created: 2015-10-29T20:25:18.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2022-05-03T06:05:45.000Z (over 2 years ago)
- Last Synced: 2024-11-18T23:15:55.234Z (2 months ago)
- Language: JavaScript
- Size: 6.84 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
This example demonstrates how to use [Express](http://expressjs.com/) 4.x and
[Passport](http://passportjs.org/) to authenticate users using City of Helsinki
SSO. Use this example as a starting point for your own web applications.## Instructions
To install this example on your computer, clone the repository and install
dependencies.```bash
$ git clone https://github.com/City-of-Helsinki/passport-helsinki-example.git
$ cd passport-helsinki-example
$ npm install
```The example uses environment variables to configure the consumer key and
consumer secret needed to access the OAuth2 API. Start the server with those
variables set to the appropriate credentials.```bash
$ CLIENT_ID=__OAUTH2_CLIENT_ID__ CLIENT_SECRET=__OAUTH2_CLIENT_SECRET__ node server.js
```Open a web browser and navigate to [http://localhost:3000/](http://localhost:3000/)
to see the example in action.