summaryrefslogtreecommitdiff
path: root/servconf.c
diff options
context:
space:
mode:
Diffstat (limited to 'servconf.c')
-rw-r--r--servconf.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/servconf.c b/servconf.c
index 0cb744a1d..e33d65a5e 100644
--- a/servconf.c
+++ b/servconf.c
@@ -10,7 +10,7 @@
10 */ 10 */
11 11
12#include "includes.h" 12#include "includes.h"
13RCSID("$OpenBSD: servconf.c,v 1.98 2002/01/22 02:52:41 stevesk Exp $"); 13RCSID("$OpenBSD: servconf.c,v 1.99 2002/01/27 14:57:46 stevesk Exp $");
14 14
15#if defined(KRB4) || defined(KRB5) 15#if defined(KRB4) || defined(KRB5)
16#include <krb.h> 16#include <krb.h>
@@ -63,6 +63,7 @@ initialize_server_options(ServerOptions *options)
63 options->print_lastlog = -1; 63 options->print_lastlog = -1;
64 options->x11_forwarding = -1; 64 options->x11_forwarding = -1;
65 options->x11_display_offset = -1; 65 options->x11_display_offset = -1;
66 options->x11_use_localhost = -1;
66 options->xauth_location = NULL; 67 options->xauth_location = NULL;
67 options->strict_modes = -1; 68 options->strict_modes = -1;
68 options->keepalives = -1; 69 options->keepalives = -1;
@@ -159,6 +160,8 @@ fill_default_server_options(ServerOptions *options)
159 options->x11_forwarding = 0; 160 options->x11_forwarding = 0;
160 if (options->x11_display_offset == -1) 161 if (options->x11_display_offset == -1)
161 options->x11_display_offset = 10; 162 options->x11_display_offset = 10;
163 if (options->x11_use_localhost == -1)
164 options->x11_use_localhost = 1;
162 if (options->xauth_location == NULL) 165 if (options->xauth_location == NULL)
163 options->xauth_location = _PATH_XAUTH; 166 options->xauth_location = _PATH_XAUTH;
164 if (options->strict_modes == -1) 167 if (options->strict_modes == -1)
@@ -255,7 +258,7 @@ typedef enum {
255 sChallengeResponseAuthentication, 258 sChallengeResponseAuthentication,
256 sPasswordAuthentication, sKbdInteractiveAuthentication, sListenAddress, 259 sPasswordAuthentication, sKbdInteractiveAuthentication, sListenAddress,
257 sPrintMotd, sPrintLastLog, sIgnoreRhosts, 260 sPrintMotd, sPrintLastLog, sIgnoreRhosts,
258 sX11Forwarding, sX11DisplayOffset, 261 sX11Forwarding, sX11DisplayOffset, sX11UseLocalhost,
259 sStrictModes, sEmptyPasswd, sKeepAlives, 262 sStrictModes, sEmptyPasswd, sKeepAlives,
260 sUseLogin, sAllowTcpForwarding, 263 sUseLogin, sAllowTcpForwarding,
261 sAllowUsers, sDenyUsers, sAllowGroups, sDenyGroups, 264 sAllowUsers, sDenyUsers, sAllowGroups, sDenyGroups,
@@ -315,6 +318,7 @@ static struct {
315 { "ignoreuserknownhosts", sIgnoreUserKnownHosts }, 318 { "ignoreuserknownhosts", sIgnoreUserKnownHosts },
316 { "x11forwarding", sX11Forwarding }, 319 { "x11forwarding", sX11Forwarding },
317 { "x11displayoffset", sX11DisplayOffset }, 320 { "x11displayoffset", sX11DisplayOffset },
321 { "x11uselocalhost", sX11UseLocalhost },
318 { "xauthlocation", sXAuthLocation }, 322 { "xauthlocation", sXAuthLocation },
319 { "strictmodes", sStrictModes }, 323 { "strictmodes", sStrictModes },
320 { "permitemptypasswords", sEmptyPasswd }, 324 { "permitemptypasswords", sEmptyPasswd },
@@ -655,6 +659,10 @@ parse_flag:
655 intptr = &options->x11_display_offset; 659 intptr = &options->x11_display_offset;
656 goto parse_int; 660 goto parse_int;
657 661
662 case sX11UseLocalhost:
663 intptr = &options->x11_use_localhost;
664 goto parse_flag;
665
658 case sXAuthLocation: 666 case sXAuthLocation:
659 charptr = &options->xauth_location; 667 charptr = &options->xauth_location;
660 goto parse_filename; 668 goto parse_filename;