passport-gitlab2
Advanced tools
Comparing version 2.2.0 to 3.0.0
@@ -0,1 +1,13 @@ | ||
<a name="3.0.0"></a> | ||
# [3.0.0](https://github.com/fh1ch/passport-gitlab2/compare/v2.2.0...v3.0.0) (2017-04-02) | ||
### Features | ||
* **strategy:** use the `read_user` scope by default ([b381813](https://github.com/fh1ch/passport-gitlab2/commit/b3818131cc1556816eb963e6a91834a87fc09176)) | ||
### BREAKING CHANGES | ||
* strategy: Requires at least GitLab 8.15 and enabled `read_user` scope in your GitLab application configuration. | ||
<a name="2.2.0"></a> | ||
@@ -2,0 +14,0 @@ # [2.2.0](https://github.com/fh1ch/passport-gitlab2/compare/v2.1.0...v2.2.0) (2016-05-01) |
@@ -0,0 +0,0 @@ var Strategy = require('./strategy'); |
@@ -46,3 +46,3 @@ var url = require('url'); | ||
options.tokenURL = options.tokenURL || url.resolve(this._baseURL, 'oauth/token'); | ||
options.scope = options.scope || 'api'; | ||
options.scope = options.scope || 'read_user'; | ||
options.scopeSeparator = options.scopeSeparator || ','; | ||
@@ -49,0 +49,0 @@ |
@@ -0,0 +0,0 @@ The MIT License (MIT) |
{ | ||
"name": "passport-gitlab2", | ||
"version": "2.2.0", | ||
"version": "3.0.0", | ||
"description": "GitLab authentication strategy for Passport.", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -7,5 +7,5 @@ # passport-gitlab2 | ||
[![npm version](https://badge.fury.io/js/passport-gilab2.svg)](http://badge.fury.io/js/passport-gilab2) | ||
[![npm version](https://badge.fury.io/js/passport-gitlab2.svg)](http://badge.fury.io/js/passport-gitlab2) | ||
[![Build Status](https://travis-ci.org/fh1ch/passport-gitlab2.svg?branch=master&style=flat)](https://travis-ci.org/fh1ch/passport-gitlab2) | ||
[![Coverage Status](https://coveralls.io/repos/fh1ch/passport-gitlab2/badge.svg?branch=master)](https://coveralls.io/r/fh1ch/passport-gilab2?branch=master) | ||
[![Coverage Status](https://coveralls.io/repos/fh1ch/passport-gitlab2/badge.svg?branch=master)](https://coveralls.io/r/fh1ch/passport-gitlab2?branch=master) | ||
[![Code Climate](https://codeclimate.com/github/fh1ch/passport-gitlab2/badges/gpa.svg)](https://codeclimate.com/github/fh1ch/passport-gitlab2) | ||
@@ -106,10 +106,8 @@ [![Dependency Status](https://david-dm.org/fh1ch/passport-gitlab2.svg?theme=shields.io)](https://david-dm.org/fh1ch/passport-gitlab2) | ||
GitLab only supports one scope at the moment which is `api`. This scope allows | ||
full read/write access to all API resources. This behavior | ||
[might change](https://gitlab.com/gitlab-org/gitlab-ce/issues/13951) in the | ||
future. | ||
GitLab supports two scopes at the moment which are `read_user` and `api`. By | ||
default, the `read_user` scope is used which was introduced with **GitLab | ||
version 8.15** and requires at least this version. If you have an older version | ||
or you need full read/write access to all API resources, use the `api` scope | ||
instead. Changing the OAuth2 scope to `api` works as following: | ||
Even tough this is not yet needed, you can still modify the requested scope as | ||
following: | ||
```js | ||
@@ -122,2 +120,4 @@ app.get('/auth/gitlab', | ||
More information can be found in the [official GitLab documentation](https://docs.gitlab.com/ce/integration/oauth_provider.html#authorized-applications). | ||
## Contributing | ||
@@ -164,4 +164,4 @@ | ||
Copyright (c) 2016 Fabio Huser <fabio@fh1.ch> | ||
Copyright (c) 2016-2017 Fabio Huser <fabio@fh1.ch> | ||
Copyright (c) 2011-2016 Jared Hanson <[http://jaredhanson.net/](http://jaredhanson.net/)> |
Sorry, the diff of this file is not supported yet
12880