summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* Guard discovery by username or key against bad API responsesNick Thomas2018-08-091-1/+1
|
* Fix two regressions in SSH certificate supportÆvar Arnfjörð Bjarmason2018-08-081-1/+1
| | | | | | | | | | | | | | | Fix two regressions in my 2e8b670 ("Add support for SSH certificate authentication", 2018-06-14) merged in gitlab-org/gitlab-shell!207. This fixes the issue noted in gitlab-org/gitlab-shell#145 where the command-line contains things other than the key/user/username, and also a regression where SSH certificates are being used, and the username presented in the key is unknown to GitLab. In that case, we should log the user in as "Anonymous" (on an instance that allows public access), but because of how the error checking around api.discover() was implemented we ended up erroring out instead.
* use GIT_PROTOCOL env variable in gitlab_shell#execJames Lopez2018-08-011-1/+1
|
* update gitlab shell to remove git_protocol env varJames Lopez2018-08-011-1/+0
|
* Add Git protocol v2James Lopez2018-08-013-6/+12
|
* Add support for SSH certificate authenticationÆvar Arnfjörð Bjarmason2018-07-264-33/+100
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This along with the code submitted to gitlab-ce in the gitlab-org/gitlab-ce! MR implements SSH certificate authentication. See the docs added to gitlab-ce for why and how to enable this. This, along with that MR, closes gitlab-org/gitlab-ce#3457 Implementation notes: - Because it's easy to do, and because an earlier nascent version of this would pass user-ID to gitlab-shell, that's now supported, even though the SSH certificate authentication uses username-USERNAME. - The astute reader will notice that not all the API calls in gitlab-ce's lib/api/internal.rb support a "username" argument, some only support "user_id". There's a few reasons for this: a) For this to be efficient, I am bending over backwards to avoid extra API calls when using SSH certificates. Therefore the /allowed API call will now return a "user id" to us if we're allowed to proceed further. This is then fed to existing APIs that would only be called after a successful call to /allowed. b) Not all of the git-shell codepaths go through /internal/allowed, or ever deal with a repository, e.g. the argument-less "Welcome to GitLab", and /internal/2fa_recovery_codes. These need to use /internal/discover to figure out details about the user, so support looking that up by username. c) Once we have the "user id", the GL_ID gets passed down to e.g. user-authored hooks. I don't want to have those all break by having to handle a third GL_ID mode of "username" in addition to the current "key id" and "user id".
* Support HTTP headers and sending JSONAsh McKenzie2018-07-202-11/+17
|
* Rename HTTPHelper#host to #internal_api_endpointAsh McKenzie2018-07-202-12/+12
|
* Add #base_api_endpoint for re-usabilityAsh McKenzie2018-07-201-1/+5
|
* Move HTTP logic out into HTTPHelperAsh McKenzie2018-07-202-104/+111
|
* allow long strings to remain intact while parsing broadcast messageCameron Crockett2018-06-011-4/+26
| | | | | | | | | | | | | | Added fix for msg nil edge case. fixed comment wording code review issues, bumped version and changelog entry Fixed rebase issues Moved strip out of the function Fixes for code review comments Removed trailing whitespaces
* Bump version to 7.1.3bvl-display-username-instead-of-fullnameBob Van Landuyt2018-05-241-1/+7
|
* Display the username instead of fullnameBob Van Landuyt2018-05-231-2/+2
| | | | | | | | When running `ssh git@gitlab.example.com` we used to reply with the full name. But it might actually be more useful to display the username. This is unique and can help support identifying issues. Closes #131
* Add missing GitlabLogger#error methodJacob Vosmaer (GitLab)2018-04-091-1/+6
|
* Flush log file after every writeJacob Vosmaer (GitLab)2018-03-231-0/+6
|
* Add Gitaly git-upload-archive migrated commandgitaly-upload-archiveAlejandro Rodríguez2018-03-201-0/+1
|
* Switch to structured loggingJacob Vosmaer (GitLab)2018-03-196-23/+114
|
* Update files to pass modern rubocop checks. Disable some of themdz-update-depsDmitriy Zaporozhets2018-02-229-55/+58
| | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
* Update rubocop and code to pass itDmitriy Zaporozhets2018-02-225-20/+22
| | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
* Print new project information in post receiveTiago Botelho2018-02-061-0/+1
|
* Remove special case treatment of Geo nodes for SSHStan Hu2018-01-123-16/+5
| | | | | | | We removed SSH support in https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/3553, so we no longer need the ability to show all refs for Geo nodes. Closes #115
* Remove direct redis integrationNick Thomas2018-01-1219-5482/+0
|
* Remove the GitlabProjects implementationNick Thomas2018-01-121-518/+0
|
* Merge branch '35385-allow-git-pull-push-on-project-redirects' into 'master'Douwe Maan2017-12-071-1/+1
|\ | | | | | | | | Prints a message if project was renamed See merge request gitlab-org/gitlab-shell!175
| * Prints a message if project was redirected35385-allow-git-pull-push-on-project-redirectsMayra Cabrera2017-12-071-1/+1
| |
* | Use 'git clone --no-local' when creating a forkJacob Vosmaer (GitLab)2017-12-061-2/+2
| |
* | Add a 'fork-repository' command that works with hashed storageNick Thomas2017-12-011-0/+31
|/ | | | | | | The existing 'fork-project' command cannot work with hashed storage as the source project basename differs from the destination repository basename. It is deprecated by the addition of 'fork-repository' and should be removed in the next major version.
* Add relative git object dir envvars to check access requestfeature/add-pwd-envvar-to-check-access-requestAhmad Sherif2017-10-102-6/+41
|
* pass gl_username through to hooksDavid Turner2017-09-283-10/+21
|
* Adds --force option to push branches.add-force-push-option-to-push-branchesTiago Botelho2017-09-191-1/+6
|
* Support new /internal/pre-receive API endpoint for post-receivegitaly-redis-refactorAlejandro Rodríguez2017-09-051-0/+8
|
* Support new /internal/post-receive API endpointAlejandro Rodríguez2017-08-302-20/+53
|
* Support old versions of ruby without monotonic clockGabriel Mazetto2017-08-091-1/+5
|
* Fix SSH support for Git for Windows v2.14sh-fix-git-upload-packStan Hu2017-08-061-3/+12
| | | | | | | Git For Windows 2.14 has a patch that changes `git-upload-pack` to `git upload-pack`. To make this work for gitlab-shell, just map this to `git-upload-pack`. Closes gitlab-org/gitlab-ce#36028
* Use git_config_options instead of git_config_parameters for Gitaly requestssh-support-gitaly-upload-pack-unhide-refsStan Hu2017-08-031-7/+10
|
* Merge branch 'update-redis-rb-3.3.3' into 'master'Douwe Maan2017-08-035-15/+73
|\ | | | | | | | | Bump redis-rb library to 3.3.3 See merge request !151
| * Bump redis-rb library to 3.3.3update-redis-rb-3.3.3Stan Hu2017-07-225-15/+73
| |
* | Fix setting permissions of SSH key tempfilesNick Thomas2017-08-021-5/+8
| |
* | Require tempfile to avoid a missing constant errorNick Thomas2017-08-021-0/+1
| |
* | Implement SSH authentication support in RubyNick Thomas2017-07-311-11/+67
| |
* | Merge branch 'sh-defer-reference-counter-load' into 'master'Robert Speicher2017-07-261-2/+6
|\ \ | | | | | | | | | | | | Optimize gitlab-projects by deferring the loading of gitlab_reference_counter See merge request !149
| * | Optimize gitlab-projects by deferring the loading of gitlab_reference_countersh-defer-reference-counter-loadStan Hu2017-07-211-2/+6
| | | | | | | | | | | | | | | | | | Loading gitlab_reference_counter loads gitlab_net, which adds an additional 100-200 ms of time. That file pulls in a vendored Redis library among other things.
* | | Make geo_node a default parametersh-show-all-refsStan Hu2017-07-242-2/+2
| | |
* | | Support unhiding of all refs for Geo NodesStan Hu2017-07-213-5/+16
| |/ |/| | | | | | | | | By default, we hide certain refs (e.g. keep-around/XXX) to save user download time. We need to preserve these references on secondary Geo nodes to have a true copy.
* | Handle internal API errors when getting merge request URLsonly-parse-mr-urls-on-successSean McGivern2017-07-121-1/+8
|/
* Merge branch 'gitaly-124-gitaly-ssh' into 'master'Robert Speicher2017-07-072-6/+12
|\ | | | | | | | | Gitaly SSH Client See merge request !139
| * no more single-value mergeKim "BKC" Carlbäcker2017-07-071-3/+1
| |
| * metrics makes no sense because 'exec'Kim "BKC" Carlbäcker2017-07-071-4/+2
| |
| * hashes have .include? not .has?Kim "BKC" Carlbäcker2017-07-071-1/+1
| |
| * type-oKim "BKC" Carlbäcker2017-07-061-1/+1
| |