[jcifs] Re: SMB URL encoding/decoding
teilo at teilo.net
Sun Feb 24 13:52:53 EST 2002
Michael B Allen wrote:
>On Sun, 24 Feb 2002 02:52:09 +0100
>James Nord <teilo at teilo.net> wrote:
>>by the way,
>>|the example on |http://jcifs.samba.org/src/docs/api/jcifs/smb/SmbFile.html
>> - A relativly sophisticated example that references a file
>>|msmith1|'s desktop as user |Administrator|.
>>Is this not illegal according to the draft?
>I don't think you HAVE to encode everything.
Erm yes you do.
>Its a good idea and a
>necessity to ensure there is no ambiguity. In practice jCIFS does not
>decode anything after the authentication creadentials because requiring
>a user to URL encode their password is just going a little too far I
Why? It is the only way.
do you not do it with http / ftp?
you can get a password from the user in another way and then urlencode
it and then form the smburl.
>And if you decode it at all, you know have to require encoding
>'+' and '%' and yada yada yada. So we search in from the end for '@'
>and don't encode/decode anything before the server.
But then what you do is not what the smb url (generic URL) spec says.
More information about the jcifs