Bug 667 - msdfs links with uppercase chars broken.
Summary: msdfs links with uppercase chars broken.
Alias: None
Product: Samba 3.0
Classification: Unclassified
Component: File Services (show other bugs)
Version: 3.0.0
Hardware: Other other
: P3 critical
Target Milestone: none
Assignee: Jeremy Allison
QA Contact:
Depends on:
Reported: 2003-10-22 06:22 UTC by Volker Lendecke
Modified: 2005-08-24 10:23 UTC (History)
0 users

See Also:

Proposed DFS case patch. (18.08 KB, patch)
2003-10-24 18:30 UTC, Jeremy Allison
no flags Details
init localpath in resolve_dfs_path (322 bytes, patch)
2003-10-26 10:10 UTC, Volker Lendecke
no flags Details
Better patch. (12.14 KB, patch)
2003-10-27 16:48 UTC, Jeremy Allison
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Volker Lendecke 2003-10-22 06:22:41 UTC
Short version: What does msdfs.c:175 do???

Long version: If you have directories with upper-case file names
in them, you will never be able to store DFS links in there, because
is_msdfs_link will not find that link due to a strlower_m on the path.

Comment 1 Jeremy Allison 2003-10-22 14:08:05 UTC
It's a stupid bug. I'm going to remove this line. I can't see why these
names are lowercased at all.
Comment 2 Jeremy Allison 2003-10-24 16:16:18 UTC
Hmmm. This is much trickier to fix than it looks - involves unix_convert
and also the statcache....
Comment 3 Jeremy Allison 2003-10-24 18:29:46 UTC
Ok, I have a proposed patch for this (attached). Volker, can you
test this ?

Comment 4 Jeremy Allison 2003-10-24 18:30:13 UTC
Created attachment 223 [details]
Proposed DFS case patch.
Comment 5 Volker Lendecke 2003-10-26 10:10:03 UTC
Created attachment 224 [details]
init localpath in resolve_dfs_path

localpath in resolve_dfs_path is used uninitialized with your patch. Also apply
the attached patch, and my brief test works fine.

Thanks for looking at that!

Comment 6 Jeremy Allison 2003-10-27 09:38:07 UTC
Volker, that fix is wrong, the correct fix is to change the pstrcat
to pstrcpy below. However, this whole patch is somewhat suspect. I've
been thinking about it over the weekend and I have a much simpler fix
I'm testing.
Comment 7 Jeremy Allison 2003-10-27 16:47:53 UTC
Ok, Volker, please test this much simpler fix against current SAMBA_3_0
CVS. I'm pretty sure it's ok, so I'm inclined to commit it.
Comment 8 Jeremy Allison 2003-10-27 16:48:54 UTC
Created attachment 227 [details]
Better patch.

Better patch. I think I will commit this.
Comment 9 Jeremy Allison 2003-10-27 16:51:47 UTC
I've committed the patch. I think it's ok (seems to be in my testing).
Comment 10 Gerald (Jerry) Carter (dead mail address) 2005-08-24 10:23:22 UTC
sorry for the same, cleaning up the database to prevent unecessary reopens of bugs.