Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re^4: Net::SSH2 and Trapeze, in-band authentication

by FloydATC (Chaplain)
on Apr 05, 2013 at 12:07 UTC ( #1027129=note: print w/ replies, xml ) Need Help??


in reply to Re^3: Net::SSH2 and Trapeze, in-band authentication
in thread Net::SSH2 and Trapeze, in-band authentication

Yes, the data is indeed delayed and the non-blocking call does return undef every now and then. This is why I call get_channel() repeatedly from get_response() and accumulate the results until I see the prompt.

The reason I can't do blocking calls is because the channel will never EOF or return a short buffer unless I tell the host to "exit" and terminate the connection. Not cool if I want to execute more commands based on the output from a previous command.

-- Time flies when you don't know what you're doing


Comment on Re^4: Net::SSH2 and Trapeze, in-band authentication

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1027129]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (10)
As of 2014-12-22 04:30 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (110 votes), past polls