[Qt-qml] How to spawn N8 Apps from within QML?
Niels Mayer
nielsmayer at gmail.com
Fri Nov 12 22:27:48 CET 2010
I just thought of a mega-hack version of asynchronous subprocesses
that will be FAR simpler, though with external dependencies on OpenSSH
and the addition of a restricted account/shell for running the
subprocesses. This is a technique I use out of http://xwiki.org java
web platform to invoke specific unix command-line programs from a
"restricted shell" that is invoked via SSH. No need for actual
subprocesses -- all that is needed is code to talk SSH over the
network: e.g. http://xizhizhu.blogspot.com/2010/08/basic-samples-for-ssl-communication.html
and then use hybrid C++/QML technique to make the SSH interface
available from QML.
Since this uses SSH to provide a secure login to execute "subprocess"
code, this is most easily handled passwordless, using SSHD setup to
only accept login with publickey/privkey pairs. By using SSH you also
open up the possibility of controlling remote hardware/systems using
the exact same technique. This makes talking to the "subprocess" no
different, conceptually, than any other client/server asychronous
transactions over the network.
http://lists.xwiki.org/pipermail/users/2009-August/016937.html
contains the groovy code that is invoked from a web-page which invokes
underlying Java functionality to do an SSH connection over network.
http://lists.xwiki.org/pipermail/users/2009-August/016947.html
contains the shell script that serves as a restricted shell for the
account that runs the subrocess.
-- Niels
http://nielsmayer.com
More information about the Qt-qml
mailing list