#1999 new defect

confusing error message when (S)FTP accounts file has malformed URL

Reported by: zooko Owned by:
Priority: normal Milestone: undecided
Component: code-frontend-ftp-sftp Version: 1.10.0
Keywords: usability error Cc:
Launchpad Bug:

Description

A user on IRC was setting up FUSE↔sshfs↔Tahoe-SFTP-server↔LAFS. He connected to the Tahoe-SFTP-server with the "sftp" client, issued the command "ls", and got this error message:

remote readdir("/"): Permission denied

It finally turned out to be that the dir cap in his accounts file had a trailing "/" character on it. Removing that made the error message go away and the SFTP server start working. To close this ticket, make it so that the error message in a case like this gives the user a clue that something is wrong with the cap.

(This might actually be hard to accomplish, if there isn't a way to send back an arbitrary error message in the SFTP protocol in response to the SFTP client's "ls" command.)

Change History (3)

comment:1 follow-up: Changed at 2013-06-08T09:27:13Z by ClashTheBunny

Why not just handle this in the Tahoe-SFTP server? When would a trailing slash not be good to ignore and just give the user the directory? This isn't an API, this is where we should use heuristics to shield users.

comment:2 in reply to: ↑ 1 Changed at 2013-06-08T13:08:15Z by zooko

Replying to ClashTheBunny:

Why not just handle this in the Tahoe-SFTP server? When would a trailing slash not be good to ignore and just give the user the directory? This isn't an API, this is where we should use heuristics to shield users.

I guess we should have two tickets: one to usefully report malformed caps in the SFTP accounts file, and the other to accept a broader range of plausible caps (e.g. don't mind trailing slashes on dir caps).

comment:3 Changed at 2014-12-02T19:50:22Z by warner

  • Component changed from code-frontend to code-frontend-ftp-sftp
Note: See TracTickets for help on using tickets.