Fixed login encryption bug