opensubscriber
   Find in this group all groups
 
Unknown more information…

o : openca-users@lists.sourceforge.net 26 June 2009 • 2:11AM -0400

Re: [Openca-Users] Explanation of EXEC calls in Openca
by Massimiliano Pala

REPLY TO AUTHOR
 
REPLY TO GROUP






Hi,

sorry not being more involved in the discussions on the ML.. it is a very
intense period for me.. :D But I am always here to help..

Coming to the problem..

The code that performs the evaluation of the EXEC:: is located in the
lib/request-utils.lib at line 169 - you are trying to execute
code passing parameters that are really variables.. this is not supported
in the EXEC code..you may need to modify the eval expression there...

Have you tried to pass the $VAR_NAME directly instead of using a function
to concatenate the values ? I am not sure it would work.. but something
like:
...
<value>$ADDITIONAL_ATTRIBUTE_FIRSTNAME $ADDITIONAL_ATTRIBUTE_MIDDLEINITIAL \
$ADDITIONAL_ATTRIBUTE_LASTNAME,$ADDITIONAL_ATTRIBUTE_SUFFIX</value>
...

I do not know if those values are actually exported as variables...

For this to work, you might need to change the code (lines 186-192) to
something like:

} else {
my $newVal = undef;
my $origVal = undef;

$origVal = $tmpVal;
foreach my $l ( $origVal =~ /\$([^\s]+)/g ) {
         $newVal = $query->param("$l");
if( $newVal eq "" ) {
$newVal = (eval $$l);
}

         $value[$t] =~ s/(\$$l)/$newVal/;
}
}

Let me know if this works... :D

Ciao,
Max


blainedw@gdls... wrote:
>
> Hi Max,
>
> Not sure how much you look at the openca mailing lists (especially the
> user one) but I have a question about how the EXEC calls work in
> browser_req.xml. I would like to call a custom function I wrote and pass
> some parameters to it but it doesn't seem to like paramters being
> passed. Really appreciate any feedback...

--

Best Regards,

Massimiliano Pala

--o------------------------------------------------------------------------
Massimiliano Pala [OpenCA Project Manager]  Massimiliano.Pala@dart...
                                                  project.manager@open...

Dartmouth Computer Science Dept               Home Phone: +1 (603) 369-9332
PKI/Trust Laboratory                          Work Phone: +1 (603) 646-9179
--o------------------------------------------------------------------------

People who think they know everything are a great annoyance to those of us
who do.
   -- Isaac Asimov

Bookmark with:

Delicious   Digg   reddit   Facebook   StumbleUpon

Related Messages

opensubscriber is not affiliated with the authors of this message nor responsible for its content.