Thank you very much Paul, I'll give it a try and I'll post any change, I'm really grateful... but giving it an overview, I think you are not executing the commands the way I want, when you pass a list of commands on the Dashboard 
<span style="font-weight: bold;">(</span>self.run_commands(&quot;myhost&quot;, &quot;myusername&quot;, &quot;mypassword&quot;, [&quot;id&quot;, &quot;pwd&quot;, &quot;ls -l&quot;])<span style="font-weight: bold;">) </span>
you are running it asynchronously (the way I&#39;m getting it, I mean, the three commands are passed to the CommandChannel class, and then they gets run, and later they return it&#39;s data), I need to run commands from the GUI, without previously knowing what commands will the user want to run (the normal GUI interaction), and avoiding to all cost to authenticate for each command (that&#39;s because some networks that my tool will connect takes too long to authenticate ssh connections, but once they are authenticated, they works just fine).
<br><br>But thanks again Paul, if you want a suggestion on your code, I think (but I&#39;m not sure) you can get rid of a lot of code if you implement something like I have (see below, in the answer to Jean-Paul), if you iterate on the list of command, you can change the raw_input() with something like this:
<br><br>for cmd in self.cmds:<br>&nbsp;&nbsp;&nbsp; self.requestService(PasswordAuth(self.username, self.password, ClientConnection(cmd)))<br><br>Just a suggestion, hope that helps...<br><br><br><div><span class="gmail_quote">On 10/9/07, 
<b class="gmail_sendername"><a href="mailto:Paul_S_Johnson@mnb.uscourts.gov">Paul_S_Johnson@mnb.uscourts.gov</a></b> &lt;<a href="mailto:Paul_S_Johnson@mnb.uscourts.gov">Paul_S_Johnson@mnb.uscourts.gov</a>&gt; wrote:</span>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br><font face="sans-serif" size="2">Raul,</font>
<br>
<br><font face="sans-serif" size="2">This is simply some work-in-progress
code, but is basically what you are looking for even written for PythonCard.
This takes a list of three commands and runs them in the order given using
deferreds to wait for the previous to complete before executing the next.</font>
<br>
<br><font face="sans-serif" size="2">This took me about forever to get it
this far. If you make and significant improvements, please share.</font>
<br>
<br><font face="sans-serif" size="2">One remaining mystery is how to switch
users once logged in. For example, I need to run some things as root.</font>
<br>
<br><font face="sans-serif" size="2">Paul</font>
<br>
</blockquote></div><br><br>Jean-Paul, is not easy to post only a small working (by itself) part of
what I&#39;m trying to do, is the <a href="http://www.ora.de/catalog/twistedadn/chapter/ch10.pdf">sshclient.py (example 10-4)</a> of the <span style="font-style: italic;">Twisted Network Programming Essentials</span>          Book by Abe Fettig (based on the 
sshsimpleclient.py by Paul Swartz), but modified in order ask for the command when the ClientConnection class is called in the ClientCommandTransport class, like this:<br><br><br>class ClientCommandTransport(transport.SSHClientTransport
):<br><br>&nbsp;&nbsp;&nbsp; def __init__(self, username, password):<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; self.username = username<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; self.password = password<br><br>&nbsp;&nbsp;&nbsp; def verifyHostKey(self, pubKey, fingerprint):<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; # in a real app, you should verify that the fingerprint matches
<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; # the one you expected to get from this server<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; return defer.succeed(True)<br><br>&nbsp;&nbsp;&nbsp; def connectionSecure(self):<br><span style="font-weight: bold;">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; cmd= &#39;&#39;</span><br style="font-weight: bold;">
<span style="font-weight: bold;">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; while True:</span><br style="font-weight: bold;"><span style="font-weight: bold;">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; cmd = raw_input(&#39;Command: &#39;)</span><br style="font-weight: bold;"><span style="font-weight: bold;">
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; if cmd != &#39;quit&#39;:</span><br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; self.requestService(PasswordAuth(self.username, self.password, ClientConnection(cmd)))<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <span style="font-weight: bold;">else:</span><br style="font-weight: bold;">
<span style="font-weight: bold;">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; print &#39;\nGood Bye!\n&#39;</span><br style="font-weight: bold;"><span style="font-weight: bold;">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; break</span><br><br>Note: the <span style="font-weight: bold;">
Bold</span> part is what I&#39;ve added to the original code<br><br><br>PD: I think Paul is a popular name in this list :p<br>