On 27 January 2012 00:58, Christophe Laprun <claprun(a)redhat.com> wrote:
Hi all,
I'm currently working on
https://issues.jboss.org/browse/GTNPORTAL-1673and I'm
quite puzzled by the different rules that are in place to validate
usernames. Not only are these rules not consistent across fields which
display usernames (some are validated using UsernameValidator, some are
validated using ExpressionValidator) but I'm also confused about the need
to validate read-only fields (which presumably will only display valid
information since it doesn't come from the user, right?). What are the
rules for a valid username and where are they documented? What are the
restrictions and why are they in place?
Defining the rules for a valid username is a long story, they have been
changed/updated many times according to users need. They are also not fixed
and documented so far. Until now, we still have requests related to this
like : to support case-sensitive, or possible to add username under an
email address.
Anyway the rules should be consistent every places and no need to validate
read-only fields, they are considered as issues
The second issue is that some of our users (rightly) want to validate user
names according to their own rules instead of arbitrary and opaque rules
that we impose on them for reasons that are entirely too unclear to me and
probably to our users. To address this issue, I need to find a way to
dynamically inject validators for some of the fields based on
user-definable configuration. I'm currently thinking about using a service
that would be initialized by the kernel and take its configuration from
${gatein.conf.dir}. Any opposition to this design? Any better idea?
Cordialement / Best,
Chris
==
Principal Software Engineer / JBoss Enterprise Middleware Red Hat, Inc.
Follow GateIn:
http://blog.gatein.org /
http://twitter.com/gatein
Follow me:
http://metacosm.info/metacosm /
http://twitter.com/metacosm
_______________________________________________
gatein-dev mailing list
gatein-dev(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/gatein-dev
--
Tran The Trong
eXo Platform SEA