If the programs are adaptable in such a way, you could set them up to run as cgi scripts under Apache. In a typical Apache setup, cgi scripts can be executed but are not visible to the outside world. Of course, other ways of accessing the server (e.g. ftp, ssh, etc.) will have to managed to exclude the unwanted from the cgi directory.