fortigate-api
fortigate-api copied to clipboard
Python package for configuring Fortigate (Fortios) devices using REST API
In the [token check](https://github.com/vladimirs-git/fortigate-api/blob/401b2c7bde08aff49f57c97603a8ddf765421471/fortigate_api/fortigate_base.py#L147C1-L147C65) the URL that is checked is .../cmdb/system/status. However this is an undocumented endpoint and might not be supported in future FortiOS versions. I propose that that...
Currently the [get token from cookies](https://github.com/vladimirs-git/fortigate-api/blob/401b2c7bde08aff49f57c97603a8ddf765421471/fortigate_api/fortigate_base.py#L212) function has the following loop: Current code ``` while True: # fortios < v7 cookie_name = "ccsrftoken" if cookies := [o for o in...
Inside the [login function](https://github.com/vladimirs-git/fortigate-api/blob/401b2c7bde08aff49f57c97603a8ddf765421471/fortigate_api/fortigate_base.py#L133) the logic for user/password authentication seems flawed. - The response to the post is _not_ raised. - The request to /system/vdom seems unnecessary as the existence...
The token validation link is invalid. This runs the risk of breaking in future FortiOS releases.