The encrypted attribute of @Validate does two things. It tells the
validation system that the incoming field is encrypted and must be
decrypted before passed into a TypeConverter. It also causes the output
of a Formatter to be encrypted before it is displayed.

You don't want to use encrypted on anything that a user enters. Only use
it for values that you don't want the user to be able to modify such as
hidden fields, values for selects, etc.

Aaron

esemba wrote:
> Hi,
> I'm having problems with one of my forms. I've three properties here -
> username, password and passwordRetype. Problem is, that these properties
> always end up null after the form is submitted.
> I've noticed couple of weird lines in my log file:
>
> DEBUG - Converting 1 value(s) using converter
> net.sourceforge.stripes.validation.StringTypeConverter
> WARN - Input is not Base64 encoded: foo
> DEBUG - Converting 1 value(s) using converter
> net.sourceforge.stripes.validation.StringTypeConverter
> WARN - Input was not encrypted with the current encryption key: admin
> DEBUG - Converting 1 value(s) using converter
> net.sourceforge.stripes.validation.StringTypeConverter
> WARN - Input is not Base64 encoded: bar
>
> All properties are annotated for validation like this:
>
> @Validate(encrypted = true)
> private String username;
>
> I also have set Stripes.EncryptionKey init param for stripes filter in
> web.xml.
>
> Does anybody know, what can be the problem here? Thank
>
> Regards Lukas
>   


------------------------------------------------------------------------------
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
_______________________________________________
Stripes-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stripes-users

Reply via email to