diff --git a/src/UnicaenLdap/Options/ModuleOptions.php b/src/UnicaenLdap/Options/ModuleOptions.php index de4eb67ebc14b919891189065a425445a4ada419..ec88fbf7bc4a509a002c4c7fce18a4c4f2807922 100644 --- a/src/UnicaenLdap/Options/ModuleOptions.php +++ b/src/UnicaenLdap/Options/ModuleOptions.php @@ -67,6 +67,11 @@ class ModuleOptions extends AbstractOptions */ protected $accountFilterFormat; + /** + * @var bool + */ + protected $useStartTls; + public function getIterator() { return new \ArrayIterator($this); @@ -244,7 +249,25 @@ class ModuleOptions extends AbstractOptions */ public function setAccountFilterFormat($accountFilterFormat) { - $this->accountFilterFormat = (boolean)$accountFilterFormat; + $this->accountFilterFormat = (string)$accountFilterFormat; + return $this; + } + + /** + * @return bool + */ + public function getUseStartTls(): bool + { + return $this->useStartTls; + } + + /** + * @param bool $useStartTls + * @return $this + */ + public function setUseStartTls(bool $useStartTls): ModuleOptions + { + $this->useStartTls = $useStartTls; return $this; } @@ -257,11 +280,12 @@ class ModuleOptions extends AbstractOptions { return array( 'host' => $this->getHost(), - 'port' => $this->getPort(), + 'port' => $this->getPort(), 'username' => $this->getUsername(), 'password' => $this->getPassword(), 'bindRequiresDn' => $this->getBindRequiresDn(), 'baseDn' => $this->getBaseDn(), + 'useStartTls' => $this->getUseStartTls(), ); } } \ No newline at end of file