[prev in list] [next in list] [prev in thread] [next in thread] 

List:       proftpd-committers
Subject:    [ProFTPD-committers] proftpd/src fsio.c,1.102.2.2,1.102.2.3
From:       TJ Saunders <castaglia () users ! sourceforge ! net>
Date:       2012-12-29 0:11:51
Message-ID: E1Tok1p-0006FU-6E () sfs-ml-2 ! v29 ! ch3 ! sourceforge ! com
[Download RAW message or body]

Update of /cvsroot/proftp/proftpd/src
In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv2325/src

Modified Files:
      Tag: B1_3_4
	fsio.c 
Log Message:

Backporting fix from trunk.


Index: fsio.c
===================================================================
RCS file: /cvsroot/proftp/proftpd/src/fsio.c,v
retrieving revision 1.102.2.2
retrieving revision 1.102.2.3
diff -u -d -r1.102.2.2 -r1.102.2.3
--- fsio.c	28 Dec 2012 00:03:27 -0000	1.102.2.2
+++ fsio.c	29 Dec 2012 00:11:49 -0000	1.102.2.3
@@ -2,7 +2,7 @@
  * ProFTPD - FTP server daemon
  * Copyright (c) 1997, 1998 Public Flood Software
  * Copyright (C) 1999, 2000 MacGyver aka Habeeb J. Dihu <macgyver@tos.net>
- * Copyright (C) 2001-2011 The ProFTPD Project
+ * Copyright (C) 2001-2012 The ProFTPD Project
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -2503,7 +2503,7 @@
   return res;
 }
 
-/* "secure mkdir" variant of mkdir(2), uses mkdtemp(3), lchown(2), and
+/* "safe mkdir" variant of mkdir(2), uses mkdtemp(3), lchown(2), and
  * rename(2) to create a directory which cannot be hijacked by a symlink
  * race (hopefully) before the UserOwner/GroupOwner ownership changes are
  * applied.
@@ -2537,7 +2537,8 @@
     return -1;
   }
 
-  if (!S_ISDIR(st.st_mode)) {
+  if (!S_ISDIR(st.st_mode) &&
+      !S_ISLNK(st.st_mode)) {
     errno = EPERM;
     return -1;
   }


------------------------------------------------------------------------------
Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS,
MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current
with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft
MVPs and experts. SALE $99.99 this month only -- learn more at:
http://p.sf.net/sfu/learnmore_122912
_______________________________________________
ProFTPD Committers Mailing List
proftpd-committers@proftpd.org
https://lists.sourceforge.net/lists/listinfo/proftp-committers
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic