There's so many different ways to get the password in the mount.cifs.c sources that I wouldn't be surprised if one path works fine while another path fails this way.
For those who can test this, it would be nice to test mount -t cifs vs calling mount.cifs directly, and it'd be worth testing the PASSWD environment variable, the PASSWD_FD environment variable, the PASSWD_FILE environment variable, the --pass and --password and -p command line options, the systemd-ask-password prompt, the getpass() password prompt, the credentials file.
The kernel sources also appears to log unknown options only if "sloppy" isn't being used:
if (!sloppy && invalid) { pr_err("CIFS: Unknown mount option \"%s\"\n", invalid); goto cifs_parse_mount_err;
}
so be sure to test with and without sloppy to make sure you're testing the right thing.
There's so many different ways to get the password in the mount.cifs.c sources that I wouldn't be surprised if one path works fine while another path fails this way.
For those who can test this, it would be nice to test mount -t cifs vs calling mount.cifs directly, and it'd be worth testing the PASSWD environment variable, the PASSWD_FD environment variable, the PASSWD_FILE environment variable, the --pass and --password and -p command line options, the systemd- ask-password prompt, the getpass() password prompt, the credentials file.
The kernel sources also appears to log unknown options only if "sloppy" isn't being used:
pr_err( "CIFS: Unknown mount option \"%s\"\n", invalid);
goto cifs_parse_ mount_err;
if (!sloppy && invalid) {
}
so be sure to test with and without sloppy to make sure you're testing the right thing.
Thanks