From ef2e7b3f9d264ec146d4dae257b1e295ab3b462a Mon Sep 17 00:00:00 2001 From: Hugues Hiegel Date: Tue, 21 Apr 2015 12:45:58 +0200 Subject: updates - plugins as a separate git folder --- plugins/password/drivers/poppassd.php | 82 ----------------------------------- 1 file changed, 82 deletions(-) delete mode 100644 plugins/password/drivers/poppassd.php (limited to 'plugins/password/drivers/poppassd.php') diff --git a/plugins/password/drivers/poppassd.php b/plugins/password/drivers/poppassd.php deleted file mode 100644 index 8ddbef5d3..000000000 --- a/plugins/password/drivers/poppassd.php +++ /dev/null @@ -1,82 +0,0 @@ - $code, 'message' => $matches[1]); - } - - return $code; - } - - function save($curpass, $passwd) - { - $rcmail = rcmail::get_instance(); -// include('Net/Socket.php'); - $poppassd = new Net_Socket(); - - $result = $poppassd->connect($rcmail->config->get('password_pop_host'), $rcmail->config->get('password_pop_port'), null); - if (PEAR::isError($result)) { - return $this->format_error_result(PASSWORD_CONNECT_ERROR, $result->getMessage()); - } - else { - $result = $poppassd->readLine(); - if(!preg_match('/^2\d\d/', $result)) { - $poppassd->disconnect(); - return $this->format_error_result(PASSWORD_ERROR, $result); - } - else { - $poppassd->writeLine("user ". $_SESSION['username']); - $result = $poppassd->readLine(); - if (!preg_match('/^[23]\d\d/', $result) ) { - $poppassd->disconnect(); - return $this->format_error_result(PASSWORD_CONNECT_ERROR, $result); - } - else { - $poppassd->writeLine("pass ". $curpass); - $result = $poppassd->readLine(); - if (!preg_match('/^[23]\d\d/', $result) ) { - $poppassd->disconnect(); - return $this->format_error_result(PASSWORD_ERROR, $result); - } - else { - $poppassd->writeLine("newpass ". $passwd); - $result = $poppassd->readLine(); - $poppassd->disconnect(); - if (!preg_match('/^2\d\d/', $result)) { - return $this->format_error_result(PASSWORD_ERROR, $result); - } - - return PASSWORD_SUCCESS; - } - } - } - } - } -} -- cgit v1.2.3