Fetch User Keys - simple tool for fetching SSH keys from various sources
1FUK(1) "git.sr.hr/~hauleth/fuk" "General Commands Manual"
2
3# NAME
4
5fuk - Fetch User Keys
6
7# SYNOPSIS
8
9*fuk* -h++
10*fuk* [--format (json|pretty)] _config.toml_
11
12# DESCRIPTION
13
14Tool for fetching public SSH keys from various sources.
15
16# CONFIGURATION
17
18Configuration uses TOML file format. In root it requires _entry_ field which
19must be a list of entries to be present in output. Each entry must have at least
202 keys:
21
22*name*
23 Name of output field.
24
25*keys*
26 List of sources for the keys. See _SOURCES_
27
28# SOURCES
29
30*raw*
31 Takes as a value list of public SSH keys. These keys will be printed in
32 the output as is.
33
34*host*
35 Hostnames that will be passed to _ssh-keyscan_(1).
36
37*http*
38 Takes `url` as and argument, with URL pointing to the HTTP resource that
39 will contain SSH keys.
40
41*github*, *gitlab*, *sourcehut*, *codeberg*
42 Each of these are shortcuts for *http* entries to provide default
43 _url_ for equivalent entries. In order these would be _github.com_,
44 _gitlab.com_, _meta.sr.ht_, and _codeberg.org_.
45
46Example configuration:
47
48```
49[[entry]]
50name = "hauleth"
51keys = [
52 { github = "hauleth" },
53 { sourcehut = "~hauleth" }
54]
55
56[[entry]]
57name = "sourcehut"
58keys = [
59 { hosts = [ "git.sr.ht", "hg.sr.ht" ] }
60]
61```
62
63# OUTPUT
64
65_fuk_ prints result to stdout in JSON format. Keys will be deduplicated by
66algorithm and key, but the comment *will* be ignored when comparing for
67equality. If comments for duplicated keys are different, then there is no
68guarantee about comment content.
69
70Example output:
71
72```
73{
74 "hauleth": [
75 "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAA...",
76 ],
77 "sourcehut": [
78 "ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNo...",
79 "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAA...",
80 "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAAB...",
81 ]
82}
83```
84
85# AUTHORS
86
87Maintained by Łukasz Niemier <~@hauleth.dev>. Sources can be found at
88https://git.sr.ht/~hauleth/fuk.
89
90# BUGS AND PATCHES
91
92Report bugs and submit patches to public inbox of maintainer at
93<~hauleth/public-inbox@lists.sr.ht>.
94
95; vim: noexpandtab