Mike Wallick wrote:
> Right now I'm just fishing for options/feedback and researching how I
> might accomplish something like this. CGI and/or mod_perl is one
> method I am considering, along with a Java API/JSP/Servlet method.
> 


>>> I tried several ways of serializing the control record in Perl with no
>>> luck and using CGI::Session, Apache::Session, .etc..



The control record is (essentially) just the username, password and
server name packed into a C-struct. There's no magic in it. What you
want to do is cache that information within your application (by using
Apache::Session for example) and then fetch it and call ars_Login() for
each http transaction.

Yes, there are security issues with doing the above, but if you could
serialize the control record, you'd have the same issues.

You can fetch the contents of the control record and store the useful
fields by using ars_GetControlStructFields()

Save this as /tmp/t.pl

#!/usr/bin/perl
use ARS;
$c = ars_Login(shift, shift, shift);
die $ars_errstr unless $c;
print join(',', ars_GetControlStructFields($c)), "\n";
exit 0;



and type this:


perl /tmp/t.pl yourserver youruser yourpass



and you'll see that the control record contains very little information.



jeff

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Arsperl-users mailing list
Arsperl-users@arsperl.org
https://lists.sourceforge.net/lists/listinfo/arsperl-users

Reply via email to