Re: Java program testing
 
On Sat, 11 Apr 2009, Marek Staniewski wrote:
I would like to give my Java program for testing to some people. But I 
look for the ay to avoid that the program is copied and redistributed 
further.
Is it possible someway to put the program in some virtual machine and 
run the program from any place in internet?
Could it be eventually copied by smoeone?
What's the interface to your application?
If it's a web application, run it on your machine and open a port for 
HTTP, or ideally HTTPS, perhaps using Apache to terminate the HTTPS 
connection from the outside world and do authentication, and then forward 
requests to your app over HTTP.
If it's a command-line application and is used interactively, and the user 
doesn't need command-line access to other commands (eg to manipulate 
files), then have them generate an SSH key pair and send you the public 
key, create an account for them on the machine, create an authorized_keys 
file for it using the public key, and use the command= directive to 
restrict that login to only be able to run your program (via a wrapper 
shell script).
If it's a command-line application but needs to be used in the context of 
a shell (eg so files can be edited), that's actually a lot harder. Get 
back to me if you need that!
If it's a GUI application, have them run an X window server on their 
machine, set your DISPLAY variable to point to their machine, and run it 
on your machine - it will start a GUI on their machine. You can combine 
this with the authorized-keys trick above to let them get the X forwarded 
over an ssh connection, and let them run the app on demand.
In all of the above, you could substitute 'virtual machine in the cloud' 
for 'your machine', and i assume the machine is running a sensible 
operating system, ie unix.
Basically, this isn't a java problem, it's a system administration 
problem. You might get a better answer on a sysadmin group.
tom
-- 
Christ. This isn't just straight to video, it's straight to Google
Video. -- UKR, on the DoA movie