Move role related views to FAB Auth manager:

- List roles
- Edit role
- Create role
- View role
raw_value = ldap_dict.get(field_name, [b""])
        
        return raw_value[0].decode("utf-8") or fallback
    @staticmethod
    def ldap_extract_list(ldap_dict: dict[str, list[bytes]], field_name: str) -> list[str]:
        raw_list = ldap_dict.get(field_name, [])
        
        return [x.decode("utf-8") for x in raw_list if x.decode("utf-8")]
    def auth_user_ldap(self, username, password):
        """
        Method for authenticating user with LDAP.
        NOTE: this depends on python-ldap module
        :param username: the username
        :param password: the password
        """
        
        if (username is None) or username == "":
            return None
        
        user = self.find_user(username=username)
        
        if user and (not user.is_active):
            return None
        
        if (not user) and (not self.auth_user_registration):
            return None
        
        try:
            import ldap