Return-Path: X-Original-To: apmail-allura-dev-archive@www.apache.org Delivered-To: apmail-allura-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 4D05317BE9 for ; Thu, 19 Mar 2015 18:34:14 +0000 (UTC) Received: (qmail 45927 invoked by uid 500); 19 Mar 2015 18:34:04 -0000 Delivered-To: apmail-allura-dev-archive@allura.apache.org Received: (qmail 45905 invoked by uid 500); 19 Mar 2015 18:34:04 -0000 Mailing-List: contact dev-help@allura.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@allura.apache.org Delivered-To: mailing list dev@allura.apache.org Received: (qmail 45894 invoked by uid 99); 19 Mar 2015 18:34:04 -0000 Received: from allura-vm.apache.org (HELO allura-vm) (140.211.11.147) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 19 Mar 2015 18:34:04 +0000 Received: from allura-vm.apache.org (localhost [127.0.0.1]) by allura-vm (Postfix) with ESMTP id 45C2828001D for ; Thu, 19 Mar 2015 18:34:04 +0000 (UTC) Content-Type: multipart/related; boundary="===============7654097924812832135==" MIME-Version: 1.0 To: dev@allura.apache.org From: "Heith Seewald" Reply-To: "[allura:tickets] " <7833@tickets.allura.p.forge-allura.apache.org> Subject: [allura:tickets] #7833 Trim emails before saving them to mongo Message-ID:

Sender: tickets@allura.p.forge-allura.apache.org In-Reply-To: <54dcb24d6d19cd2c62308897.tickets@allura.p.forge-allura.apache.org> References: <54dcb24d6d19cd2c62308897.tickets@allura.p.forge-allura.apache.org> Date: Thu, 19 Mar 2015 18:34:04 +0000 (UTC) --===============7654097924812832135== Content-Type: multipart/alternative; boundary="===============6194474419278247742==" MIME-Version: 1.0 --===============6194474419278247742== MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit - **Reviewer**: Heith Seewald --- ** [tickets:#7833] Trim emails before saving them to mongo** **Status:** review **Milestone:** unreleased **Labels:** 42cc sf-2 sf-current **Created:** Thu Feb 12, 2015 02:01 PM UTC by Igor Bondarenko **Last Updated:** Mon Mar 16, 2015 09:56 AM UTC **Owner:** Igor Bondarenko Right now you can claim address like `"email@example.com "` (note spaces in the end) or even `"email@example.com\t"` (tab in the end, you can't type this but can copy&paste from some source. That's how I discovered this issue actually). That's a problem because on the UI you can't see this blank symbols and later, when user types the same email in, say, password recovery form, but without spaces in the end, system will not find it, therefore user will not be able to recover password. Also, association of commits with users and other stuff won't work. Probably fix is as simple as adding `.strip()` inside `EmailAddress.canonical`, since we use it everywhere already, but it's good to test/investigate further. Don't sure what to do with existing emails like this which are already in mongo. --- Sent from forge-allura.apache.org because dev@allura.apache.org is subscribed to https://forge-allura.apache.org/p/allura/tickets/ To unsubscribe from further messages, a project admin can change settings at https://forge-allura.apache.org/p/allura/admin/tickets/options. Or, if this is a mailing list, you can unsubscribe from the mailing list. --===============6194474419278247742== MIME-Version: 1.0 Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: 7bit
  • Reviewer: Heith Seewald

[tickets:#7833] Trim emails before saving them to mongo

Status: review
Milestone: unreleased
Labels: 42cc sf-2 sf-current
Created: Thu Feb 12, 2015 02:01 PM UTC by Igor Bondarenko
Last Updated: Mon Mar 16, 2015 09:56 AM UTC
Owner: Igor Bondarenko

Right now you can claim address like "email@example.com " (note spaces in the end) or even "email@example.com\t" (tab in the end, you can't type this but can copy&paste from some source. That's how I discovered this issue actually).

That's a problem because on the UI you can't see this blank symbols and later, when user types the same email in, say, password recovery form, but without spaces in the end, system will not find it, therefore user will not be able to recover password. Also, association of commits with users and other stuff won't work.

Probably fix is as simple as adding .strip() inside EmailAddress.canonical, since we use it everywhere already, but it's good to test/investigate further.

Don't sure what to do with existing emails like this which are already in mongo.


Sent from forge-allura.apache.org because dev@allura.apache.org is subscribed to https://forge-allura.apache.org/p/allura/tickets/

To unsubscribe from further messages, a project admin can change settings at https://forge-allura.apache.org/p/allura/admin/tickets/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.

--===============6194474419278247742==-- --===============7654097924812832135==--