Use Matrix ID for login

This commit is contained in:
Konstantinos Sideris 2017-04-10 01:47:15 +03:00
parent 87ecb28558
commit 0f3cffcfd9
3 changed files with 14 additions and 14 deletions

View file

@ -17,9 +17,8 @@
#include "InputValidator.h"
// FIXME: Maybe change the regex to match the real Matrix ID format and not email.
InputValidator::InputValidator(QObject *parent)
: matrix_id_("[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,6}")
: matrix_id_("@[A-Za-z0-9._%+-]+:[A-Za-z0-9.-]+\\.[A-Za-z]{2,6}")
, matrix_localpart_("[A-za-z0-9._%+-]{3,}")
, matrix_password_(".{8,}")
, server_domain_("(?!\\-)(?:[a-zA-Z\\d\\-]{0,62}[a-zA-Z\\d]\\.){1,126}(?!\\d+)[a-zA-Z\\d]{1,63}")