summaryrefslogtreecommitdiff
path: root/servconf.c
diff options
context:
space:
mode:
Diffstat (limited to 'servconf.c')
-rw-r--r--servconf.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/servconf.c b/servconf.c
index d7f54a62f..b1e52638c 100644
--- a/servconf.c
+++ b/servconf.c
@@ -12,7 +12,7 @@ Created: Mon Aug 21 15:48:58 1995 ylo
12*/ 12*/
13 13
14#include "includes.h" 14#include "includes.h"
15RCSID("$Id: servconf.c,v 1.2 1999/11/11 06:57:39 damien Exp $"); 15RCSID("$Id: servconf.c,v 1.3 1999/11/12 00:33:04 damien Exp $");
16 16
17#include "ssh.h" 17#include "ssh.h"
18#include "servconf.h" 18#include "servconf.h"
@@ -31,6 +31,7 @@ void initialize_server_options(ServerOptions *options)
31 options->key_regeneration_time = -1; 31 options->key_regeneration_time = -1;
32 options->permit_root_login = -1; 32 options->permit_root_login = -1;
33 options->ignore_rhosts = -1; 33 options->ignore_rhosts = -1;
34 options->ignore_user_known_hosts = -1;
34 options->print_motd = -1; 35 options->print_motd = -1;
35 options->check_mail = -1; 36 options->check_mail = -1;
36 options->x11_forwarding = -1; 37 options->x11_forwarding = -1;
@@ -88,6 +89,8 @@ void fill_default_server_options(ServerOptions *options)
88 options->permit_root_login = 1; /* yes */ 89 options->permit_root_login = 1; /* yes */
89 if (options->ignore_rhosts == -1) 90 if (options->ignore_rhosts == -1)
90 options->ignore_rhosts = 0; 91 options->ignore_rhosts = 0;
92 if (options->ignore_user_known_hosts == -1)
93 options->ignore_user_known_hosts = 0;
91 if (options->check_mail == -1) 94 if (options->check_mail == -1)
92 options->check_mail = 0; 95 options->check_mail = 0;
93 if (options->print_motd == -1) 96 if (options->print_motd == -1)
@@ -156,8 +159,8 @@ typedef enum
156 sPasswordAuthentication, sListenAddress, 159 sPasswordAuthentication, sListenAddress,
157 sPrintMotd, sIgnoreRhosts, sX11Forwarding, sX11DisplayOffset, 160 sPrintMotd, sIgnoreRhosts, sX11Forwarding, sX11DisplayOffset,
158 sStrictModes, sEmptyPasswd, sRandomSeedFile, sKeepAlives, sCheckMail, 161 sStrictModes, sEmptyPasswd, sRandomSeedFile, sKeepAlives, sCheckMail,
159 sUseLogin, sAllowUsers, sDenyUsers, sAllowGroups, sDenyGroups 162 sUseLogin, sAllowUsers, sDenyUsers, sAllowGroups, sDenyGroups,
160 163 sIgnoreUserKnownHosts
161} ServerOpCodes; 164} ServerOpCodes;
162 165
163/* Textual representation of the tokens. */ 166/* Textual representation of the tokens. */
@@ -195,6 +198,7 @@ static struct
195 { "listenaddress", sListenAddress }, 198 { "listenaddress", sListenAddress },
196 { "printmotd", sPrintMotd }, 199 { "printmotd", sPrintMotd },
197 { "ignorerhosts", sIgnoreRhosts }, 200 { "ignorerhosts", sIgnoreRhosts },
201 { "ignoreuserknownhosts", sIgnoreUserKnownHosts },
198 { "x11forwarding", sX11Forwarding }, 202 { "x11forwarding", sX11Forwarding },
199 { "x11displayoffset", sX11DisplayOffset }, 203 { "x11displayoffset", sX11DisplayOffset },
200 { "strictmodes", sStrictModes }, 204 { "strictmodes", sStrictModes },
@@ -402,7 +406,11 @@ void read_server_config(ServerOptions *options, const char *filename)
402 if (*intptr == -1) 406 if (*intptr == -1)
403 *intptr = value; 407 *intptr = value;
404 break; 408 break;
405 409
410 case sIgnoreUserKnownHosts:
411 intptr = &options->ignore_user_known_hosts;
412 goto parse_int;
413
406 case sRhostsAuthentication: 414 case sRhostsAuthentication:
407 intptr = &options->rhosts_authentication; 415 intptr = &options->rhosts_authentication;
408 goto parse_flag; 416 goto parse_flag;