]> source.dussan.org Git - gitea.git/commit
allow native and ssh-keygen public key check
authorGibheer <gibheer+git@zero-knowledge.org>
Tue, 16 Feb 2016 22:01:56 +0000 (23:01 +0100)
committerGibheer <gibheer+git@zero-knowledge.org>
Tue, 16 Feb 2016 22:01:56 +0000 (23:01 +0100)
commit12403bdfb098d8118df734275c302c8c5de20ee4
treeb289b891ed4d1f56aa6ee98a875efb9c131ee14d
parent3af1d3c5810bd94b2f3f80831f2be3a97fc1ceb1
allow native and ssh-keygen public key check

This commit adds the possibibility to use either the native golang
libraries or ssh-keygen to check public keys. The check is adjusted
depending on the settings, so that only supported keys are let through.

This commit also brings back the blacklist feature, which was removed in
7ef9a055886574655d9f2be70c957bc16bf30500. This allows to blacklist
algorythms or keys based on the key length. This works with the native
and the ssh-keygen way.

Because of #2179 it also includes a way to adjust the path to
ssh-keygen and the working directory for ssh-keygen. With this,
sysadmins should be able to adjust the settings in a way, that SELinux
is okay with it. In the worst case, they can switch to the native
implementation and only loose support for ed25519 keys at the moment.
There are some other places which need adjustment to utilize the
parameters and the native implementation, but this sets the ground work.
conf/app.ini
models/ssh_key.go
models/ssh_key_test.go [new file with mode: 0644]
modules/setting/setting.go