Protecting your scripts is not gonna be much use if you don't secure the server first. Firewalls, access rights, etc should all be addressed first before even worrying about the scripts.
The last thing you need is your machine being used to send spam or virus'.
Linux has great capabilties in securing the server via all sorts of features. There are also others to turn off, like finger, FTP, telnet (if they are not being used. Disable ports not being used etc...
That is the best place to start