Merge from vendor branch GDB:
[dragonfly.git] / secure / usr.sbin / sshd / servconf.c.patch
1 # $DragonFly: src/secure/usr.sbin/sshd/Attic/servconf.c.patch,v 1.2 2004/08/30 21:59:58 geekgod Exp $
2 --- /home/sullrich/openssh-3.9p1/servconf.c     2004-08-13 11:30:24.000000000 +0000
3 +++ servconf.c  2004-08-20 17:23:25.000000000 +0000
4 @@ -116,7 +116,7 @@
5  
6         /* Standard Options */
7         if (options->protocol == SSH_PROTO_UNKNOWN)
8 -               options->protocol = SSH_PROTO_1|SSH_PROTO_2;
9 +               options->protocol = SSH_PROTO_2;
10         if (options->num_host_key_files == 0) {
11                 /* fill default hostkeys for protocols */
12                 if (options->protocol & SSH_PROTO_1)
13 @@ -124,8 +124,6 @@
14                             _PATH_HOST_KEY_FILE;
15                 if (options->protocol & SSH_PROTO_2) {
16                         options->host_key_files[options->num_host_key_files++] =
17 -                           _PATH_HOST_RSA_KEY_FILE;
18 -                       options->host_key_files[options->num_host_key_files++] =
19                             _PATH_HOST_DSA_KEY_FILE;
20                 }
21         }
22 @@ -142,7 +140,7 @@
23         if (options->key_regeneration_time == -1)
24                 options->key_regeneration_time = 3600;
25         if (options->permit_root_login == PERMIT_NOT_SET)
26 -               options->permit_root_login = PERMIT_YES;
27 +               options->permit_root_login = PERMIT_NO;
28         if (options->ignore_rhosts == -1)
29                 options->ignore_rhosts = 1;
30         if (options->ignore_user_known_hosts == -1)
31 @@ -152,7 +150,7 @@
32         if (options->print_lastlog == -1)
33                 options->print_lastlog = 1;
34         if (options->x11_forwarding == -1)
35 -               options->x11_forwarding = 0;
36 +               options->x11_forwarding = 1;
37         if (options->x11_display_offset == -1)
38                 options->x11_display_offset = 10;
39         if (options->x11_use_localhost == -1)
40 @@ -272,6 +270,7 @@
41         sClientAliveCountMax, sAuthorizedKeysFile, sAuthorizedKeysFile2,
42         sGssAuthentication, sGssCleanupCreds, sAcceptEnv,
43         sUsePrivilegeSeparation,
44 +       sVersionAddendum,
45         sDeprecated, sUnsupported
46  } ServerOpCodes;
47  
48 @@ -371,6 +370,7 @@
49         { "authorizedkeysfile", sAuthorizedKeysFile },
50         { "authorizedkeysfile2", sAuthorizedKeysFile2 },
51         { "useprivilegeseparation", sUsePrivilegeSeparation},
52 +       { "versionaddendum", sVersionAddendum },
53         { "acceptenv", sAcceptEnv },
54         { NULL, sBadOption }
55  };
56 @@ -915,6 +915,13 @@
57                 }
58                 break;
59  
60 +       case sVersionAddendum:
61 +                ssh_version_set_addendum(strtok(cp, "\n"));
62 +                do {
63 +                        arg = strdelim(&cp);
64 +                } while (arg != NULL && *arg != '\0');
65 +               break;
66 +
67         case sDeprecated:
68                 logit("%s line %d: Deprecated option %s",
69                     filename, linenum, arg);