Improve Encryption process + cross-site scripting vulnerability fix