Maybe you should use a VM to run your restricted applications. Or have a look a chroot, dchroot or schroot, to setup such stuff. The Programming Language will not help you in this case!