Skip to content
This repository was archived by the owner on Jul 10, 2023. It is now read-only.

Authentication issues #55

@jk

Description

@jk

I've noticed that tokens were "refreshed" every 25 seconds, where they are currently valid for 3 hours (10800 seconds). You will get that expiration span in the response of https://api.netatmo.com/oauth2/token in expires_in and expire_in. This is likely to clutter up their memory for valid access IDs.

Furthermore refreshing is implemented as first retrieval of the access token (transfering username, password, client_id and client_secret every 25 seconds). This is highly controversioal in terms operational security and an anti-pattern for oauth2. You should rather use the refresh_token to get a fresh access_token every $now + $expires_in - $threashold. It's also documentated in their api documentation: https://dev.netatmo.com/apidocumentation/oauth#refreshing-a-token

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions