Secure access to files and network resources