A more thorough analysis revealed that the culprit is the freesshd server which is the one returning a response marked as "bad" (aka the message sent by the client to the server was "malformed"). It's still unclear to me whether this message is the approapriate one in this scenario but in any case it's something that the library cannot do anything about in terms of error reporting. Thusly, Notabug in the ftp lib.
- Dominick