fix permissions in uploaded key file