Refactored RunCommand, Skeleton for Encrypt