LdapTools\Ldif\Entry\LdifEntryModify::unicodePwdHack PHP Method

unicodePwdHack() protected method

..
protected unicodePwdHack ( BatchModifyOperation $operation )
$operation LdapTools\Operation\BatchModifyOperation
    protected function unicodePwdHack(BatchModifyOperation $operation)
    {
        if (!$this->isUnicodePwdHackNeeded()) {
            return;
        }
        foreach ($operation->getBatchCollection() as $batch) {
            if (strtolower($batch->getAttribute()) !== 'unicodepwd') {
                continue;
            }
            $values = $batch->getValues();
            $batch->setValues(base64_encode(reset($values)));
        }
    }