Public bug reported:
If sshfs is called with the "password_stdin" option (for example, when
invoked with pam_mount) it will refuse to accept a password longer than
64 characters.
The limit is hardcoded in the sshfs.c file (line 3069 in version 2.3,
line 3466 in version 2.5) with the variable named "max_password".
To reproduce, from the command-line you can use for example:
sshfs mvaldez@servername:/home/mvaldez/SHARE ./myfiles -o
"reconnect,idmap=user,password_stdin"
then type the password (sshfs will wait for the password from stdin
without prompt) and press Enter. If the password is longer than 64
characters it will fail with the message: "Password too long".
When used with pam_mount, the logs in /var/log/auth.log show the following
messages:
pam_mount(mount.c:69): Messages from underlying mount program:
pam_mount(mount.c:73): Password too long
pam_mount(pam_mount.c:521): mount of
sshfs#mvaldez@servername:/home/mvaldez/SHARE failed
This limit seems to be inherited from the first patches sent to the sshfs-fuse
project (around 2008) for the password_stdin option, but it seems to be
arbitrary. I have successfully changed the limit to 1024 without problems.
Also, the function "read_password" which is used to capture the password from
stdin is only used when using the "password_stdin" option (so any change in the
allowed length won't affect any other part of the program).
This tests were done in Ubuntu 12.04.5 LTS but the limit is the same up
to the latest sshfs-fuse version (2.5).
** Affects: sshfs-fuse (Ubuntu)
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1406840
Title:
sshfs cannot handle passwords longer than 64 characters from stdin
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/sshfs-fuse/+bug/1406840/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs