From a5e51efff87d828dde6634559a8fbc2f89e086ed Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 26 Aug 2010 14:23:17 +0000 Subject: [PATCH] - Symlink resolution fails when target is a DFS path --- NEWS | 3 ++- TSRM/tsrm_virtual_cwd.c | 6 ++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/NEWS b/NEWS index a902870cd8..357ed744c4 100644 --- a/NEWS +++ b/NEWS @@ -9,7 +9,8 @@ - Added new character sets to mysqlnd, which are available in MySQL 5.5 (Andrey) -- Fixed MOPS-2010-24, fix string validation. (CVE-2010-2950) (Pierre) +- Fixed symbolic resolution support when the target is a DFS share. (Pierre) +- Fixed MOPS-2010-24, fix string validation. (CVE-2010-2950). (Pierre) - Changed deprecated ini options on startup from E_WARNING to E_DEPRECATED. (Kalle) - Changed the $context parameter on copy() to actually have an effect. (Kalle) diff --git a/TSRM/tsrm_virtual_cwd.c b/TSRM/tsrm_virtual_cwd.c index d51e01aa3e..947b22c8f4 100644 --- a/TSRM/tsrm_virtual_cwd.c +++ b/TSRM/tsrm_virtual_cwd.c @@ -811,8 +811,10 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i \\?\Volume{62d1c3f8-83b9-11de-b108-806e6f6e6963}\foo */ if (strncmp(substitutename, "\\??\\Volume{",11) == 0 - || strncmp(substitutename, "\\\\?\\Volume{",11) == 0) { - isVolume = TRUE; + || strncmp(substitutename, "\\\\?\\Volume{",11) == 0 + || strncmp(substitutename, "\\??\\UNC\\", 8) == 0 + ) { + isVolume = TRUE; substitutename_off = 0; } else /* do not use the \??\ and \\?\ prefix*/ -- 2.40.0