Skip to content

Check raises login error on "UniFi OS 3.2.7" #19

Open
@jrttr

Description

@jrttr

/share/check_mk/agents/special/agent_unifi_controller

 def check_unifi_os(self):
        _response = self.request("GET",url=self.url,allow_redirects=False)
        self.is_unifios= _response.status_code == 200 and _response.headers.get("x-csrf-token")

Header x-csrf-token is no longer available, so it is not possible to correctly determine whether unifiOS is being used. The wrong login URL is therefore used in def login()

File "/omd/sites/XXX/local/share/check_mk/agents/special/agent_unifi_controller", line 641, in <module>
_api = unifi_controller_api(**args.__dict__)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/omd/sites/XXX/local/share/check_mk/agents/special/agent_unifi_controller", line 551, in __init__
self.login(username,password)
File "/omd/sites/XXX/local/share/check_mk/agents/special/agent_unifi_controller", line 585, in login
raise unifi_api_exception("Login failed")

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions