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

Fix dashboard logout button and py3.8 removed hmac.new digestmod #1156

Merged
merged 6 commits into from
Jul 24, 2020

Conversation

OttoWinter
Copy link
Member

@OttoWinter OttoWinter commented Jul 15, 2020

Description:

This PR fixes two things:

  • The logout button was shown even when username/password are not set or when using HassIO ingress (in both cases there's no such thing as logging out)
  • Python 3.8 changed hmac.new behavior. It doesn't set the HMAC digest mode anymore (previously it was md5 which of course is not so good). -> Switch to using HMAC-SHA256.

Related issue (if applicable): fixes esphome/issues#1277

Pull request in esphome-docs with documentation (if applicable): esphome/esphome-docs#

Checklist:

  • The code change is tested and works locally.
  • Tests have been added to verify that the new code works (under tests/ folder).

If user exposed functionality or configuration variables are added/changed:

@pkuehne
Copy link
Contributor

pkuehne commented Jul 16, 2020

This might also fix esphome/issues#1277

No reason to use HMAC here, as authenticity is not an issue
@OttoWinter OttoWinter merged commit c030be4 into dev Jul 24, 2020
@OttoWinter OttoWinter deleted the fix-dashboard-logout-button branch July 24, 2020 09:10
This was referenced Jul 26, 2020
rspaargaren pushed a commit to rspaargaren/esphome that referenced this pull request Jul 30, 2020
…home#1156)

* Fix dashboard logout button and py3.8 removed hmac.new digestmod

* Just use SHA256

No reason to use HMAC here, as authenticity is not an issue

* Wrong branch

* Clenaup
sashao pushed a commit to sashao/esphome that referenced this pull request Oct 23, 2020
…home#1156)

* Fix dashboard logout button and py3.8 removed hmac.new digestmod

* Just use SHA256

No reason to use HMAC here, as authenticity is not an issue

* Wrong branch

* Clenaup
@github-actions github-actions bot locked and limited conversation to collaborators Sep 14, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TypeError: Missing required parameter 'digestmod' with Python 3.8 and username/password
2 participants