From: naoki i. <am...@us...> - 2008-04-17 15:13:11
|
Update of /cvsroot/popfile/engine/Proxy In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6287/Proxy Modified Files: NNTP.pm POP3.pm SMTP.pm Log Message: Change Log 1. The session keys are now released when they are expired 2. New global parameter 'GLOBAL_session_timeout' (default : 1800 seconds) 3. Replaced get_administrator_session_key with get_single_user_session_key Classifier/Bayes.pm UI/HTML.pm POPFile/History.pm POPFile/Configuration.pm tests/TestConfiguration.tst The session keys which does not used in GLOBAL_session_timeout seconds will be released. NOTE : The session key for the administrator which got from get_administrator_session_key won't be expired. For this reason, please use get_single_user_session_key instead of get_administrator_session_key in the single user mode. NOTE : The 'last used time' is updated when valid_session_key__ is called with the session key. 4. Added 'Single User Mode Parameters' section in the Advanced tab UI/HTML.pm skins/default/advanced-page.thtml languages/English.msg languages/Nihongo.msg All POPFile parameters now can be changed in the single user mode. 'Single User Mode Parameters' section has been added below the 'Global POPFile Parameters' section. 5. Updated translation file languages/Nihongo.msg 6. The session cache is purged when the session key is released 7. The query is stopped when the session key is released UI/HTML.pm 8. Added escape_html_() function in HTTP.pm UI/HTTP.pm UI/HTML.pm tests/TestHTML.script This function is used for escaping ", <, >, &, ' characters. They are converted to ", <, >, & and ' 9. The matched header is showed/emphasized if the magnets are used UI/HTML.pm POPFile/History.pm Classifier/Bayes.pm tests/TestHTML.script The magnet icon's "title" will be like 'From:te...@ex...' in the history tab. The header information will be showed/emphasized in the single message view. 10. Minor fixes of the skins skins/default/common-bottom.thtml skins/default/users-page.thtml skins/default/administration-page.thtml skins/default/pop3-chain-panel.thtml skins/default/pop3-configuration-panel.thtml skins/default/socks-widget.thtml skins/default/nntp-configuration.thtml skins/default/smtp-configuration.thtml skins/default/windows-configuration.thtml Proxy/POP3.pm Proxy/NNTP.pm Proxy/SMTP.pm Platform/MSWin32.pm tests/TestPOP3.tst tests/TestHTML.tst Current state of the test suite: TestBayesScript PASS TestBayes PASS TestConfiguration PASS * TestHistory PASS TestHTML PASS * TestHTTP PASS TestIMAP PASS TestInsertScript PASS * TestLogger PASS TestMailParse PASS TestModule PASS TestMQ PASS TestMutex PASS TestPipeScript PASS TestPOP3 PASS TestProxy PASS TestWordMangle PASS TestXMLRPC PASS * : TODO : needs to add tests for multi user support Index: POP3.pm =================================================================== RCS file: /cvsroot/popfile/engine/Proxy/POP3.pm,v retrieving revision 1.119 retrieving revision 1.120 diff -C2 -d -r1.119 -r1.120 *** POP3.pm 6 Apr 2008 08:27:07 -0000 1.119 --- POP3.pm 17 Apr 2008 15:13:05 -0000 1.120 *************** *** 727,731 **** if ( $name eq 'pop3_configuration' ) { ! $templ->param( 'POP3_Configuration_If_Force_Fork' => ( $self->config_( 'force_fork' ) == 0 ) ); $templ->param( 'POP3_Configuration_Port' => $self->config_( 'port' ) ); $templ->param( 'POP3_Configuration_Separator' => $self->config_( 'separator' ) ); --- 727,731 ---- if ( $name eq 'pop3_configuration' ) { ! $templ->param( 'POP3_Configuration_If_Force_Fork' => ( $self->config_( 'force_fork' ) == 1 ) ); $templ->param( 'POP3_Configuration_Port' => $self->config_( 'port' ) ); $templ->param( 'POP3_Configuration_Separator' => $self->config_( 'separator' ) ); *************** *** 737,742 **** if ( $name eq 'pop3_chain' ) { $templ->param( 'POP3_Chain_Secure_Server' => $self->config_( 'secure_server' ) ); ! $templ->param( 'POP3_Chain_Secure_Port' => $self->config_( 'secure_port' ) ); ! $templ->param( 'POP3_Chain_Secure_SSL' => ( $self->config_( 'secure_ssl' ) == 1 ) ); } else { $self->SUPER::configure_item( $name, $templ, $language ); --- 737,742 ---- if ( $name eq 'pop3_chain' ) { $templ->param( 'POP3_Chain_Secure_Server' => $self->config_( 'secure_server' ) ); ! $templ->param( 'POP3_Chain_Secure_Port' => $self->config_( 'secure_port' ) ); ! $templ->param( 'POP3_Chain_Secure_SSL' => ( $self->config_( 'secure_ssl' ) == 1 ) ); } else { $self->SUPER::configure_item( $name, $templ, $language ); *************** *** 778,782 **** $self->config_( 'separator', $$form{pop3_separator} ); $status_message .= "\n" if ( defined( $status_message ) ); ! $status_message .= sprintf( $$language{Configuration_POP3SepUpdate}, $self->config_( 'separator' ) ) } else { $error_message .= "\n" if ( defined( $error_message ) ); --- 778,782 ---- $self->config_( 'separator', $$form{pop3_separator} ); $status_message .= "\n" if ( defined( $status_message ) ); ! $status_message .= sprintf( $$language{Configuration_POP3SepUpdate}, $self->config_( 'separator' ) ); } else { $error_message .= "\n" if ( defined( $error_message ) ); *************** *** 785,790 **** } ! if ( defined($$form{pop3_force_fork}) ) { ! $self->config_( 'force_fork', $$form{pop3_force_fork} ) if ($$form{pop3_force_fork} eq 1 || $$form{pop3_force_fork} eq 0); } --- 785,794 ---- } ! if ( defined($$form{update_pop3_configuration}) ) { ! if ( $$form{pop3_force_fork} ) { ! $self->config_( 'force_fork', 1 ); ! } else { ! $self->config_( 'force_fork', 0 ); ! } } *************** *** 793,797 **** if ( $name eq 'pop3_security' ) { ! if ( $form->{serveropt_pop3} ) { $self->config_( 'local', 0 ); } --- 797,801 ---- if ( $name eq 'pop3_security' ) { ! if ( $$form{serveropt_pop3} ) { $self->config_( 'local', 0 ); } *************** *** 820,825 **** } ! if ( defined($$form{sssl}) ) { ! if ( $$form{sssl} eq 'UseSSL' ) { $self->config_( 'secure_ssl', 1 ); $status_message .= "\n" if ( defined( $status_message ) ); --- 824,829 ---- } ! if ( defined($$form{update_server}) ) { ! if ( $$form{sssl} ) { $self->config_( 'secure_ssl', 1 ); $status_message .= "\n" if ( defined( $status_message ) ); Index: NNTP.pm =================================================================== RCS file: /cvsroot/popfile/engine/Proxy/NNTP.pm,v retrieving revision 1.43 retrieving revision 1.44 diff -C2 -d -r1.43 -r1.44 *** NNTP.pm 30 Mar 2008 05:33:58 -0000 1.43 --- NNTP.pm 17 Apr 2008 15:13:05 -0000 1.44 *************** *** 420,426 **** if ( $name eq 'nntp_config' ) { ! $templ->param( 'nntp_port' => $self->config_( 'port' ) ); ! $templ->param( 'nntp_separator' => $self->config_( 'separator' ) ); ! $templ->param( 'nntp_force_fork_on' => $self->config_( 'force_fork' ) ); } --- 420,426 ---- if ( $name eq 'nntp_config' ) { ! $templ->param( 'nntp_port' => $self->config_( 'port' ) ); ! $templ->param( 'nntp_separator' => $self->config_( 'separator' ) ); ! $templ->param( 'nntp_force_fork_on' => ( $self->config_( 'force_fork' ) == 1 ) ); } *************** *** 454,458 **** if ( defined $$form{nntp_port} ) { ! if ( ( $$form{nntp_port} >= 1 ) && ( $$form{nntp_port} < 65536 ) ) { $self->config_( 'port', $$form{nntp_port} ); $status = sprintf $$language{Configuration_NNTPUpdate}, $self->config_( 'port' ); --- 454,458 ---- if ( defined $$form{nntp_port} ) { ! if ( ( $$form{nntp_port} =~ /^\d+$/ ) && ( $$form{nntp_port} >= 1 ) && ( $$form{nntp_port} < 65536 ) ) { $self->config_( 'port', $$form{nntp_port} ); $status = sprintf $$language{Configuration_NNTPUpdate}, $self->config_( 'port' ); *************** *** 465,476 **** if ( length($$form{nntp_separator}) == 1 ) { $self->config_( 'separator', $$form{nntp_separator} ); ! $status = sprintf $$language{Configuration_NNTPSepUpdate}, $self->config_( 'separator' ); } else { ! $error = $$language{Configuration_Error1}; } } ! if ( defined $$form{nntp_force_fork} ) { ! $self->config_( 'force_fork', $$form{nntp_force_fork} ); } --- 465,482 ---- if ( length($$form{nntp_separator}) == 1 ) { $self->config_( 'separator', $$form{nntp_separator} ); ! $status .= "\n" if ( defined( $status ) ); ! $status .= sprintf $$language{Configuration_NNTPSepUpdate}, $self->config_( 'separator' ); } else { ! $error .= "\n" if ( defined( $error ) ); ! $error .= $$language{Configuration_Error1}; } } ! if ( defined $$form{update_nntp_configuration} ) { ! if ( $$form{nntp_force_fork} ) { ! $self->config_( 'force_fork', 1 ); ! } else { ! $self->config_( 'force_fork', 0 ); ! } } Index: SMTP.pm =================================================================== RCS file: /cvsroot/popfile/engine/Proxy/SMTP.pm,v retrieving revision 1.44 retrieving revision 1.45 diff -C2 -d -r1.44 -r1.45 *** SMTP.pm 30 Mar 2008 05:33:58 -0000 1.44 --- SMTP.pm 17 Apr 2008 15:13:05 -0000 1.45 *************** *** 340,345 **** if ( $name eq 'smtp_fork_and_port' ) { ! $templ->param( 'smtp_port' => $self->config_( 'port' ) ); ! $templ->param( 'smtp_force_fork_on' => $self->config_( 'force_fork' ) ); } --- 340,345 ---- if ( $name eq 'smtp_fork_and_port' ) { ! $templ->param( 'smtp_port' => $self->config_( 'port' ) ); ! $templ->param( 'smtp_force_fork_on' => ( $self->config_( 'force_fork' ) == 1 ) ); } *************** *** 381,390 **** if ( $name eq 'smtp_fork_and_port' ) { ! if ( defined($$form{smtp_force_fork}) ) { ! $self->config_( 'force_fork', $$form{smtp_force_fork} ); } if ( defined($$form{smtp_port}) ) { ! if ( ( $$form{smtp_port} >= 1 ) && ( $$form{smtp_port} < 65536 ) ) { $self->config_( 'port', $$form{smtp_port} ); $status = sprintf( $$language{Configuration_SMTPUpdate}, $self->config_( 'port' ) ); --- 381,394 ---- if ( $name eq 'smtp_fork_and_port' ) { ! if ( defined($$form{update_smtp_configuration}) ) { ! if ( $$form{smtp_force_fork} ) { ! $self->config_( 'force_fork', 1 ); ! } else { ! $self->config_( 'force_fork', 0 ); ! } } if ( defined($$form{smtp_port}) ) { ! if ( ( $$form{smtp_port} =~ /^\d+$/ ) && ( $$form{smtp_port} >= 1 ) && ( $$form{smtp_port} < 65536 ) ) { $self->config_( 'port', $$form{smtp_port} ); $status = sprintf( $$language{Configuration_SMTPUpdate}, $self->config_( 'port' ) ); |