From: David V. <dv...@ad...> - 2011-03-09 20:01:35
|
Hi! On Mon, 2011-03-07 at 11:59 -0800, Eric Wheeler wrote: > [...] > Would you send an example on how you configure your patch? Sure! In all the hurry, I forgot to write about what it does and how it works.. Anyway. Currently, you have the option to configure the following keys: - sshHostKey, which is basically the output of ssh-keyscan - sshPassword can be used to omit the password dialog - Alternatively, you can configure sshUserPublicKey and sshUserPrivateKey as found in ~/.ssh/id_*. I've attached an HTML file that shows how to use this configuration. > [...] > One notable difference between the two applications is that I > developed my application for use as a command-line app, and you > appear to have developed this for a Java Applet. Would you be able > to test my patch on the applet side? Sure! I'm looking forward to it. Hope I get at it on friday. One thing I noted when hacking my patch is that browsers tend to meddle with newlines (and other whitespace) when used in an attribute like <param value="...">. Since Jsch requires at least the newline after the -----BEGIN line for the private key, I decided to escape the newlines with a pipe character. I'm a bit rusty on my java skills, so my current implementation feels hacky at best. I hadn't yet figured out how to properly "fix" the private key string so this wouldn't be neccessary. > > One comment: You might consider using JSch's built-in public/private > key parser. They have already done the work of parsing many different > public/private key formats. Yep, indeed. > Would you compare and contrast your patch to the one I submitted the > other day? So we can compare, these are the contributions of my > earlier patch [ http://tinyurl.com/6gwsbpu ]: > * Supports SSH known_hosts parsing for all formats supported by > JSch > * Supports RSA/DSA key parsing for all formats supported by > JSch > * Prompts for passphrases of encrypted keys > * Abstracts the VNC-SSH configuration interface to easily add > configuration values in the future, simultaneously supporting > Applet and command-line parameters. > > Specifically, I am curious if your patch provides something additional > to the prior patch. If so, it would be great to get the best features > of both patches committed to this project! Absolutely! I didn't have the time yet to actually try your patch, but it looks very promising (and much cleaner than mine :D). The only thing that your patch seems to miss is the escaping thing I mentioned above. Cheers, Dave -- David Vogt, Project Manager & Software Developer adfinis GmbH, Brückfeldstrasse 21, 3012 Bern (Switzerland) Email: dv...@ad..., Web: http://www.adfinis.com Jabber/XMPP: dv...@ja..., Phone: +41 31 381 70 47 |