mooli tayer has posted comments on this change. Change subject: core: replace regexp validation for user email. ......................................................................
Patch Set 2: (3 comments) http://gerrit.ovirt.org/#/c/28742/2//COMMIT_MSG Commit Message: Line 9: validating using an ad-hock regexp may cause problems(see bug). Line 10: using strinct java.mail.internetAddress() [1] for validation. Line 11: This enforces some (but not all) RFC822 syntax. Line 12: Line 13: Using the strict form does not allow simple (user )names but will change to: simple names (e.g 'user') but Line 14: requires a domain although user@localhost is now accepted. Line 15: Line 16: [1] https://javamail.java.net/nonav/docs/api/ Line 17: Line 10: using strinct java.mail.internetAddress() [1] for validation. Line 11: This enforces some (but not all) RFC822 syntax. Line 12: Line 13: Using the strict form does not allow simple (user )names but Line 14: requires a domain although user@localhost is now accepted. will change to: requires a domain. 'user@localhost' is now accepted. Line 15: Line 16: [1] https://javamail.java.net/nonav/docs/api/ Line 17: Line 18: Change-Id: I18904a669453baef632af1cd427b61852e7ab583 http://gerrit.ovirt.org/#/c/28742/2/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/EventSubscriptionCommandBase.java File backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/EventSubscriptionCommandBase.java: Line 150: */ Line 151: protected static boolean isEmailValid(String email) { Line 152: boolean valid = false; Line 153: try { Line 154: if (email == null){ empty email is checked by InternetAddress Line 155: throw new AddressException(); Line 156: } Line 157: new InternetAddress(email, true); Line 158: valid = true; -- To view, visit http://gerrit.ovirt.org/28742 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I18904a669453baef632af1cd427b61852e7ab583 Gerrit-PatchSet: 2 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: mooli tayer <[email protected]> Gerrit-Reviewer: Alon Bar-Lev <[email protected]> Gerrit-Reviewer: Martin Peřina <[email protected]> Gerrit-Reviewer: Oved Ourfali <[email protected]> Gerrit-Reviewer: [email protected] Gerrit-Reviewer: mooli tayer <[email protected]> Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
