Re: How to prevent user invoke a method?

2009-08-13 Thread Dale Newfield
mailtolouis2020-str...@yahoo.com wrote: Since this is potiential security holes, how come this is not turn off by default? Probably for the same reason I used the phrase "I believe" so frequently in my last message. I was the one that pointed out this potential hole and urged it's closing

Re: How to prevent user invoke a method?

2009-08-13 Thread mailtolouis2020-struts
Well, just a thought. Of course I will turn it off. Since this is potiential security holes, how come this is not turn off by default? Louis From: Dale Newfield To: Struts Users Mailing List Sent: Thursday, August 13, 2009 6:13:42 PM Subject: Re: How to preve

Re: How to prevent user invoke a method?

2009-08-13 Thread Dale Newfield
mailtolouis2020-str...@yahoo.com wrote: I just wondering in case DyanmicMethodInvocation is require I believe that this is a mistake. I believe that setting DynamicMethodInvocation to "true" opens too many potential security holes. Why do you believe your application requires this to be set

Re: How to prevent user invoke a method?

2009-08-13 Thread mailtolouis2020-struts
Thanks Dale, Yes, done that. I just wondering in case DyanmicMethodInvocation is require, if I showing the customize 404 error page will it enough to prevent user to steal the information from the action property? Regards Louis From: Dale Newfield To: Struts

exception not print

2009-08-13 Thread Louis Voo
Hello, I follow the example to configure the global exception handling. Here is my error.jsp contain this Exception Name: What you did wrong: And in my action I throw a nullpointer exception, the error page is display, but no value show for exception and exceptionStack, what I missing ? Reg

Re: How to prevent user invoke a method?

2009-08-13 Thread Dale Newfield
Louis Voo wrote: Is there anyway to prevent user invoke a method which is not define in the configuration file? Yes: Set "struts.enable.DynamicMethodInvocation" to "false" -Dale - To unsubscribe, e-mail: user-unsubscr...@st

RE: struts 2.1.5 type conversion error

2009-08-13 Thread Martin Gainty
http transmits strings (not int,double,date or any other type of primitive) Martin Gainty je ne suis pas d'accord avec ce que vous dites. mais je défendrai à ma mort votre droite de la dire. - Voltaire __ Note de déni et de confidentialité Ce message

Re: Validating that two fields match?

2009-08-13 Thread James Carr
I got it working with fieldexpression, but had to use .equals() vs. == Now my next question... in order to get the confirmation field to be highlighted in red, I needed to add the same field validator for this field as well. I need the other validation errors to display for the confirm field (like

Re: Validation does not work on redirect result

2009-08-13 Thread musomesa
Martin I think the docs you are looking at are for the old org.apache.struts2.config.Result  rather than org.apache.struts2.convention.annotation.Result. Chris -Original Message- From: musom...@aol.com To: user@struts.apache.org Sent: Thu, Aug 13, 2009 10:10 am Subject: Re: Validati

RE: Validating that two fields match?

2009-08-13 Thread Martin Gainty
http://struts.apache.org/2.1.2/docs/using-field-validators.html . package org.apache.struts2.showcase.validation; public class FieldValidatorsExampleAction extends AbstractValidationActionSupport { private String requiredValidatorField = null; public String getRequiredV

RE: struts 2.1.5 type conversion error

2009-08-13 Thread Sandy.Verfaille
Lukasz, The type of 'price' is a double.. Thx for answering. Regards, sandy -Oorspronkelijk bericht- Van: Lukasz Lenart [mailto:lukasz.len...@googlemail.com] Verzonden: woensdag 22 juli 2009 9:50 Aan: Struts Users Mailing List Onderwerp: Re: struts 2.1.5 type conversion error 2009/7/

Re: Validation does not work on redirect result

2009-08-13 Thread musomesa
But then look at http://struts.apache.org/2.1.6/docs/convention-plugin.html#ConventionPlugin-Resultannotation I am using location successfuly. C -Original Message- From: Martin Gainty To: Struts Users Mailing List Sent: Thu, Aug 13, 2009 9:34 am Subject: RE: Validation does n

Re: Validating that two fields match?

2009-08-13 Thread musomesa
try the pattern etc -Original Message- From: James Carr To: Struts Users Mailing List Sent: Thu, Aug 13, 2009 9:53 am Subject: Re: Validating that two fields match? I have tried this and it doesn't seem to work at all. I am using ModelDriven and the model object has

Re: Validating that two fields match?

2009-08-13 Thread James Carr
I have tried this and it doesn't seem to work at all. I am using ModelDriven and the model object has a PointOfContact object with an emailAddress and confirmingEmail attributes. true Email Address is required. Please enter a v

RE: Validation does not work on redirect result

2009-08-13 Thread Martin Gainty
see value (of destination location) not location http://struts.apache.org/2.1.6/docs/result-annotation.html e.g. @Result(name="success", value="/home.page", type=TilesResult.class) is the doc incorrect? Martin Gainty __ Verzicht und Vertraulichkeitanm

Re: How to prevent user invoke a method?

2009-08-13 Thread mailtolouis2020-struts
Thanks Chris. From: "musom...@aol.com" To: user@struts.apache.org Sent: Thursday, August 13, 2009 1:13:52 PM Subject: Re: How to prevent user invoke a method? Have dynamic method invocation off and be careful with wildcards. Another possibility is to have an

Repopulate List in Form on validation failure

2009-08-13 Thread David Miller
Struts 1.3.10 Is it possible to repopulate a List of Objects on an ActionForm upon validation failure? If so, how? Here's a simple example of what I'm trying: *JSP:* *Form:* String year; List yearList = new ArrayList(); public String getYear() { return year; } public void setYear(S

Re: Validation does not work on redirect result

2009-08-13 Thread musomesa
Check @Result(name="input",value="findUser",type=ServletActionRedirectResult.class) I think the attribute should be location rather than value in 2.1.x Chris -Original Message- From: spsarolkar To: user@struts.apache.org Sent: Thu, Aug 13, 2009 12:47 am Subject: RE: Valida

Re: How to prevent user invoke a method?

2009-08-13 Thread musomesa
Have dynamic method invocation off and be careful with wildcards. Another possibility is to have an interceptor veto calls to that method but that would get tedious if you have many of them. chris -Original Message- From: Louis Voo To: Struts Users Mailing List Sent: Thu, Aug

How to prevent user invoke a method?

2009-08-13 Thread Louis Voo
Hello, Is there anyway to prevent user invoke a method which is not define in the configuration file? For e.g, in my UserAction, there is a public String getPassword() method. So in the url, user can enter User!getPassword to directly call this method(), of course they won't be a result map to

Re: Struts - 2.1.6 - Prepare Interceptor

2009-08-13 Thread Nils-Helge Garli Hegvik
super.prepare()? Nils-H On Thu, Aug 13, 2009 at 9:51 AM, Kishan Paandy wrote: > > Hi Folks, > > I have a problem as below: > > 1) > public abstract class AbstractBaseAction implements Preparable > { >    public void prepare() >        { >        populateSomething(); >        } > } > > 2) > public

Re: Validating that two fields match?

2009-08-13 Thread Andras Balogh
Hi, I have created a validator called "SameValueValidator", this worked both client-side and server side, this was for struts2.0.x so I don't know how will work with the latest struts (and if it works with annotations). If You are interested here it is: SameValueValidator.java: ---

Struts - 2.1.6 - Prepare Interceptor

2009-08-13 Thread Kishan Paandy
Hi Folks, I have a problem as below: 1) public abstract class AbstractBaseAction implements Preparable { public void prepare() { populateSomething(); } } 2) public class MyAction1 extends AbstractBaseAction { ……… } 3) public abstract class MyAction2 extends A