Add so security checks.

Check owner and permissions for a loaded so file.