diff options
author | djm@openbsd.org <djm@openbsd.org> | 2018-06-01 03:33:53 +0000 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2018-06-01 13:35:59 +1000 |
commit | 9c935dd9bf05628826ad2495d3e8bdf3d3271c21 (patch) | |
tree | 35ccf63e51d3daf2fa927b843d813295e41e96e6 | |
parent | d8748b91d1d6c108c0c260ed41fa55f37b9ef34b (diff) |
upstream: make UID available as a %-expansion everywhere that the
username is available currently. In the client this is via %i, in the server
%U (since %i was already used in the client in some places for this, but used
for something different in the server); bz#2870, ok dtucker@
OpenBSD-Commit-ID: c7e912b0213713316cb55db194b3a6415b3d4b95
-rw-r--r-- | auth.c | 8 | ||||
-rw-r--r-- | auth2-pubkey.c | 12 | ||||
-rw-r--r-- | readconf.c | 6 | ||||
-rw-r--r-- | session.c | 8 | ||||
-rw-r--r-- | sftp-server.c | 8 | ||||
-rw-r--r-- | ssh.c | 30 | ||||
-rw-r--r-- | ssh_config.5 | 14 | ||||
-rw-r--r-- | sshd_config.5 | 16 |
8 files changed, 67 insertions, 35 deletions
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: auth.c,v 1.128 2018/05/25 07:11:01 djm Exp $ */ | 1 | /* $OpenBSD: auth.c,v 1.129 2018/06/01 03:33:53 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2000 Markus Friedl. All rights reserved. | 3 | * Copyright (c) 2000 Markus Friedl. All rights reserved. |
4 | * | 4 | * |
@@ -422,11 +422,13 @@ auth_root_allowed(struct ssh *ssh, const char *method) | |||
422 | char * | 422 | char * |
423 | expand_authorized_keys(const char *filename, struct passwd *pw) | 423 | expand_authorized_keys(const char *filename, struct passwd *pw) |
424 | { | 424 | { |
425 | char *file, ret[PATH_MAX]; | 425 | char *file, uidstr[32], ret[PATH_MAX]; |
426 | int i; | 426 | int i; |
427 | 427 | ||
428 | snprintf(uidstr, sizeof(uidstr), "%llu", | ||
429 | (unsigned long long)pw->pw_uid); | ||
428 | file = percent_expand(filename, "h", pw->pw_dir, | 430 | file = percent_expand(filename, "h", pw->pw_dir, |
429 | "u", pw->pw_name, (char *)NULL); | 431 | "u", pw->pw_name, "U", uidstr, (char *)NULL); |
430 | 432 | ||
431 | /* | 433 | /* |
432 | * Ensure that filename starts anchored. If not, be backward | 434 | * Ensure that filename starts anchored. If not, be backward |
diff --git a/auth2-pubkey.c b/auth2-pubkey.c index 8024b1d6a..5603f5ef3 100644 --- a/auth2-pubkey.c +++ b/auth2-pubkey.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: auth2-pubkey.c,v 1.77 2018/03/03 03:15:51 djm Exp $ */ | 1 | /* $OpenBSD: auth2-pubkey.c,v 1.78 2018/06/01 03:33:53 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2000 Markus Friedl. All rights reserved. | 3 | * Copyright (c) 2000 Markus Friedl. All rights reserved. |
4 | * | 4 | * |
@@ -387,7 +387,7 @@ match_principals_command(struct ssh *ssh, struct passwd *user_pw, | |||
387 | pid_t pid; | 387 | pid_t pid; |
388 | char *tmp, *username = NULL, *command = NULL, **av = NULL; | 388 | char *tmp, *username = NULL, *command = NULL, **av = NULL; |
389 | char *ca_fp = NULL, *key_fp = NULL, *catext = NULL, *keytext = NULL; | 389 | char *ca_fp = NULL, *key_fp = NULL, *catext = NULL, *keytext = NULL; |
390 | char serial_s[16]; | 390 | char serial_s[16], uidstr[32]; |
391 | void (*osigchld)(int); | 391 | void (*osigchld)(int); |
392 | 392 | ||
393 | if (authoptsp != NULL) | 393 | if (authoptsp != NULL) |
@@ -447,8 +447,11 @@ match_principals_command(struct ssh *ssh, struct passwd *user_pw, | |||
447 | } | 447 | } |
448 | snprintf(serial_s, sizeof(serial_s), "%llu", | 448 | snprintf(serial_s, sizeof(serial_s), "%llu", |
449 | (unsigned long long)cert->serial); | 449 | (unsigned long long)cert->serial); |
450 | snprintf(uidstr, sizeof(uidstr), "%llu", | ||
451 | (unsigned long long)user_pw->pw_uid); | ||
450 | for (i = 1; i < ac; i++) { | 452 | for (i = 1; i < ac; i++) { |
451 | tmp = percent_expand(av[i], | 453 | tmp = percent_expand(av[i], |
454 | "U", uidstr, | ||
452 | "u", user_pw->pw_name, | 455 | "u", user_pw->pw_name, |
453 | "h", user_pw->pw_dir, | 456 | "h", user_pw->pw_dir, |
454 | "t", sshkey_ssh_name(key), | 457 | "t", sshkey_ssh_name(key), |
@@ -852,7 +855,7 @@ user_key_command_allowed2(struct ssh *ssh, struct passwd *user_pw, | |||
852 | int i, uid_swapped = 0, ac = 0; | 855 | int i, uid_swapped = 0, ac = 0; |
853 | pid_t pid; | 856 | pid_t pid; |
854 | char *username = NULL, *key_fp = NULL, *keytext = NULL; | 857 | char *username = NULL, *key_fp = NULL, *keytext = NULL; |
855 | char *tmp, *command = NULL, **av = NULL; | 858 | char uidstr[32], *tmp, *command = NULL, **av = NULL; |
856 | void (*osigchld)(int); | 859 | void (*osigchld)(int); |
857 | 860 | ||
858 | if (authoptsp != NULL) | 861 | if (authoptsp != NULL) |
@@ -902,8 +905,11 @@ user_key_command_allowed2(struct ssh *ssh, struct passwd *user_pw, | |||
902 | command); | 905 | command); |
903 | goto out; | 906 | goto out; |
904 | } | 907 | } |
908 | snprintf(uidstr, sizeof(uidstr), "%llu", | ||
909 | (unsigned long long)user_pw->pw_uid); | ||
905 | for (i = 1; i < ac; i++) { | 910 | for (i = 1; i < ac; i++) { |
906 | tmp = percent_expand(av[i], | 911 | tmp = percent_expand(av[i], |
912 | "U", uidstr, | ||
907 | "u", user_pw->pw_name, | 913 | "u", user_pw->pw_name, |
908 | "h", user_pw->pw_dir, | 914 | "h", user_pw->pw_dir, |
909 | "t", sshkey_ssh_name(key), | 915 | "t", sshkey_ssh_name(key), |
diff --git a/readconf.c b/readconf.c index 7b7a0d7e0..9c4a234b5 100644 --- a/readconf.c +++ b/readconf.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: readconf.c,v 1.287 2018/05/22 00:13:26 djm Exp $ */ | 1 | /* $OpenBSD: readconf.c,v 1.288 2018/06/01 03:33:53 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> | 3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> |
4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
@@ -551,6 +551,7 @@ match_cfg_line(Options *options, char **condition, struct passwd *pw, | |||
551 | const char *ruser; | 551 | const char *ruser; |
552 | int r, port, this_result, result = 1, attributes = 0, negate; | 552 | int r, port, this_result, result = 1, attributes = 0, negate; |
553 | char thishost[NI_MAXHOST], shorthost[NI_MAXHOST], portstr[NI_MAXSERV]; | 553 | char thishost[NI_MAXHOST], shorthost[NI_MAXHOST], portstr[NI_MAXSERV]; |
554 | char uidstr[32]; | ||
554 | 555 | ||
555 | /* | 556 | /* |
556 | * Configuration is likely to be incomplete at this point so we | 557 | * Configuration is likely to be incomplete at this point so we |
@@ -631,6 +632,8 @@ match_cfg_line(Options *options, char **condition, struct passwd *pw, | |||
631 | strlcpy(shorthost, thishost, sizeof(shorthost)); | 632 | strlcpy(shorthost, thishost, sizeof(shorthost)); |
632 | shorthost[strcspn(thishost, ".")] = '\0'; | 633 | shorthost[strcspn(thishost, ".")] = '\0'; |
633 | snprintf(portstr, sizeof(portstr), "%d", port); | 634 | snprintf(portstr, sizeof(portstr), "%d", port); |
635 | snprintf(uidstr, sizeof(uidstr), "%llu", | ||
636 | (unsigned long long)pw->pw_uid); | ||
634 | 637 | ||
635 | cmd = percent_expand(arg, | 638 | cmd = percent_expand(arg, |
636 | "L", shorthost, | 639 | "L", shorthost, |
@@ -641,6 +644,7 @@ match_cfg_line(Options *options, char **condition, struct passwd *pw, | |||
641 | "p", portstr, | 644 | "p", portstr, |
642 | "r", ruser, | 645 | "r", ruser, |
643 | "u", pw->pw_name, | 646 | "u", pw->pw_name, |
647 | "i", uidstr, | ||
644 | (char *)NULL); | 648 | (char *)NULL); |
645 | if (result != 1) { | 649 | if (result != 1) { |
646 | /* skip execution if prior predicate failed */ | 650 | /* skip execution if prior predicate failed */ |
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: session.c,v 1.294 2018/03/03 03:15:51 djm Exp $ */ | 1 | /* $OpenBSD: session.c,v 1.295 2018/06/01 03:33:53 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 3 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
4 | * All rights reserved | 4 | * All rights reserved |
@@ -1324,7 +1324,7 @@ safely_chroot(const char *path, uid_t uid) | |||
1324 | void | 1324 | void |
1325 | do_setusercontext(struct passwd *pw) | 1325 | do_setusercontext(struct passwd *pw) |
1326 | { | 1326 | { |
1327 | char *chroot_path, *tmp; | 1327 | char uidstr[32], *chroot_path, *tmp; |
1328 | 1328 | ||
1329 | platform_setusercontext(pw); | 1329 | platform_setusercontext(pw); |
1330 | 1330 | ||
@@ -1356,8 +1356,10 @@ do_setusercontext(struct passwd *pw) | |||
1356 | strcasecmp(options.chroot_directory, "none") != 0) { | 1356 | strcasecmp(options.chroot_directory, "none") != 0) { |
1357 | tmp = tilde_expand_filename(options.chroot_directory, | 1357 | tmp = tilde_expand_filename(options.chroot_directory, |
1358 | pw->pw_uid); | 1358 | pw->pw_uid); |
1359 | snprintf(uidstr, sizeof(uidstr), "%llu", | ||
1360 | (unsigned long long)pw->pw_uid); | ||
1359 | chroot_path = percent_expand(tmp, "h", pw->pw_dir, | 1361 | chroot_path = percent_expand(tmp, "h", pw->pw_dir, |
1360 | "u", pw->pw_name, (char *)NULL); | 1362 | "u", pw->pw_name, "U", uidstr, (char *)NULL); |
1361 | safely_chroot(chroot_path, pw->pw_uid); | 1363 | safely_chroot(chroot_path, pw->pw_uid); |
1362 | free(tmp); | 1364 | free(tmp); |
1363 | free(chroot_path); | 1365 | free(chroot_path); |
diff --git a/sftp-server.c b/sftp-server.c index df0fb5068..ab1b063f2 100644 --- a/sftp-server.c +++ b/sftp-server.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: sftp-server.c,v 1.111 2017/04/04 00:24:56 djm Exp $ */ | 1 | /* $OpenBSD: sftp-server.c,v 1.112 2018/06/01 03:33:53 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2000-2004 Markus Friedl. All rights reserved. | 3 | * Copyright (c) 2000-2004 Markus Friedl. All rights reserved. |
4 | * | 4 | * |
@@ -1503,7 +1503,7 @@ sftp_server_main(int argc, char **argv, struct passwd *user_pw) | |||
1503 | int i, r, in, out, max, ch, skipargs = 0, log_stderr = 0; | 1503 | int i, r, in, out, max, ch, skipargs = 0, log_stderr = 0; |
1504 | ssize_t len, olen, set_size; | 1504 | ssize_t len, olen, set_size; |
1505 | SyslogFacility log_facility = SYSLOG_FACILITY_AUTH; | 1505 | SyslogFacility log_facility = SYSLOG_FACILITY_AUTH; |
1506 | char *cp, *homedir = NULL, buf[4*4096]; | 1506 | char *cp, *homedir = NULL, uidstr[32], buf[4*4096]; |
1507 | long mask; | 1507 | long mask; |
1508 | 1508 | ||
1509 | extern char *optarg; | 1509 | extern char *optarg; |
@@ -1554,8 +1554,10 @@ sftp_server_main(int argc, char **argv, struct passwd *user_pw) | |||
1554 | break; | 1554 | break; |
1555 | case 'd': | 1555 | case 'd': |
1556 | cp = tilde_expand_filename(optarg, user_pw->pw_uid); | 1556 | cp = tilde_expand_filename(optarg, user_pw->pw_uid); |
1557 | snprintf(uidstr, sizeof(uidstr), "%llu", | ||
1558 | (unsigned long long)pw->pw_uid); | ||
1557 | homedir = percent_expand(cp, "d", user_pw->pw_dir, | 1559 | homedir = percent_expand(cp, "d", user_pw->pw_dir, |
1558 | "u", user_pw->pw_name, (char *)NULL); | 1560 | "u", user_pw->pw_name, "U", uidstr, (char *)NULL); |
1559 | free(cp); | 1561 | free(cp); |
1560 | break; | 1562 | break; |
1561 | case 'p': | 1563 | case 'p': |
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ssh.c,v 1.478 2018/06/01 03:11:49 djm Exp $ */ | 1 | /* $OpenBSD: ssh.c,v 1.479 2018/06/01 03:33:53 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> | 3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> |
4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
@@ -1278,7 +1278,8 @@ main(int ac, char **av) | |||
1278 | strlcpy(shorthost, thishost, sizeof(shorthost)); | 1278 | strlcpy(shorthost, thishost, sizeof(shorthost)); |
1279 | shorthost[strcspn(thishost, ".")] = '\0'; | 1279 | shorthost[strcspn(thishost, ".")] = '\0'; |
1280 | snprintf(portstr, sizeof(portstr), "%d", options.port); | 1280 | snprintf(portstr, sizeof(portstr), "%d", options.port); |
1281 | snprintf(uidstr, sizeof(uidstr), "%d", pw->pw_uid); | 1281 | snprintf(uidstr, sizeof(uidstr), "%llu", |
1282 | (unsigned long long)pw->pw_uid); | ||
1282 | 1283 | ||
1283 | if ((md = ssh_digest_start(SSH_DIGEST_SHA1)) == NULL || | 1284 | if ((md = ssh_digest_start(SSH_DIGEST_SHA1)) == NULL || |
1284 | ssh_digest_update(md, thishost, strlen(thishost)) < 0 || | 1285 | ssh_digest_update(md, thishost, strlen(thishost)) < 0 || |
@@ -1303,6 +1304,7 @@ main(int ac, char **av) | |||
1303 | "L", shorthost, | 1304 | "L", shorthost, |
1304 | "d", pw->pw_dir, | 1305 | "d", pw->pw_dir, |
1305 | "h", host, | 1306 | "h", host, |
1307 | "i", uidstr, | ||
1306 | "l", thishost, | 1308 | "l", thishost, |
1307 | "n", host_arg, | 1309 | "n", host_arg, |
1308 | "p", portstr, | 1310 | "p", portstr, |
@@ -1323,6 +1325,7 @@ main(int ac, char **av) | |||
1323 | "C", conn_hash_hex, | 1325 | "C", conn_hash_hex, |
1324 | "L", shorthost, | 1326 | "L", shorthost, |
1325 | "h", host, | 1327 | "h", host, |
1328 | "i", uidstr, | ||
1326 | "l", thishost, | 1329 | "l", thishost, |
1327 | "n", host_arg, | 1330 | "n", host_arg, |
1328 | "p", portstr, | 1331 | "p", portstr, |
@@ -1501,9 +1504,14 @@ main(int ac, char **av) | |||
1501 | } else { | 1504 | } else { |
1502 | p = tilde_expand_filename(options.identity_agent, | 1505 | p = tilde_expand_filename(options.identity_agent, |
1503 | original_real_uid); | 1506 | original_real_uid); |
1504 | cp = percent_expand(p, "d", pw->pw_dir, | 1507 | cp = percent_expand(p, |
1505 | "u", pw->pw_name, "l", thishost, "h", host, | 1508 | "d", pw->pw_dir, |
1506 | "r", options.user, (char *)NULL); | 1509 | "h", host, |
1510 | "i", uidstr, | ||
1511 | "l", thishost, | ||
1512 | "r", options.user, | ||
1513 | "u", pw->pw_name, | ||
1514 | (char *)NULL); | ||
1507 | setenv(SSH_AUTHSOCKET_ENV_NAME, cp, 1); | 1515 | setenv(SSH_AUTHSOCKET_ENV_NAME, cp, 1); |
1508 | free(cp); | 1516 | free(cp); |
1509 | free(p); | 1517 | free(p); |
@@ -1908,6 +1916,7 @@ ssh_session2(struct ssh *ssh, struct passwd *pw) | |||
1908 | "L", shorthost, | 1916 | "L", shorthost, |
1909 | "d", pw->pw_dir, | 1917 | "d", pw->pw_dir, |
1910 | "h", host, | 1918 | "h", host, |
1919 | "i", uidstr, | ||
1911 | "l", thishost, | 1920 | "l", thishost, |
1912 | "n", host_arg, | 1921 | "n", host_arg, |
1913 | "p", portstr, | 1922 | "p", portstr, |
@@ -2106,9 +2115,14 @@ load_public_identity_files(struct passwd *pw) | |||
2106 | for (i = 0; i < options.num_certificate_files; i++) { | 2115 | for (i = 0; i < options.num_certificate_files; i++) { |
2107 | cp = tilde_expand_filename(options.certificate_files[i], | 2116 | cp = tilde_expand_filename(options.certificate_files[i], |
2108 | original_real_uid); | 2117 | original_real_uid); |
2109 | filename = percent_expand(cp, "d", pw->pw_dir, | 2118 | filename = percent_expand(cp, |
2110 | "u", pw->pw_name, "l", thishost, "h", host, | 2119 | "d", pw->pw_dir, |
2111 | "r", options.user, (char *)NULL); | 2120 | "h", host, |
2121 | "i", host, | ||
2122 | "l", thishost, | ||
2123 | "r", options.user, | ||
2124 | "u", pw->pw_name, | ||
2125 | (char *)NULL); | ||
2112 | free(cp); | 2126 | free(cp); |
2113 | 2127 | ||
2114 | public = key_load_public(filename, NULL); | 2128 | public = key_load_public(filename, NULL); |
diff --git a/ssh_config.5 b/ssh_config.5 index bcd18a872..94c12bdda 100644 --- a/ssh_config.5 +++ b/ssh_config.5 | |||
@@ -33,8 +33,8 @@ | |||
33 | .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF | 33 | .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF |
34 | .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 34 | .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
35 | .\" | 35 | .\" |
36 | .\" $OpenBSD: ssh_config.5,v 1.273 2018/04/10 00:10:49 djm Exp $ | 36 | .\" $OpenBSD: ssh_config.5,v 1.274 2018/06/01 03:33:53 djm Exp $ |
37 | .Dd $Mdocdate: April 10 2018 $ | 37 | .Dd $Mdocdate: June 1 2018 $ |
38 | .Dt SSH_CONFIG 5 | 38 | .Dt SSH_CONFIG 5 |
39 | .Os | 39 | .Os |
40 | .Sh NAME | 40 | .Sh NAME |
@@ -1743,10 +1743,10 @@ The local username. | |||
1743 | .El | 1743 | .El |
1744 | .Pp | 1744 | .Pp |
1745 | .Cm Match exec | 1745 | .Cm Match exec |
1746 | accepts the tokens %%, %h, %L, %l, %n, %p, %r, and %u. | 1746 | accepts the tokens %%, %h, %i, %L, %l, %n, %p, %r, and %u. |
1747 | .Pp | 1747 | .Pp |
1748 | .Cm CertificateFile | 1748 | .Cm CertificateFile |
1749 | accepts the tokens %%, %d, %h, %l, %r, and %u. | 1749 | accepts the tokens %%, %d, %h, %i %l, %r, and %u. |
1750 | .Pp | 1750 | .Pp |
1751 | .Cm ControlPath | 1751 | .Cm ControlPath |
1752 | accepts the tokens %%, %C, %h, %i, %L, %l, %n, %p, %r, and %u. | 1752 | accepts the tokens %%, %C, %h, %i, %L, %l, %n, %p, %r, and %u. |
@@ -1757,16 +1757,16 @@ accepts the tokens %% and %h. | |||
1757 | .Cm IdentityAgent | 1757 | .Cm IdentityAgent |
1758 | and | 1758 | and |
1759 | .Cm IdentityFile | 1759 | .Cm IdentityFile |
1760 | accept the tokens %%, %d, %h, %l, %r, and %u. | 1760 | accept the tokens %%, %d, %h, %i %l, %r, and %u. |
1761 | .Pp | 1761 | .Pp |
1762 | .Cm LocalCommand | 1762 | .Cm LocalCommand |
1763 | accepts the tokens %%, %C, %d, %h, %l, %n, %p, %r, %T, and %u. | 1763 | accepts the tokens %%, %C, %d, %h, %i %l, %n, %p, %r, %T, and %u. |
1764 | .Pp | 1764 | .Pp |
1765 | .Cm ProxyCommand | 1765 | .Cm ProxyCommand |
1766 | accepts the tokens %%, %h, %p, and %r. | 1766 | accepts the tokens %%, %h, %p, and %r. |
1767 | .Pp | 1767 | .Pp |
1768 | .Cm RemoteCommand | 1768 | .Cm RemoteCommand |
1769 | accepts the tokens %%, %C, %d, %h, %l, %n, %p, %r, and %u. | 1769 | accepts the tokens %%, %C, %d, %h, %i, %l, %n, %p, %r, and %u. |
1770 | .Sh FILES | 1770 | .Sh FILES |
1771 | .Bl -tag -width Ds | 1771 | .Bl -tag -width Ds |
1772 | .It Pa ~/.ssh/config | 1772 | .It Pa ~/.ssh/config |
diff --git a/sshd_config.5 b/sshd_config.5 index 95dbc1d12..1d6e0d1e4 100644 --- a/sshd_config.5 +++ b/sshd_config.5 | |||
@@ -33,8 +33,8 @@ | |||
33 | .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF | 33 | .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF |
34 | .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 34 | .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
35 | .\" | 35 | .\" |
36 | .\" $OpenBSD: sshd_config.5,v 1.266 2018/05/15 05:40:11 jmc Exp $ | 36 | .\" $OpenBSD: sshd_config.5,v 1.267 2018/06/01 03:33:53 djm Exp $ |
37 | .Dd $Mdocdate: May 15 2018 $ | 37 | .Dd $Mdocdate: June 1 2018 $ |
38 | .Dt SSHD_CONFIG 5 | 38 | .Dt SSHD_CONFIG 5 |
39 | .Os | 39 | .Os |
40 | .Sh NAME | 40 | .Sh NAME |
@@ -1689,24 +1689,26 @@ The serial number of the certificate. | |||
1689 | The type of the CA key. | 1689 | The type of the CA key. |
1690 | .It %t | 1690 | .It %t |
1691 | The key or certificate type. | 1691 | The key or certificate type. |
1692 | .It %U | ||
1693 | The numeric user-id id of the target user. | ||
1692 | .It %u | 1694 | .It %u |
1693 | The username. | 1695 | The username. |
1694 | .El | 1696 | .El |
1695 | .Pp | 1697 | .Pp |
1696 | .Cm AuthorizedKeysCommand | 1698 | .Cm AuthorizedKeysCommand |
1697 | accepts the tokens %%, %f, %h, %k, %t, and %u. | 1699 | accepts the tokens %%, %f, %h, %k, %t, %U and %u. |
1698 | .Pp | 1700 | .Pp |
1699 | .Cm AuthorizedKeysFile | 1701 | .Cm AuthorizedKeysFile |
1700 | accepts the tokens %%, %h, and %u. | 1702 | accepts the tokens %%, %h, %U and %u. |
1701 | .Pp | 1703 | .Pp |
1702 | .Cm AuthorizedPrincipalsCommand | 1704 | .Cm AuthorizedPrincipalsCommand |
1703 | accepts the tokens %%, %F, %f, %h, %i, %K, %k, %s, %T, %t, and %u. | 1705 | accepts the tokens %%, %F, %f, %h, %i, %K, %k, %s, %T, %t, %U and %u. |
1704 | .Pp | 1706 | .Pp |
1705 | .Cm AuthorizedPrincipalsFile | 1707 | .Cm AuthorizedPrincipalsFile |
1706 | accepts the tokens %%, %h, and %u. | 1708 | accepts the tokens %%, %h, and %U %u. |
1707 | .Pp | 1709 | .Pp |
1708 | .Cm ChrootDirectory | 1710 | .Cm ChrootDirectory |
1709 | accepts the tokens %%, %h, and %u. | 1711 | accepts the tokens %%, %h, and %U %u. |
1710 | .Pp | 1712 | .Pp |
1711 | .Cm RoutingDomain | 1713 | .Cm RoutingDomain |
1712 | accepts the token %D. | 1714 | accepts the token %D. |