Improved username validation on server