Hey list,

I ran into a nasty problem with SVN::Client under mp2.0.2. I simply want
it to connect to an ssl svn server with a specified username and password.

When I run the needed code from cmdline, everything works perfect, but
when I try to run it using an mp2 handler, it craps out with the following
errormessage:

Bogus filename: Can't open config file '/root/.subversion/servers' at
/srv/www/modules/testhandler.pm line 28

the code:

--

sub handler($) {

    my $r       = shift;

    $r->content_type('text/plain');

    print "BLA\n";

    my $ctx = new SVN::Client(
             auth => [
                SVN::Client::get_simple_provider(),
                SVN::Client::get_simple_prompt_provider(\&_simple_prompt,2),
                
SVN::Client::get_ssl_server_trust_prompt_provider(\&_trust_callback),
             ]
          );

    print "BLA2\n";

    return Apache2::Const::OK;
}

sub _trust_callback {
    my ($cred,$realm,$ifailed,$server_cert_info,$may_save) = @_;
    $cred->accepted_failures($SVN::Auth::SSL::UNKNOWNCA);
}

sub _simple_prompt {
    my ($cred, $realm, $default_username, $may_save, $pool) = @_;
    $cred->username($svn_user);
    $cred->password($svn_pass);
}

--

anyone know a solution?

Thanks in advance ;)

Enno

PS: I'm running the following:

- Apache/2.0.49 (Linux/SuSE)
- mod_ssl/2.0.49
- OpenSSL/0.9.7d
- mod_python/3.1.3
- Python/2.3.3
- DAV/2
- SVN/1.2.3
- PHP/4.3.4
- mod_perl/2.0.2
- Perl/v5.8.3

Reply via email to