Added a Module Config option to set the SSH server version, rather than having Webmin auto-detect it.
---- Changes since 1.430 ----
Added a button on the module's main page for viewing the public side of the host keys, thanks to Sean Cox.
+---- Changes since 1.440 ----
+Added a field to allow or deny SSH 2 public key authentication.
print "</select></td>\n";
&ecmd();
+# SSH 1 RSA authentication
if ($version{'type'} ne 'ssh' || $version{'number'} < 3) {
&scmd();
$rsa = &find_value("RSAAuthentication", $conf);
&ecmd();
}
+# SSH 2 DSA authentication
+if ($version{'type'} eq 'openssh' && $version{'number'} >= 3) {
+ &scmd();
+ $rsa = &find_value("PubkeyAuthentication", $conf);
+ print "<td><b>$text{'users_dsa'}</b></td> <td nowrap>\n";
+ printf "<input type=radio name=dsa value=1 %s> %s\n",
+ lc($rsa) eq 'no' ? "" : "checked", $text{'yes'};
+ printf "<input type=radio name=dsa value=0 %s> %s</td>\n",
+ lc($rsa) eq 'no' ? "checked" : "", $text{'no'};
+ &ecmd();
+ }
+
&scmd();
$strict = &find_value("StrictModes", $conf);
print "<td><b>$text{'users_strict'}</b></td> <td nowrap>\n";
users_root=Allow login by root?
users_nopwd=Only with RSA auth
users_fcmd=Only for commands
-users_rsa=Allow RSA authentication?
+users_rsa=Allow RSA (SSH 1) authentication?
+users_dsa=Allow DSA (SSH 2) authentication?
users_strict=Check permissions on key files?
users_rhosts=Ignore <tt>.rhosts</tt> files?
users_rrhosts=Ignore <tt>.rhosts</tt> files for root user?
if ($version{'type'} ne 'ssh' || $version{'number'} < 3) {
&save_directive("RSAAuthentication", $conf, $in{'rsa'} ? 'yes' : 'no');
}
+if ($version{'type'} eq 'openssh' && $version{'number'} >= 3) {
+ &save_directive("PubkeyAuthentication", $conf,
+ $in{'dsa'} ? 'yes' : 'no');
+ }
&save_directive("StrictModes", $conf, $in{'strict'} ? 'yes' : 'no');