JS login for SMF with non UTF8 encoding