summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog3
-rw-r--r--auth.c9
2 files changed, 6 insertions, 6 deletions
diff --git a/ChangeLog b/ChangeLog
index 4e08289d6..04544286c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -10,6 +10,9 @@
10 entierly :) 10 entierly :)
11 11
12 feedback and ok markus@ dtucker@ 12 feedback and ok markus@ dtucker@
13 - djm@cvs.openbsd.org 2011/05/23 03:33:38
14 [auth.c]
15 make secure_filename() spam debug logs less
13 16
1420110520 1720110520
15 - (djm) [session.c] call setexeccon() before executing passwd for pw 18 - (djm) [session.c] call setexeccon() before executing passwd for pw
diff --git a/auth.c b/auth.c
index cac12b2e7..cd95da931 100644
--- a/auth.c
+++ b/auth.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: auth.c,v 1.93 2011/05/23 03:30:07 djm Exp $ */ 1/* $OpenBSD: auth.c,v 1.94 2011/05/23 03:33:38 djm Exp $ */
2/* 2/*
3 * Copyright (c) 2000 Markus Friedl. All rights reserved. 3 * Copyright (c) 2000 Markus Friedl. All rights reserved.
4 * 4 *
@@ -456,7 +456,6 @@ secure_filename(FILE *f, const char *file, struct passwd *pw,
456 } 456 }
457 strlcpy(buf, cp, sizeof(buf)); 457 strlcpy(buf, cp, sizeof(buf));
458 458
459 debug3("secure_filename: checking '%s'", buf);
460 if (stat(buf, &st) < 0 || 459 if (stat(buf, &st) < 0 ||
461 (st.st_uid != 0 && st.st_uid != uid) || 460 (st.st_uid != 0 && st.st_uid != uid) ||
462 (st.st_mode & 022) != 0) { 461 (st.st_mode & 022) != 0) {
@@ -466,11 +465,9 @@ secure_filename(FILE *f, const char *file, struct passwd *pw,
466 } 465 }
467 466
468 /* If are past the homedir then we can stop */ 467 /* If are past the homedir then we can stop */
469 if (comparehome && strcmp(homedir, buf) == 0) { 468 if (comparehome && strcmp(homedir, buf) == 0)
470 debug3("secure_filename: terminating check at '%s'",
471 buf);
472 break; 469 break;
473 } 470
474 /* 471 /*
475 * dirname should always complete with a "/" path, 472 * dirname should always complete with a "/" path,
476 * but we can be paranoid and check for "." too 473 * but we can be paranoid and check for "." too