Fossil SCM
Change the default ssh command to just be "ssh" and then unequivocally add "-e none" to each ssh-command (default or overridden) as mentioned in [forum:667d59587b90c4c6 | forum post 667d59587b90c4c6]. It's arguable that if ssh-command has been specified that no modifications should be done to it at all. In which case this commit should be backed out and the default command should be made to include "-T" as well.
Commit
b537eeef058e96697372e1148284974057de3b1ae65706e6d5bfea3716d64845
Parent
25857ebba518011…
1 file changed
+2
-2
+2
-2
| --- src/http_transport.c | ||
| +++ src/http_transport.c | ||
| @@ -95,11 +95,11 @@ | ||
| 95 | 95 | ** Default SSH command |
| 96 | 96 | */ |
| 97 | 97 | #if 0 /* was: defined(_WIN32). Windows generally has ssh now. */ |
| 98 | 98 | static const char zDefaultSshCmd[] = "plink -ssh"; |
| 99 | 99 | #else |
| 100 | -static const char zDefaultSshCmd[] = "ssh -e none"; | |
| 100 | +static const char zDefaultSshCmd[] = "ssh"; | |
| 101 | 101 | #endif |
| 102 | 102 | |
| 103 | 103 | /* |
| 104 | 104 | ** Initialize a Blob to the name of the configured SSH command. |
| 105 | 105 | */ |
| @@ -126,11 +126,11 @@ | ||
| 126 | 126 | g.zIpAddr = mprintf("%s", pUrlData->name); |
| 127 | 127 | transport_ssh_command(&zCmd); |
| 128 | 128 | if( pUrlData->port!=pUrlData->dfltPort && pUrlData->port ){ |
| 129 | 129 | blob_appendf(&zCmd, " -p %d", pUrlData->port); |
| 130 | 130 | } |
| 131 | - blob_appendf(&zCmd, " -T --"); /* End of switches */ | |
| 131 | + blob_appendf(&zCmd, " -e none -T --"); /* End of switches */ | |
| 132 | 132 | if( pUrlData->user && pUrlData->user[0] ){ |
| 133 | 133 | zHost = mprintf("%s@%s", pUrlData->user, pUrlData->name); |
| 134 | 134 | blob_append_escaped_arg(&zCmd, zHost, 0); |
| 135 | 135 | fossil_free(zHost); |
| 136 | 136 | }else{ |
| 137 | 137 |
| --- src/http_transport.c | |
| +++ src/http_transport.c | |
| @@ -95,11 +95,11 @@ | |
| 95 | ** Default SSH command |
| 96 | */ |
| 97 | #if 0 /* was: defined(_WIN32). Windows generally has ssh now. */ |
| 98 | static const char zDefaultSshCmd[] = "plink -ssh"; |
| 99 | #else |
| 100 | static const char zDefaultSshCmd[] = "ssh -e none"; |
| 101 | #endif |
| 102 | |
| 103 | /* |
| 104 | ** Initialize a Blob to the name of the configured SSH command. |
| 105 | */ |
| @@ -126,11 +126,11 @@ | |
| 126 | g.zIpAddr = mprintf("%s", pUrlData->name); |
| 127 | transport_ssh_command(&zCmd); |
| 128 | if( pUrlData->port!=pUrlData->dfltPort && pUrlData->port ){ |
| 129 | blob_appendf(&zCmd, " -p %d", pUrlData->port); |
| 130 | } |
| 131 | blob_appendf(&zCmd, " -T --"); /* End of switches */ |
| 132 | if( pUrlData->user && pUrlData->user[0] ){ |
| 133 | zHost = mprintf("%s@%s", pUrlData->user, pUrlData->name); |
| 134 | blob_append_escaped_arg(&zCmd, zHost, 0); |
| 135 | fossil_free(zHost); |
| 136 | }else{ |
| 137 |
| --- src/http_transport.c | |
| +++ src/http_transport.c | |
| @@ -95,11 +95,11 @@ | |
| 95 | ** Default SSH command |
| 96 | */ |
| 97 | #if 0 /* was: defined(_WIN32). Windows generally has ssh now. */ |
| 98 | static const char zDefaultSshCmd[] = "plink -ssh"; |
| 99 | #else |
| 100 | static const char zDefaultSshCmd[] = "ssh"; |
| 101 | #endif |
| 102 | |
| 103 | /* |
| 104 | ** Initialize a Blob to the name of the configured SSH command. |
| 105 | */ |
| @@ -126,11 +126,11 @@ | |
| 126 | g.zIpAddr = mprintf("%s", pUrlData->name); |
| 127 | transport_ssh_command(&zCmd); |
| 128 | if( pUrlData->port!=pUrlData->dfltPort && pUrlData->port ){ |
| 129 | blob_appendf(&zCmd, " -p %d", pUrlData->port); |
| 130 | } |
| 131 | blob_appendf(&zCmd, " -e none -T --"); /* End of switches */ |
| 132 | if( pUrlData->user && pUrlData->user[0] ){ |
| 133 | zHost = mprintf("%s@%s", pUrlData->user, pUrlData->name); |
| 134 | blob_append_escaped_arg(&zCmd, zHost, 0); |
| 135 | fossil_free(zHost); |
| 136 | }else{ |
| 137 |