Update of /cvsroot/popfile/engine/Proxy
In directory sc8-pr-cvs1:/tmp/cvs-serv1952
Modified Files:
NNTP.pm
Log Message:
fixed remote login, syntax now [username@]host[:port]
Index: NNTP.pm
===================================================================
RCS file: /cvsroot/popfile/engine/Proxy/NNTP.pm,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** NNTP.pm 18 Mar 2003 00:48:25 -0000 1.3
--- NNTP.pm 18 Mar 2003 01:55:19 -0000 1.4
***************
*** 62,66 ****
# The separator within the NNTP user name is :
! $self->config_( 'separator', ':');
return 1;
--- 62,66 ----
# The separator within the NNTP user name is :
! $self->config_( 'separator', '@');
return 1;
***************
*** 122,134 ****
if ($connection_state eq 'username needed') {
! my $user_command = '^ *AUTHINFO USER (.+)(:(\d+))?(' . $self->config_( 'separator' ) . '(.+))?';
! if ( $command =~ /$user_command/i ) {
! if ( $1 ne '' ) {
! if ( $news = $self->verify_connected_( $news, $client, $1, $3 || 119 ) ) {
! if (defined $5) {
# Pass through the AUTHINFO command with the actual user name for this server,
# if one is defined, and send the reply straight to the client
! $self->echo_response_($news, $client, 'AUTHINFO USER ' . $5 );
$connection_state = "password needed";
} else {
--- 122,139 ----
if ($connection_state eq 'username needed') {
! my $user_command = '^ *AUTHINFO USER ((.+)\\' . $self->config_('separator') . ')?([^\:]+)(:(.*))?';
! if ( $command =~ /$user_command/i ) {
!
! my $username = $2;
! my $server = $3;
! my $port = $5;
!
! if ( $server ne '' ) {
! if ( $news = $self->verify_connected_( $news, $client, $server, $port || 119 ) ) {
! if (defined $username) {
# Pass through the AUTHINFO command with the actual user name for this server,
# if one is defined, and send the reply straight to the client
! $self->get_response_($news, $client, 'AUTHINFO USER ' . $username );
$connection_state = "password needed";
} else {
***************
*** 136,142 ****
$self->tee_($client, "381 password$eol");
$connection_state = "ignore password";
! }
!
!
} else {
--- 141,145 ----
$self->tee_($client, "381 password$eol");
$connection_state = "ignore password";
! }
} else {
***************
*** 161,166 ****
if ($command =~ /^ *AUTHINFO PASS (.*)/i) {
! my $response = $self->echo_response_($news, $client, $command);
! $self->tee_($client,$response);
if ($response =~ /^281 .*/) {
--- 164,168 ----
if ($command =~ /^ *AUTHINFO PASS (.*)/i) {
! my $response = $self->get_response_($news, $client, $command);
if ($response =~ /^281 .*/) {
|