Skip to content
This repository has been archived by the owner on May 17, 2021. It is now read-only.

Welcome custom hydrators!

Compare
Choose a tag to compare
@Maks3w Maks3w released this 12 Feb 17:48
· 35 commits to master since this release

Custom hydrators replaces the hardcoded and usuallly customized LdapManager::hydrate() method.

Read Resources/doc/cookbook/custom_hydrator.md for to see how this new subcomponent helps you to fine customization the User hydration with your LDAP data.

CHANGELOG v3.0.0

Ldap driver:

  • [BC Break] Remove support for PHP 5.3 and 5.4
  • [BC Break] Remove legacy Ldap driver declared as deprecated in 2.0.0.
  • [BC Break] hydrate() method in LdapManager has been moved to Model\LegacyHydrator.php.
    See Create a custom hydrator for more details.
  • [BC Break] This bundle is now PSR-3 (Logger) compliant. Typehints has been updated in favor of Psr\Log\LoggerInterface.
  • [BC Break] Remove FR3D\LdapBundle\Ldap\Converter
  • [BC Break] Remove escapeValue() and unescapeValue() methods from LdapManagerInterface and LdapManager. Now use
    PHP 5.6 ldap_escape() polyfill.

Config:

  • [BC Break] Added fr3d_ldap.user.usernameAttribute for indicate the attribute which holds the username.
    Previously was the first entry in attributes

Validator:

  • Removed unused property option

UPGRADE v3.0.0

  • Define the attribute which hold the username value if was different than uid.

    Before:

    # app/config/config.yml
    fr3d_ldap:
        user:
            attributes:
                - { ldap_attr: customUID, user_method: setUsername }

    After:

    # app/config/config.yml
    fr3d_ldap:
        user:
            usernameAttribute: customUID # Add this line
            attributes:
                - { ldap_attr: customUID, user_method: setUsername }
  • If you was using the legacy (deprecated) old driver remove the ldap_driver setting and use the default one.

    # app/config/config.yml
    fr3d_ldap:
        service:
            ldap_driver: fr3d_ldap.ldap_driver.legacy # Remove this line.