Hi All,
I am using Commons Net 1.4.0 and seeing this problem with a particular FTP
server. I am connecting to the FTP server using the commons net API and
frequently get the MalformedServerReplyException. On looking at the commons
net FTP.java source file, I see that it is caused because we were unable to
parse the server reply "27 Entering Passive Mode". The expected response
code is "227 Entering Passive Mode". The code:
            String code = line.substring(0, 3);
            _replyCode = Integer.parseInt(code);
        catch (NumberFormatException e)
            throw new MalformedServerReplyException(
                "Could not parse response code.\nServer Reply: " + line);

Clearly, substring 0,3 will yeild "27 " which is probably causing the
exception. I telnetted to the offending server on the FTP port but was not
able to get the "27" instead of "227" error code. Anyone seen this problem ?
Is this a problem with the commons net library or am I doing something wrong
? Thanks,


The FTP server administrator is not able to reproduce the issue and a m
View this message in context: 
Sent from the Commons - User mailing list archive at Nabble.com.

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to