support ssl, make authentication case-insensitive