[PATCH conductor] BZ-863465 username can contain only characters and numbers

Tomas Hrcka thrcka at redhat.com
Mon Oct 8 15:33:11 UTC 2012


On Mon, 2012-10-08 at 11:16 -0400, Matt Wagner wrote:
> On Mon, Oct 08, 2012 at 02:00:14PM +0200, Tomáš Hrčka wrote:
> > +  validates_format_of :username, :with => /[a-z0-9A-Z]/, :message => I18n.t("users.flash.warning.invalid_username")
> 
> I'm going to comment on the bug itself and question whether it's even a
> valid bug, but I'm not a fan of this particular implementation.
> 
> This would keep you from being thrčka ('č' is not "valid"), me from being
> 'matt.wagner' (it uses a verboten '.'), or someone who speaks Chinese or
> Russian or any other language with a non-Latin alphabet from even being
> able to use their name in their username. To me, that is far worse than
> being able to create a username named '.'.

You are right, now when I think about it it's all wrong. What about
validation at least first char is not in .~!@#$%^&*()

> 
> Note that this isn't a review of your patch -- just me disagreeing with
> the whole bug/fix. If people disagree with me, this is not a NACK.
> 
> -- Matt

== Tomas




More information about the aeolus-devel mailing list