mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2026-04-17 20:20:20 +00:00
Exclude SSH principals from .keys route
This commit is contained in:
parent
6a5dda7116
commit
cfcbc33af0
1 changed files with 3 additions and 0 deletions
|
|
@ -705,6 +705,9 @@ func ShowSSHKeys(ctx *context.Context) {
|
|||
|
||||
var buf bytes.Buffer
|
||||
for i := range keys {
|
||||
if keys[i].Type == asymkey_model.KeyTypePrincipal {
|
||||
continue // Don't display SSH principals, only public keys
|
||||
}
|
||||
buf.WriteString(keys[i].OmitEmail())
|
||||
buf.WriteString("\n")
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue