unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Michael Albinus <michael.albinus@gmx.de>
To: Noah Lavine <noah549@gmail.com>
Cc: tramp-devel@gnu.org, emacs-devel@gnu.org
Subject: Re: SCPC Detection Program
Date: Mon, 12 Apr 2010 21:55:45 +0200	[thread overview]
Message-ID: <8739z0wim6.fsf@gmx.de> (raw)
In-Reply-To: <g2x16d22e431004121236wba289bd3g222f297295eb499d@mail.gmail.com> (Noah Lavine's message of "Mon, 12 Apr 2010 15:36:42 -0400")

Noah Lavine <noah549@gmail.com> writes:

> Hi Michael,

Hi Noah,

> I checked with my version of ssh, and we would indeed be able to
> detect this from its help version string. However, it seems like this
> could have similar fragility issues as the version number idea, if the
> help string changed format some time. You could solve this by only
> trying scpc on help strings that are known to be good, but you could
> also have a version number whitelist that would serve the same
> purpose. It seems like both of these would work and would be quite
> similar - is there a reason to think that one would be better than the
> other?

I have no bullet-proof reason. But your version test depends on
underlying OpenSSH, and its version numbering scheme. What if other ssh
implementations will support this option as well? Therefore, the version
check seems to be more fragile to me than the "-M" option. Again, it is
just a feeling.

Another test could be the following:

$ ssh -o ControlMaster=auto wrong-host
ssh: Could not resolve hostname wrong-host: Name or service not known

This would indicate, that the option is supported. Unsupported options
return the following error message:

$ ssh -o ControlMasterr=auto wrong-host
command-line: line 0: Bad configuration option: ControlMasterr

> As for the test connection, maybe a change would help. It's probably
> not good to try connecting to a known-good host, but what about trying
> it with the host that Tramp needs to connect to anyway? You could try
> it first with the -ControlMaster option, and if ssh gave an error,
> then try again without it and fall back on the other method. This
> wouldn't create more ssh connections than necessary. The problem I see
> is that it might require a more substantial change to the Tramp
> codebase than the other methods, but I don't know, because I haven't
> looked around enough to see. Do you think this method would be useful
> enough to make it worth looking through the Tramp code more and maybe
> making bigger changes?

Yes, this would require deeper changes in Tramp's workflow, which I
would like to avoid. And it might discriminate users for whom the test
fails, because they would *always* need to spend the time for that
failed test.

> Noah

Best regards, Michael.




  reply	other threads:[~2010-04-12 19:55 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <x2m16d22e431003311930ob1f64d28t6ea61f44b5131f8e@mail.gmail.com>
2010-04-11 16:19 ` SCPC Detection Program Michael Albinus
2010-04-12 19:06   ` Noah Lavine
2010-04-12 19:18     ` Michael Albinus
2010-04-12 19:36       ` Noah Lavine
2010-04-12 19:55         ` Michael Albinus [this message]
2010-04-13 19:56           ` Noah Lavine
2010-04-13 21:01             ` Michael Albinus
2010-04-14 23:57               ` Noah Lavine
2010-04-15  3:31                 ` Michael Albinus
2010-04-15 23:53                   ` Noah Lavine
2010-04-22 11:24                     ` Michael Albinus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8739z0wim6.fsf@gmx.de \
    --to=michael.albinus@gmx.de \
    --cc=emacs-devel@gnu.org \
    --cc=noah549@gmail.com \
    --cc=tramp-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).