The code in main.c causes rsh/ssh to fail if there is an "@" in the 
login name

e.g. 
  username: [EMAIL PROTECTED]
  host: shell.isp.net

=>
  rsync foo [EMAIL PROTECTED]@shell.isp.net:

tries to log in with 
 rsh -l fulano [EMAIL PROTECTED]
or even worse with -e ssh
 ssh -l fulano [EMAIL PROTECTED]
ssh ignores the -l option and uses 'mydomain.net' as the username

The fix is simple: use the last "@" as the delimiter instead of the 
first "@". (RFC 1035 does not allow "@" in domain names.)

--- main.c~     Tue Mar 26 21:10:44 2002
+++ main.c      Wed Aug 21 13:47:40 2002
@@ -743,7 +743,7 @@
        }

        if (shell_machine) {
-               p = strchr(shell_machine,'@');
+               p = strrchr(shell_machine,'@');
                if (p) {
                        *p = 0;
                        shell_user = shell_machine;


-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html

Reply via email to