[jcifs] Creating file with hash ('#') in filename

Thomas Krammer TKrammer at nxn-software.com
Tue Jan 14 04:06:49 EST 2003


Hi everyone,

I'm trying to create a file with a hash mark ('#') in the filename on a SMB
server. This works fine using the Windows Explorer but fails when I try it
using jCIFS 0.7.0.

When I'm using the SMB URL "smb://server/share/test#1.txt" a file named
"test" is created because the "#1.txt" is interpreted as the fragment part
of the URL.

When I URL encode the hash mark ("smb://server/share/test%231.txt") a file
named "test%231.txt" gets created.

Looking at the "SMB Filesharing URL Scheme" document I didn't find any
information how to encode the path component of the SMB URL.

Did I miss something or is it simply not possible? 


   Thomas





More information about the jcifs mailing list