perl-embperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thomas Baetzler <>
Subject What's going on here?
Date Fri, 04 Feb 2005 19:49:35 GMT

I have this totally weird problem with using Cyrus::SIEVE::managesieve
(part of the Cyrus messagestore) from an Embperl page. Maybe somebody
can help me understand what's going on. 

I'm running this on a current Debian "Sarge" (aka "testing") system with 
these relevant packages installed:

libapache-mod-ssl           2.8.22-1  
apache-common               1.3.33-3 
libhtml-embperl-perl        1.3.6-2 
cyrus21-admin               2.1.17-3

My test case code does nothing fancy - just connect and login to the
sieve daemon ("timsieved") running on localhost. Here it is:

  use Cyrus::SIEVE::managesieve;

  %cfg = ();

  sub prompt {  
    my( $key, $prompt ) = @_;
    return $cfg{ $key }; 

  sub login_sieve {

    $cfg{'username'} = shift;
    $cfg{'password'} = shift;
    $cfg{'authname'} = $cfg{'username'};

    return sieve_get_handle("localhost", "prompt", "prompt", "prompt",
"prompt" );

  $sieve = login_sieve( 'valid username','valid password' );
[$ if $sieve $]
<p>Login successful</p>
[$ else $]
<p>Login not successful</p>
[$ endif $]

The script runs just fine as "pure Perl" with warnings (and strict)
turned on. runs it without a complaint - even when I change
user to the webserver user. But when I try to open the code URL with a
browser, it just dies. Not like die(), mind you, but sudden and mute death.

When I send the request manually using telnet, I don't even see an error
code from the server, but just a "Connection closed" message from telnet. 

The Embperl debug log doesn't help much, either. After a request, the
last few lines are:

[25681]SVs:  17049
  $obj = login_sieve( 'valid username','valid password' );

I'd appreciate any and all ideas you might have. 

TIA & have a nice weekend,
Thomas Bätzler, or (alternate)
My homepage:  My Humor Archive:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message