def attrlist(self):
        'Transform the KEY_MAP paramiter into an attrlist for ldap filters'
        keymap = self.config.get('KEY_MAP')
        if keymap:
            # https://github.com/ContinuumIO/flask-ldap-login/issues/11
            # https://continuumsupport.zendesk.com/agent/tickets/393
            return [s.encode('utf-8') for s in keymap.values()]
        else:
            return None
Transform the KEY_MAP paramiter into an attrlist for ldap filters