<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/gitlab/gitlab-ce.git/lib/api/api_guard.rb, branch replace_explore_projects.feature</title>
<subtitle>gitlab.com: gitlab-org/gitlab-ce.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-ce.git/'/>
<entry>
<title>Make sure API responds with 401 when invalid authentication info is provided</title>
<updated>2017-09-28T12:17:52+00:00</updated>
<author>
<name>Douwe Maan</name>
<email>douwe@selenight.nl</email>
</author>
<published>2017-09-27T13:31:52+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-ce.git/commit/?id=b6c5a73c0bc0bc68ca8c66a5cefa50d314cc164a'/>
<id>b6c5a73c0bc0bc68ca8c66a5cefa50d314cc164a</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Whitelist or fix additional `Gitlab/PublicSend` cop violations</title>
<updated>2017-08-14T16:14:11+00:00</updated>
<author>
<name>Robert Speicher</name>
<email>rspeicher@gmail.com</email>
</author>
<published>2017-08-10T16:39:26+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-ce.git/commit/?id=260c8da060a6039cbd47cfe31c8ec6d6f9b43de0'/>
<id>260c8da060a6039cbd47cfe31c8ec6d6f9b43de0</id>
<content type='text'>
An upcoming update to rubocop-gitlab-security added additional
violations.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
An upcoming update to rubocop-gitlab-security added additional
violations.
</pre>
</div>
</content>
</entry>
<entry>
<title>Extract a `Gitlab::Scope` class.</title>
<updated>2017-06-29T06:15:57+00:00</updated>
<author>
<name>Timothy Andrew</name>
<email>mail@timothyandrew.net</email>
</author>
<published>2017-06-28T07:12:23+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-ce.git/commit/?id=b8ec1f4201c74c500e4f7010b238c7920599da7a'/>
<id>b8ec1f4201c74c500e4f7010b238c7920599da7a</id>
<content type='text'>
- To represent an authorization scope, such as `api` or `read_user`
- This is a better abstraction than the hash we were previously using.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- To represent an authorization scope, such as `api` or `read_user`
- This is a better abstraction than the hash we were previously using.
</pre>
</div>
</content>
</entry>
<entry>
<title>Implement review comments from @DouweM for !12300.</title>
<updated>2017-06-28T07:17:13+00:00</updated>
<author>
<name>Timothy Andrew</name>
<email>mail@timothyandrew.net</email>
</author>
<published>2017-06-26T04:14:10+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-ce.git/commit/?id=c1fcd730cc9dbee5b41ce2a6a12f8d84416b1a4a'/>
<id>c1fcd730cc9dbee5b41ce2a6a12f8d84416b1a4a</id>
<content type='text'>
- Use a struct for scopes, so we can call `scope.if` instead of `scope[:if]`

- Refactor the "remove scopes whose :if condition returns false" logic to use a
  `select` rather than a `reject`.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- Use a struct for scopes, so we can call `scope.if` instead of `scope[:if]`

- Refactor the "remove scopes whose :if condition returns false" logic to use a
  `select` rather than a `reject`.
</pre>
</div>
</content>
</entry>
<entry>
<title>Implement review comments from @dbalexandre for !12300.</title>
<updated>2017-06-28T07:17:13+00:00</updated>
<author>
<name>Timothy Andrew</name>
<email>mail@timothyandrew.net</email>
</author>
<published>2017-06-23T11:18:44+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-ce.git/commit/?id=4dbfa14e160e0d9bca11941adcf04b3d272aa1a2'/>
<id>4dbfa14e160e0d9bca11941adcf04b3d272aa1a2</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix remaining spec failures for !12300.</title>
<updated>2017-06-28T07:17:13+00:00</updated>
<author>
<name>Timothy Andrew</name>
<email>mail@timothyandrew.net</email>
</author>
<published>2017-06-21T09:22:39+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-ce.git/commit/?id=1b8223dd51345f6075172a92dab610f9dee89d84'/>
<id>1b8223dd51345f6075172a92dab610f9dee89d84</id>
<content type='text'>
1. Get the spec for `lib/gitlab/auth.rb` passing.

  - Make the `request` argument to `AccessTokenValidationService` optional -
  `auth.rb` doesn't need to pass in a request.

  - Pass in scopes in the format `[{ name: 'api' }]` rather than `['api']`, which
  is what `AccessTokenValidationService` now expects.

2. Get the spec for `API::V3::Users` passing

2. Get the spec for `AccessTokenValidationService` passing
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
1. Get the spec for `lib/gitlab/auth.rb` passing.

  - Make the `request` argument to `AccessTokenValidationService` optional -
  `auth.rb` doesn't need to pass in a request.

  - Pass in scopes in the format `[{ name: 'api' }]` rather than `['api']`, which
  is what `AccessTokenValidationService` now expects.

2. Get the spec for `API::V3::Users` passing

2. Get the spec for `AccessTokenValidationService` passing
</pre>
</div>
</content>
</entry>
<entry>
<title>When verifying scopes, manually include scopes from `API::API`.</title>
<updated>2017-06-28T07:17:13+00:00</updated>
<author>
<name>Timothy Andrew</name>
<email>mail@timothyandrew.net</email>
</author>
<published>2017-06-20T12:00:57+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-ce.git/commit/?id=d774825f981a73263c9a6c276c672b0c3e9bf104'/>
<id>d774825f981a73263c9a6c276c672b0c3e9bf104</id>
<content type='text'>
- They are not included automatically since `API::Users` does not inherit from
  `API::API`, as I initially assumed.

- Scopes declared in `API::API` are considered global (to the API), and need to
  be included in all cases.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- They are not included automatically since `API::Users` does not inherit from
  `API::API`, as I initially assumed.

- Scopes declared in `API::API` are considered global (to the API), and need to
  be included in all cases.
</pre>
</div>
</content>
</entry>
<entry>
<title>Allow API scope declarations to be applied conditionally.</title>
<updated>2017-06-28T07:17:13+00:00</updated>
<author>
<name>Timothy Andrew</name>
<email>mail@timothyandrew.net</email>
</author>
<published>2017-06-20T08:27:45+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-ce.git/commit/?id=80c1ebaa83f346e45346baac584f21878652c350'/>
<id>80c1ebaa83f346e45346baac584f21878652c350</id>
<content type='text'>
- Scope declarations of the form:

    allow_access_with_scope :read_user, if: -&gt; (request) { request.get? }

  will only apply for `GET` requests

- Add a negative test to a `POST` endpoint in the `users` API to test this. Also
  test for this case in the `AccessTokenValidationService` unit tests.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- Scope declarations of the form:

    allow_access_with_scope :read_user, if: -&gt; (request) { request.get? }

  will only apply for `GET` requests

- Add a negative test to a `POST` endpoint in the `users` API to test this. Also
  test for this case in the `AccessTokenValidationService` unit tests.
</pre>
</div>
</content>
</entry>
<entry>
<title>Initial attempt at refactoring API scope declarations.</title>
<updated>2017-06-28T07:17:13+00:00</updated>
<author>
<name>Timothy Andrew</name>
<email>mail@timothyandrew.net</email>
</author>
<published>2017-06-20T07:40:24+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-ce.git/commit/?id=6f1922500bc9e2c6d53c46dfcbd420687dfe6e6b'/>
<id>6f1922500bc9e2c6d53c46dfcbd420687dfe6e6b</id>
<content type='text'>
- Declaring an endpoint's scopes in a `before` block has proved to be
  unreliable. For example, if we're accessing the `API::Users` endpoint - code
  in a `before` block in `API::API` wouldn't be able to see the scopes set in
  `API::Users` since the `API::API` `before` block runs first.

- This commit moves these declarations to the class level, since they don't need
  to change once set.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- Declaring an endpoint's scopes in a `before` block has proved to be
  unreliable. For example, if we're accessing the `API::Users` endpoint - code
  in a `before` block in `API::API` wouldn't be able to see the scopes set in
  `API::Users` since the `API::API` `before` block runs first.

- This commit moves these declarations to the class level, since they don't need
  to change once set.
</pre>
</div>
</content>
</entry>
<entry>
<title>Enable Style/Proc cop for rubocop</title>
<updated>2017-04-02T09:48:43+00:00</updated>
<author>
<name>mhasbini</name>
<email>mohammad.hasbini@gmail.com</email>
</author>
<published>2017-03-31T15:11:28+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-ce.git/commit/?id=0a09925dcef1976970bc2674432f69d46786c38f'/>
<id>0a09925dcef1976970bc2674432f69d46786c38f</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
