Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: SSH daemon in Perl?

by perlfan (Curate)
on Jun 22, 2016 at 18:31 UTC ( #1166291=note: print w/replies, xml ) Need Help??


in reply to SSH daemon in Perl?

It seems to me that all you wish to do is use ssh as the means to invoke a remote application, thereby using it as a simple transport or tunnel. I am pretty sure you don't need to do any ssh daemon futzing in Perl, but the remote client would; for example in your link above:

ssh api.example.com multiply a=4 b=5



Replies are listed 'Best First'.
Re^2: SSH daemon in Perl?
by robs87 (Novice) on Jun 22, 2016 at 18:52 UTC

    Thanks for the response.

    I could configure openssh-server to execute a Perl program upon connection, but that would require user accounts on the server. I would also lose a lot of control if the connections were handled by OpenSSH.

    The goal is to create a self-contained Perl program (it's fine if it requires external modules) that listens on port 22. For simplicity, it can be a basic echo server. I'll connect by entering ssh localhost and it will echo back the lines I enter.

      If all you want is a secure layer (and no users) maybe base your application on HTTPS (e.g., using Dancer2 and something like starman) rather than trying to emulate what ssh does.

        It's important that the daemon can be accessed from a standard SSH client, such as the OpenSSH client or PuTTY.

        Go has crypto/ssh, Java has Apache SSHD, Python has Twisted. Are there no similar frameworks for Perl?

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (3)
As of 2020-05-27 03:57 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If programming languages were movie genres, Perl would be:















    Results (152 votes). Check out past polls.

    Notices?