gitlab-org--gitlab-foss/spec/controllers/import
Stan Hu 88f2e9615c
Alias GitHub and BitBucket OAuth2 callback URLs
To prevent an OAuth2 covert redirect vulnerability, this commit adds and
uses an alias for the GitHub and BitBucket OAuth2 callback URLs to the
following paths:

GitHub: /users/auth/-/import/github
Bitbucket: /users/auth/-/import/bitbucket

This allows admins to put a more restrictive callback URL in the OAuth2
configuration settings. Instead of https://example.com, admins can now use:

https://example.com/users/auth

It's possible but not trivial to change Devise and OmniAuth to use a
different prefix for callback URLs instead of /users/auth. For now,
aliasing the import URLs under the /users/auth namespace should suffice.

Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/56663
2019-01-31 16:52:48 +01:00
..
bitbucket_controller_spec.rb Alias GitHub and BitBucket OAuth2 callback URLs 2019-01-31 16:52:48 +01:00
bitbucket_server_controller_spec.rb Fix Bitbucket Server import not allowing personal projects 2019-01-28 13:06:27 -08:00
fogbugz_controller_spec.rb Change all :empty_project to :project 2017-08-02 17:47:31 -04:00
gitea_controller_spec.rb Namespace access token session key in Import::GithubController 2016-12-19 17:35:51 +01:00
github_controller_spec.rb Alias GitHub and BitBucket OAuth2 callback URLs 2019-01-31 16:52:48 +01:00
gitlab_controller_spec.rb Update specs to rails5 format 2018-12-19 10:04:31 +11:00
gitlab_projects_controller_spec.rb Update specs to rails5 format 2018-12-19 10:04:31 +11:00
google_code_controller_spec.rb Update specs to rails5 format 2018-12-19 10:04:31 +11:00