There are many commercial applications available that does similar to what you want. Try googling for "exe encryptor".
But, in reality, none of them is 100% secure.