[jcifs] Re: Null pointer exception in ServerMessageBlock.java

Jake Goulding goulding at vivisimo.com
Wed Jun 21 18:08:25 GMT 2006


 From the URL JavaDoc:
> The |URLEncoder| 
> <http://java.sun.com/j2se/1.5.0/docs/api/java/net/URLEncoder.html> and 
> |URLDecoder| 
> <http://java.sun.com/j2se/1.5.0/docs/api/java/net/URLDecoder.html> 
> classes can also be used, but only for HTML form encoding, which is 
> not the same as the encoding scheme defined in RFC2396.
So I think that these classes are for something different than the 
encoding needed here... am I wrong?

Levi Purvis wrote:
> Or just use java.net.URLEncoder...
>
> http://java.sun.com/j2se/1.5.0/docs/api/java/net/URLEncoder.html
>
> On 6/21/06, Ronny Schuetz <Usenet.8d3 at gishpuppy.com> wrote:
>> * Jake Goulding wrote:
>>
>> Hi,
>>
>> > Obviously, this is not right... the question is where does this 
>> need to
>> > be fixed? Do I need to make sure that the user/domain/password are
>> > encoded before passing them off to JCIFS? Does JCIFS need to better
>> > support this? Am I not "allowed" to have a hash in my password?
>>
>> Try to URL-encode the username and password before using them to build
>> the URL. The jakarta commons codec library [1] offers the required
>> functionality for example.
>>
>> [1] http://jakarta.apache.org/commons/codec/
>>
>> Ronny
>>
>>
>

-- 
Jake Goulding
Software Engineer
Vivísimo, Inc.

"One of the main causes of the fall of the Roman Empire was that,
lacking zero, they had no way to indicate successful termination
of their C programs."



More information about the jcifs mailing list