|
Jan F. Chadima |
a3ba41 |
diff -up openssh-5.2p1/configure.ac.vendor openssh-5.2p1/configure.ac
|
|
Jan F. Chadima |
adad2a |
--- openssh-5.2p1/configure.ac.vendor 2008-07-23 14:13:22.000000000 +0200
|
|
Jan F. Chadima |
adad2a |
+++ openssh-5.2p1/configure.ac 2008-07-23 14:13:22.000000000 +0200
|
|
Jan F. Chadima |
adad2a |
@@ -3890,6 +3890,12 @@ AC_ARG_WITH(lastlog,
|
|
Jan F. Chadima |
a3ba41 |
fi
|
|
Jan F. Chadima |
a3ba41 |
]
|
|
Jan F. Chadima |
a3ba41 |
)
|
|
Jan F. Chadima |
a3ba41 |
+AC_ARG_ENABLE(vendor-patchlevel,
|
|
Jan F. Chadima |
a3ba41 |
+ [ --enable-vendor-patchlevel=TAG specify a vendor patch level],
|
|
Jan F. Chadima |
a3ba41 |
+ [AC_DEFINE_UNQUOTED(SSH_VENDOR_PATCHLEVEL,[SSH_RELEASE "-" "$enableval"],[Define to your vendor patch level, if it has been modified from the upstream source release.])
|
|
Jan F. Chadima |
a3ba41 |
+ SSH_VENDOR_PATCHLEVEL="$enableval"],
|
|
Jan F. Chadima |
a3ba41 |
+ [AC_DEFINE(SSH_VENDOR_PATCHLEVEL,SSH_RELEASE,[Define to your vendor patch level, if it has been modified from the upstream source release.])
|
|
Jan F. Chadima |
a3ba41 |
+ SSH_VENDOR_PATCHLEVEL=none])
|
|
Jan F. Chadima |
a3ba41 |
|
|
Jan F. Chadima |
a3ba41 |
dnl lastlog, [uw]tmpx? detection
|
|
Jan F. Chadima |
a3ba41 |
dnl NOTE: set the paths in the platform section to avoid the
|
|
Jan F. Chadima |
adad2a |
@@ -4146,6 +4152,7 @@ echo " IP address in \$DISPLAY hac
|
|
Jan F. Chadima |
a3ba41 |
echo " Translate v4 in v6 hack: $IPV4_IN6_HACK_MSG"
|
|
Jan F. Chadima |
a3ba41 |
echo " BSD Auth support: $BSD_AUTH_MSG"
|
|
Jan F. Chadima |
a3ba41 |
echo " Random number source: $RAND_MSG"
|
|
Jan F. Chadima |
a3ba41 |
+echo " Vendor patch level: $SSH_VENDOR_PATCHLEVEL"
|
|
Jan F. Chadima |
a3ba41 |
if test ! -z "$USE_RAND_HELPER" ; then
|
|
Jan F. Chadima |
a3ba41 |
echo " ssh-rand-helper collects from: $RAND_HELPER_MSG"
|
|
Jan F. Chadima |
a3ba41 |
fi
|
|
Jan F. Chadima |
adad2a |
diff -up openssh-5.2p1/sshd_config.5.vendor openssh-5.2p1/sshd_config.5
|
|
Jan F. Chadima |
adad2a |
--- openssh-5.2p1/sshd_config.5.vendor 2008-07-23 14:13:22.000000000 +0200
|
|
Jan F. Chadima |
adad2a |
+++ openssh-5.2p1/sshd_config.5 2008-07-23 14:19:23.000000000 +0200
|
|
Jan F. Chadima |
adad2a |
@@ -812,6 +812,14 @@ This option applies to protocol version
|
|
Jan F. Chadima |
adad2a |
.It Cm ServerKeyBits
|
|
Jan F. Chadima |
adad2a |
Defines the number of bits in the ephemeral protocol version 1 server key.
|
|
Jan F. Chadima |
adad2a |
The minimum value is 512, and the default is 1024.
|
|
Jan F. Chadima |
adad2a |
+.It Cm ShowPatchLevel
|
|
Jan F. Chadima |
adad2a |
+Specifies whether
|
|
Jan F. Chadima |
adad2a |
+.Nm sshd
|
|
Jan F. Chadima |
adad2a |
+will display the patch level of the binary in the identification string.
|
|
Jan F. Chadima |
adad2a |
+The patch level is set at compile-time.
|
|
Jan F. Chadima |
adad2a |
+The default is
|
|
Jan F. Chadima |
adad2a |
+.Dq no .
|
|
Jan F. Chadima |
adad2a |
+This option applies to protocol version 1 only.
|
|
Jan F. Chadima |
adad2a |
.It Cm StrictModes
|
|
Jan F. Chadima |
adad2a |
Specifies whether
|
|
Jan F. Chadima |
adad2a |
.Xr sshd 8
|
|
Jan F. Chadima |
adad2a |
diff -up openssh-5.2p1/servconf.h.vendor openssh-5.2p1/servconf.h
|
|
Jan F. Chadima |
adad2a |
--- openssh-5.2p1/servconf.h.vendor 2008-06-10 15:01:51.000000000 +0200
|
|
Jan F. Chadima |
adad2a |
+++ openssh-5.2p1/servconf.h 2008-07-23 14:13:22.000000000 +0200
|
|
Jan F. Chadima |
adad2a |
@@ -126,6 +126,7 @@ typedef struct {
|
|
Jan F. Chadima |
adad2a |
int max_authtries;
|
|
Jan F. Chadima |
adad2a |
int max_sessions;
|
|
Jan F. Chadima |
adad2a |
char *banner; /* SSH-2 banner message */
|
|
Jan F. Chadima |
adad2a |
+ int show_patchlevel; /* Show vendor patch level to clients */
|
|
Jan F. Chadima |
adad2a |
int use_dns;
|
|
Jan F. Chadima |
adad2a |
int client_alive_interval; /*
|
|
Jan F. Chadima |
adad2a |
* poke the client this often to
|
|
Jan F. Chadima |
a3ba41 |
diff -up openssh-5.2p1/servconf.c.vendor openssh-5.2p1/servconf.c
|
|
Jan F. Chadima |
adad2a |
--- openssh-5.2p1/servconf.c.vendor 2008-07-04 05:51:12.000000000 +0200
|
|
Jan F. Chadima |
adad2a |
+++ openssh-5.2p1/servconf.c 2008-07-23 14:32:27.000000000 +0200
|
|
Jan F. Chadima |
a3ba41 |
@@ -117,6 +117,7 @@ initialize_server_options(ServerOptions
|
|
Jan F. Chadima |
a3ba41 |
options->max_authtries = -1;
|
|
Jan F. Chadima |
a3ba41 |
options->max_sessions = -1;
|
|
Jan F. Chadima |
a3ba41 |
options->banner = NULL;
|
|
Jan F. Chadima |
a3ba41 |
+ options->show_patchlevel = -1;
|
|
Jan F. Chadima |
a3ba41 |
options->use_dns = -1;
|
|
Jan F. Chadima |
a3ba41 |
options->client_alive_interval = -1;
|
|
Jan F. Chadima |
a3ba41 |
options->client_alive_count_max = -1;
|
|
Jan F. Chadima |
a3ba41 |
@@ -262,6 +263,9 @@ fill_default_server_options(ServerOption
|
|
Jan F. Chadima |
a3ba41 |
if (options->zero_knowledge_password_authentication == -1)
|
|
Jan F. Chadima |
a3ba41 |
options->zero_knowledge_password_authentication = 0;
|
|
Jan F. Chadima |
a3ba41 |
|
|
Jan F. Chadima |
a3ba41 |
+ if (options->show_patchlevel == -1)
|
|
Jan F. Chadima |
a3ba41 |
+ options->show_patchlevel = 0;
|
|
Jan F. Chadima |
a3ba41 |
+
|
|
Jan F. Chadima |
a3ba41 |
/* Turn privilege separation on by default */
|
|
Jan F. Chadima |
a3ba41 |
if (use_privsep == -1)
|
|
Jan F. Chadima |
a3ba41 |
use_privsep = 1;
|
|
Jan F. Chadima |
a3ba41 |
@@ -299,7 +303,7 @@ typedef enum {
|
|
Jan F. Chadima |
a3ba41 |
sIgnoreUserKnownHosts, sCiphers, sMacs, sProtocol, sPidFile,
|
|
Jan F. Chadima |
a3ba41 |
sGatewayPorts, sPubkeyAuthentication, sXAuthLocation, sSubsystem,
|
|
Jan F. Chadima |
a3ba41 |
sMaxStartups, sMaxAuthTries, sMaxSessions,
|
|
Jan F. Chadima |
a3ba41 |
- sBanner, sUseDNS, sHostbasedAuthentication,
|
|
Jan F. Chadima |
a3ba41 |
+ sBanner, sShowPatchLevel, sUseDNS, sHostbasedAuthentication,
|
|
Jan F. Chadima |
a3ba41 |
sHostbasedUsesNameFromPacketOnly, sClientAliveInterval,
|
|
Jan F. Chadima |
a3ba41 |
sClientAliveCountMax, sAuthorizedKeysFile, sAuthorizedKeysFile2,
|
|
Jan F. Chadima |
a3ba41 |
sGssAuthentication, sGssCleanupCreds, sAcceptEnv, sPermitTunnel,
|
|
Jan F. Chadima |
a3ba41 |
@@ -410,6 +414,7 @@ static struct {
|
|
Jan F. Chadima |
a3ba41 |
{ "maxauthtries", sMaxAuthTries, SSHCFG_ALL },
|
|
Jan F. Chadima |
a3ba41 |
{ "maxsessions", sMaxSessions, SSHCFG_ALL },
|
|
Jan F. Chadima |
a3ba41 |
{ "banner", sBanner, SSHCFG_ALL },
|
|
Jan F. Chadima |
a3ba41 |
+ { "showpatchlevel", sShowPatchLevel, SSHCFG_GLOBAL },
|
|
Jan F. Chadima |
a3ba41 |
{ "usedns", sUseDNS, SSHCFG_GLOBAL },
|
|
Jan F. Chadima |
a3ba41 |
{ "verifyreversemapping", sDeprecated, SSHCFG_GLOBAL },
|
|
Jan F. Chadima |
a3ba41 |
{ "reversemappingcheck", sDeprecated, SSHCFG_GLOBAL },
|
|
Jan F. Chadima |
a3ba41 |
@@ -1033,6 +1038,10 @@ process_server_config_line(ServerOptions
|
|
Jan F. Chadima |
a3ba41 |
intptr = &use_privsep;
|
|
Jan F. Chadima |
a3ba41 |
goto parse_flag;
|
|
Jan F. Chadima |
a3ba41 |
|
|
Jan F. Chadima |
a3ba41 |
+ case sShowPatchLevel:
|
|
Jan F. Chadima |
a3ba41 |
+ intptr = &options->show_patchlevel;
|
|
Jan F. Chadima |
a3ba41 |
+ goto parse_flag;
|
|
Jan F. Chadima |
a3ba41 |
+
|
|
Jan F. Chadima |
a3ba41 |
case sAllowUsers:
|
|
Jan F. Chadima |
a3ba41 |
while ((arg = strdelim(&cp)) && *arg != '\0') {
|
|
Jan F. Chadima |
a3ba41 |
if (options->num_allow_users >= MAX_ALLOW_USERS)
|
|
Jan F. Chadima |
a3ba41 |
@@ -1613,6 +1622,7 @@ dump_config(ServerOptions *o)
|
|
Jan F. Chadima |
a3ba41 |
dump_cfg_fmtint(sUseLogin, o->use_login);
|
|
Jan F. Chadima |
a3ba41 |
dump_cfg_fmtint(sCompression, o->compression);
|
|
Jan F. Chadima |
a3ba41 |
dump_cfg_fmtint(sGatewayPorts, o->gateway_ports);
|
|
Jan F. Chadima |
a3ba41 |
+ dump_cfg_fmtint(sShowPatchLevel, o->show_patchlevel);
|
|
Jan F. Chadima |
a3ba41 |
dump_cfg_fmtint(sUseDNS, o->use_dns);
|
|
Jan F. Chadima |
a3ba41 |
dump_cfg_fmtint(sAllowTcpForwarding, o->allow_tcp_forwarding);
|
|
Jan F. Chadima |
a3ba41 |
dump_cfg_fmtint(sUsePrivilegeSeparation, use_privsep);
|
|
Jan F. Chadima |
a3ba41 |
diff -up openssh-5.2p1/sshd_config.0.vendor openssh-5.2p1/sshd_config.0
|
|
Jan F. Chadima |
adad2a |
--- openssh-5.2p1/sshd_config.0.vendor 2008-07-23 14:13:22.000000000 +0200
|
|
Jan F. Chadima |
adad2a |
+++ openssh-5.2p1/sshd_config.0 2008-07-23 14:13:22.000000000 +0200
|
|
Jan F. Chadima |
adad2a |
@@ -466,6 +466,11 @@ DESCRIPTION
|
|
Jan F. Chadima |
a3ba41 |
Defines the number of bits in the ephemeral protocol version 1
|
|
Jan F. Chadima |
a3ba41 |
server key. The minimum value is 512, and the default is 1024.
|
|
Jan F. Chadima |
a3ba41 |
|
|
Jan F. Chadima |
a3ba41 |
+ ShowPatchLevel
|
|
Jan F. Chadima |
a3ba41 |
+ Specifies whether sshd will display the specific patch level of
|
|
Jan F. Chadima |
a3ba41 |
+ the binary in the server identification string. The patch level
|
|
Jan F. Chadima |
a3ba41 |
+ is set at compile-time. The default is M-bM-^@M-^\noM-bM-^@M-^].
|
|
Jan F. Chadima |
a3ba41 |
+
|
|
Jan F. Chadima |
a3ba41 |
StrictModes
|
|
Jan F. Chadima |
a3ba41 |
Specifies whether sshd(8) should check file modes and ownership
|
|
Jan F. Chadima |
a3ba41 |
of the user's files and home directory before accepting login.
|
|
Jan F. Chadima |
a3ba41 |
diff -up openssh-5.2p1/sshd_config.vendor openssh-5.2p1/sshd_config
|
|
Jan F. Chadima |
adad2a |
--- openssh-5.2p1/sshd_config.vendor 2008-07-23 14:13:22.000000000 +0200
|
|
Jan F. Chadima |
adad2a |
+++ openssh-5.2p1/sshd_config 2008-07-23 14:13:22.000000000 +0200
|
|
Jan F. Chadima |
a3ba41 |
@@ -112,6 +112,7 @@ X11Forwarding yes
|
|
Jan F. Chadima |
a3ba41 |
#Compression delayed
|
|
Jan F. Chadima |
a3ba41 |
#ClientAliveInterval 0
|
|
Jan F. Chadima |
a3ba41 |
#ClientAliveCountMax 3
|
|
Jan F. Chadima |
a3ba41 |
+#ShowPatchLevel no
|
|
Jan F. Chadima |
a3ba41 |
#UseDNS yes
|
|
Jan F. Chadima |
a3ba41 |
#PidFile /var/run/sshd.pid
|
|
Jan F. Chadima |
a3ba41 |
#MaxStartups 10
|
|
Jan F. Chadima |
a3ba41 |
diff -up openssh-5.2p1/sshd.c.vendor openssh-5.2p1/sshd.c
|
|
Jan F. Chadima |
adad2a |
--- openssh-5.2p1/sshd.c.vendor 2008-07-11 09:36:49.000000000 +0200
|
|
Jan F. Chadima |
adad2a |
+++ openssh-5.2p1/sshd.c 2008-07-23 14:35:43.000000000 +0200
|
|
Jan F. Chadima |
adad2a |
@@ -416,7 +416,7 @@ sshd_exchange_identification(int sock_in
|
|
Jan F. Chadima |
a3ba41 |
minor = PROTOCOL_MINOR_1;
|
|
Jan F. Chadima |
a3ba41 |
}
|
|
Jan F. Chadima |
a3ba41 |
snprintf(buf, sizeof buf, "SSH-%d.%d-%.100s%s", major, minor,
|
|
Jan F. Chadima |
a3ba41 |
- SSH_VERSION, newline);
|
|
Jan F. Chadima |
a3ba41 |
+ (options.show_patchlevel == 1) ? SSH_VENDOR_PATCHLEVEL : SSH_VERSION, newline);
|
|
Jan F. Chadima |
a3ba41 |
server_version_string = xstrdup(buf);
|
|
Jan F. Chadima |
a3ba41 |
|
|
Jan F. Chadima |
a3ba41 |
/* Send our protocol version identification. */
|
|
Jan F. Chadima |
adad2a |
@@ -1484,7 +1484,8 @@ main(int ac, char **av)
|
|
Jan F. Chadima |
a3ba41 |
exit(1);
|
|
Jan F. Chadima |
a3ba41 |
}
|
|
Jan F. Chadima |
a3ba41 |
|
|
Jan F. Chadima |
a3ba41 |
- debug("sshd version %.100s", SSH_RELEASE);
|
|
Jan F. Chadima |
a3ba41 |
+ debug("sshd version %.100s",
|
|
Jan F. Chadima |
a3ba41 |
+ (options.show_patchlevel == 1) ? SSH_VENDOR_PATCHLEVEL : SSH_RELEASE);
|
|
Jan F. Chadima |
a3ba41 |
|
|
Jan F. Chadima |
a3ba41 |
/* Store privilege separation user for later use if required. */
|
|
Jan F. Chadima |
a3ba41 |
if ((privsep_pw = getpwnam(SSH_PRIVSEP_USER)) == NULL) {
|