Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Revert "Merge branch 'sh-bump-ruby-version' into 'master'" | Douwe Maan | 2018-12-13 | 1 | -18/+10 |
| | | | This reverts merge request !257 | ||||
* | Upgrade to Ruby 2.5.3 | Stan Hu | 2018-12-13 | 1 | -10/+18 |
| | |||||
* | Fix a RuboCop warning | Robert Speicher | 2018-08-15 | 1 | -1/+1 |
| | |||||
* | Revert "Merge branch 'ash.mckenzie/srp-refactor' into 'master'" | Nick Thomas | 2018-08-14 | 1 | -2/+0 |
| | | | | | This reverts commit 3aaf4751e09262c53544a1987f59b1308af9b6c1, reversing changes made to c6577e0d75f51b017f2f332838b97c3ca5b497c0. | ||||
* | Added TODO to fixup whatever naming | Ash McKenzie | 2018-08-01 | 1 | -0/+2 |
| | |||||
* | Add support for SSH certificate authentication | Ævar Arnfjörð Bjarmason | 2018-07-26 | 1 | -4/+22 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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". | ||||
* | Switch to structured logging | Jacob Vosmaer (GitLab) | 2018-03-19 | 1 | -4/+4 |
| | |||||
* | Update files to pass modern rubocop checks. Disable some of themdz-update-deps | Dmitriy Zaporozhets | 2018-02-22 | 1 | -13/+20 |
| | | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | ||||
* | Update rubocop and code to pass it | Dmitriy Zaporozhets | 2018-02-22 | 1 | -2/+2 |
| | | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | ||||
* | Add list-key-ids command | Michael Kozono | 2017-06-28 | 1 | -0/+13 |
| | |||||
* | Instrument GitLab Shell and log metrics data to a file | Paco Guzman | 2016-10-11 | 1 | -11/+20 |
| | |||||
* | In order to use chomp! on the input later, we need to dup the ARGV input ↵dup-frozen-argv-key | DJ Mountney | 2016-08-10 | 1 | -1/+2 |
| | | | | | | string for keys Also updated the gitlab_key tests to freeze the ARGV variables. | ||||
* | Update the keys permission check to open the file in write mode. | DJ Mountney | 2016-08-10 | 1 | -2/+2 |
| | | | | That way the file is created if it does not exist. | ||||
* | Changes proposed during review | Jacob Vosmaer | 2016-08-10 | 1 | -1/+1 |
| | |||||
* | Defense in depth for authorized_keys lines | Jacob Vosmaer | 2016-08-05 | 1 | -0/+5 |
| | |||||
* | Refactor 'GitlabKey' class awaysmall-fixes | Jacob Vosmaer | 2016-08-04 | 1 | -15/+11 |
| | | | | | It is not nice to have both 'GitlabKeys' and 'GitlabKey'. We also do not need GitlabKey to be a class when it has no state. | ||||
* | Add permission check tests, improve checkauthorized-keys-permission-check | Jacob Vosmaer | 2016-08-03 | 1 | -3/+3 |
| | |||||
* | Improve authorized_keys check | Jacob Vosmaer | 2016-08-02 | 1 | -0/+13 |
| | | | | | | The old check only looked if authorized_keys exists. With this change, we look whether we can actually open the file for reading and writing. When this fails we try to print useful diagnostic information. | ||||
* | Manage authorized_keys permissions continuouslykeys-chmod | Jacob Vosmaer | 2016-08-01 | 1 | -4/+11 |
| | | | | | | We can lazily create authorized_keys and set its permissions. This adds negligible overhead and it allows us to remove a setup step from GitLab both on source and in omnibus-gitlab. | ||||
* | Add authorized keys bin script to find keys by fingerprint | Pablo Carranza | 2016-03-24 | 1 | -11/+15 |
| | |||||
* | Merge branch 'batch-add-keys-timeout' | Dmitriy Zaporozhets | 2015-07-17 | 1 | -1/+1 |
|\ | | | | | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | ||||
| * | Increase batch_add_keys lock timeout to 300 seconds | Jacob Vosmaer | 2015-07-16 | 1 | -1/+1 |
| | | |||||
* | | Remove keys from authorized_keys in-place | Jacob Vosmaer | 2015-07-16 | 1 | -8/+7 |
|/ | | | | | | This will speed up the rm-key operation. The downside is that authorized_keys will not shrink when you remove a key. If this ever becomes a problem it can be fixed by running 'rake gitlab:shell:setup'. | ||||
* | Prevent keys with a very specific comment from accidentally being deleted. | Douwe Maan | 2015-04-14 | 1 | -2/+6 |
| | |||||
* | Include ecdsa keys in `gitlab_keys list-keys`.list-ecdsa | Douwe Maan | 2015-04-10 | 1 | -1/+1 |
| | |||||
* | Added list-keys command and spec | David Martin | 2014-10-15 | 1 | -0/+14 |
| | | | | | | | | | | | | | | | | | | Removed puts and tidied up regex Address the hound Address the hound, again Use single quotes Add back travis.yml file Remove travis.yml, only keep on fh-master Use single quotes Use single quotes | ||||
* | Expliclity require 'timeout' from the stdlib | Jacob Vosmaer | 2014-06-10 | 1 | -0/+1 |
| | | | | | | This avoids getting the following error on some platforms: NameError: uninitialized constant GitlabKeys::Timeout | ||||
* | Use authorized_keys lock when add new key to file | Dmitriy Zaporozhets | 2014-05-31 | 1 | -3/+5 |
| | | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | ||||
* | Put authorized_keys.lock in the .ssh directory | Jacob Vosmaer | 2014-05-30 | 1 | -1/+1 |
| | |||||
* | Use lock file when add or remove keys from authorized_keys file | Dmitriy Zaporozhets | 2014-04-18 | 1 | -14/+34 |
| | | | | | | This prevents concurrent modification of authorized_keys file Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | ||||
* | Add gitlab-keys batch-add-keys | Jacob Vosmaer | 2014-03-14 | 1 | -0/+18 |
| | | | | | This command is intended to be called by the GitLab Rails code when restoring an application backup. | ||||
* | Generate key_line in separate method | Jacob Vosmaer | 2014-03-14 | 1 | -1/+5 |
| | |||||
* | Fix return values in GitlabKeys | Jacob Vosmaer | 2013-11-20 | 1 | -0/+3 |
| | |||||
* | Use Ruby instead of the Bourne shell | Jacob Vosmaer | 2013-11-02 | 1 | -1/+1 |
| | |||||
* | Remove sed invocation from GitlabKeys | Jacob Vosmaer | 2013-11-02 | 1 | -2/+7 |
| | |||||
* | Use Kernel#open to append lines to authorized_keys | Jacob Vosmaer | 2013-10-31 | 1 | -3/+2 |
| | |||||
* | Use Tempfile instead of `sed -i` | Jacob Vosmaer | 2013-07-19 | 1 | -2/+5 |
| | | | | | | The syntax for `sed -i` is incompatible between GNU sed and BSD sed. By Tempfile from the Ruby standard library we can avoid using the `-i` option of sed. | ||||
* | Remove unused require statement | Jacob Vosmaer | 2013-07-19 | 1 | -1/+0 |
| | |||||
* | Ability to clear authorized_keys file | Dmitriy Zaporozhets | 2013-07-18 | 1 | -0/+5 |
| | |||||
* | Use :warn instead of :error for invalid commands. | ash | 2013-05-18 | 1 | -1/+1 |
| | |||||
* | Use a better error message if gitlab-keys gets an invalid command. | ash | 2013-05-18 | 1 | -1/+1 |
| | |||||
* | Add log messages for gitlab_keys. | ash | 2013-05-17 | 1 | -0/+4 |
| | |||||
* | Regex used in rm-key command is too lax | Max Krasnyansky | 2013-04-24 | 1 | -1/+1 |
| | | | | | | Basically the issue is that 'gitlab-shell rm-key key-2' removes all keys that match "key-2" pattern. "key-20", "key-25", etc. This change makes the regex used in the sed command more strict. | ||||
* | return non-zero status if gitlab-projects or gitlab-keys cmd was not successfulv1.2.0 | Dmitriy Zaporozhets | 2013-03-25 | 1 | -0/+1 |
| | |||||
* | test GitlabKeys exec | Dmitriy Zaporozhets | 2013-03-11 | 1 | -0/+2 |
| | |||||
* | more accurate key deletion | Dmitriy Zaporozhets | 2013-02-09 | 1 | -1/+1 |
| | |||||
* | Include gitlab_config in gitlab_init | Dmitriy Zaporozhets | 2013-02-06 | 1 | -1/+0 |
| | |||||
* | Fix key removal | Dmitriy Zaporozhets | 2013-02-05 | 1 | -1/+1 |
| | |||||
* | add/remove keys by id | Dmitriy Zaporozhets | 2013-02-05 | 1 | -4/+4 |
| | |||||
* | More tests | Dmitriy Zaporozhets | 2013-02-05 | 1 | -6/+0 |
| |