[BACK]Return to auth.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / ssh

Diff for /src/usr.bin/ssh/auth.c between version 1.30 and 1.31

version 1.30, 2001/11/17 19:14:34 version 1.31, 2001/12/19 07:18:56
Line 220 
Line 220 
                 }                  }
                 if (cp[0] == '%' && cp[1] == 'u') {                  if (cp[0] == '%' && cp[1] == 'u') {
                         buffer_append(&buffer, pw->pw_name,                          buffer_append(&buffer, pw->pw_name,
                              strlen(pw->pw_name));                              strlen(pw->pw_name));
                         cp++;                          cp++;
                         continue;                          continue;
                 }                  }
Line 274 
Line 274 
                 if (options.strict_modes &&                  if (options.strict_modes &&
                     (stat(user_hostfile, &st) == 0) &&                      (stat(user_hostfile, &st) == 0) &&
                     ((st.st_uid != 0 && st.st_uid != pw->pw_uid) ||                      ((st.st_uid != 0 && st.st_uid != pw->pw_uid) ||
                      (st.st_mode & 022) != 0)) {                      (st.st_mode & 022) != 0)) {
                         log("Authentication refused for %.100s: "                          log("Authentication refused for %.100s: "
                             "bad owner or modes for %.200s",                              "bad owner or modes for %.200s",
                             pw->pw_name, user_hostfile);                              pw->pw_name, user_hostfile);
Line 347 
Line 347 
                 if (stat(buf, &st) < 0 ||                  if (stat(buf, &st) < 0 ||
                     (st.st_uid != 0 && st.st_uid != uid) ||                      (st.st_uid != 0 && st.st_uid != uid) ||
                     (st.st_mode & 022) != 0) {                      (st.st_mode & 022) != 0) {
                         snprintf(err, errlen,                          snprintf(err, errlen,
                             "bad ownership or modes for directory %s", buf);                              "bad ownership or modes for directory %s", buf);
                         return -1;                          return -1;
                 }                  }

Legend:
Removed from v.1.30  
changed lines
  Added in v.1.31