Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

automatic logout from web interface - make "plugin read interval" changeable? #2

Open
DFS-90 opened this issue Oct 16, 2023 · 7 comments

Comments

@DFS-90
Copy link

DFS-90 commented Oct 16, 2023

Hey,

I have another Issue I want to report:
Whenever I try to access the speedport's web interface, I'm automatically logged out after a few seconds.
I assume that this happens every time the HACS plugin logs itself in in order to read the router's parameters.

Maybe it might help to add an option to set the "plugin read interval" (e. g. to every five or ten minutes) manually and / or to pause reading in order to be able to manually change router settings?

Thanks and best regards,
David

@DFS-90
Copy link
Author

DFS-90 commented Oct 17, 2023

Just thought about this problem again.
In the past, I used the script provided by aaronk6 (see here and here) that reads the router's encrypted JSON file, decrypts it and provides a decrypted version of the JSON file.

Maybe it's possible to combine this way of reading the router's values with your plugin?

Andre0512 added a commit to Andre0512/speedport-api that referenced this issue Oct 17, 2023
Andre0512 added a commit that referenced this issue Oct 17, 2023
@Andre0512
Copy link
Owner

Hey, that is a good idea. I introduced a configurable option, with which you can set for how many minutes the integration will not try to log in after an external login is registered. Try it out in v0.3.2 🙂

My integration uses the same decryption logic like aaronk6 (without knowing it 😅) and reads in the same json data. The status.json is not the problem, but some data like the ip addresses are not included and require other json files for which a login is needed.
btw the sensors that can be read from the status.json are not affected from the new pause

@MelleD
Copy link

MelleD commented Oct 18, 2023

Another idea is create a binary sensor / toggle sensor to temporarily switch off the entire login from HA to the speedport.
If you want to go to the Speeport.ip UI and do things directly on the router, you could simply set the toggle so that logins from HA no longer happen.

@Andre0512
Copy link
Owner

Hey @MelleD, thanks for your feedback. But I think with the new configuration feature this is not really a problem anymore. If you really want to work for several hours in your router web interface and the logout every x minutes bothers you, you can disable the integration temporarily 😄

@MelleD
Copy link

MelleD commented Oct 18, 2023

Hey @MelleD, thanks for your feedback. But I think with the new configuration feature this is not really a problem anymore. If you really want to work for several hours in your router web interface and the logout every x minutes bothers you, you can disable the integration temporarily 😄

I will test it and give feedback. I do a lot of things with a Overview Dashboard with the button template card and there would be toggle very easy and transparent :), but I will try the next version ;)

@MelleD
Copy link

MelleD commented Oct 18, 2023

e.g.
Bildschirmfoto 2023-10-18 um 14 54 12

Ignore the icon, is currently missing, but here I could just add new button/toggle or just if I click on the main card.

@DFS-90
Copy link
Author

DFS-90 commented Oct 18, 2023

Thanks for your hard work! 🙂
Installed v0.3.2, no problems so far. Can't test thoroughly though as I'm on travel atm.

Toggling a switch is a nice idea, deactivating the integration is also okay.

Maybe mentioning this in README is a good idea ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants