Limit the number of maximum connect attempts to 1
http://php.net/manual/en/function.imap-open.php
This commit is contained in:
@@ -42,7 +42,7 @@ class OC_User_IMAP extends \OCA\user_external\Base {
|
|||||||
OCP\Util::writeLog('user_external', 'ERROR: PHP imap extension is not installed', OCP\Util::ERROR);
|
OCP\Util::writeLog('user_external', 'ERROR: PHP imap extension is not installed', OCP\Util::ERROR);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
$mbox = @imap_open($this->mailbox, $uid, $password, OP_HALFOPEN);
|
$mbox = @imap_open($this->mailbox, $uid, $password, OP_HALFOPEN, 1);
|
||||||
imap_errors();
|
imap_errors();
|
||||||
imap_alerts();
|
imap_alerts();
|
||||||
if($mbox !== FALSE) {
|
if($mbox !== FALSE) {
|
||||||
|
|||||||
Reference in New Issue
Block a user