Updated to use public key to encrypt uploads