The default ssh keys are fairly secure at default settings. But, you can change the format for the ssh key generation if you're inclined. If you're talking about security for the actual script, you can just set the owner to root which would require root access to read,write, and execute.