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

Adds a second TLS fingerprint to allow switching keys in TLS mode #2102

Closed
wants to merge 1 commit into from

Conversation

issacg
Copy link
Contributor

@issacg issacg commented Mar 7, 2018

This is the start of an attempt to fix the issues brought up in #2033

Things I wasn't sure about, some of which almost need to be addressed:

  1. The memory addresses in Settings.h (or a revamp of how I'm storing the second key)
  2. The CFG_HOLDER may need to be bumped
  3. I'm not sure if an entry is needed in sonoff_post.h
  4. In Settings.ino I'm unsure if I patched correctly, or if a new SettingsDefaultSet_x is needed
  5. Changes made at run-time, via the Commands, don't seem to be saving. I assume that's due to the above, but not clear enough of how the settings is meant to fit together to figure it out.

@arendst
Copy link
Owner

arendst commented Mar 8, 2018

This PR is a good reason to finally store the fingerprint as hex values saving 2/3 of the space needed and allowing for a second fingerprint without messing up the settings area.

I have to invest some time to implement.

What would be the procedure/steps to change a fingerprint when you have the possibility to use commands MqttFingerprint1 and MqttFingerprint2?

@arendst arendst added the enhancement Type - Enhancement that will be worked on label Mar 8, 2018
@issacg
Copy link
Contributor Author

issacg commented Mar 8, 2018 via email

@arendst
Copy link
Owner

arendst commented Mar 9, 2018

So all that is needed is support for a second fingerprint and during initial connection test for both fingerprints and if one is valid continue as before. I'll make that.

In the initial issue you talk about fingerprint in relation to OTA. I do not use TLS with OTA and do not support HTTPS either. In the new ESP/Arduino library (2.4.0plus) there is works being made to get HTTPS functional. I did some testing with this but it makes tasmota unfunctional as it uses too many resources. For the short term I will not invest time in getting HTTPS usable on tiny ESP8266 devices running tasmota

arendst added a commit that referenced this pull request Mar 9, 2018
5.12.0e
 * Add a second TLS fingerprint to allow switching keys in TLS
mode (#2033, #2102)
@issacg
Copy link
Contributor Author

issacg commented Mar 11, 2018

Fixed in b51f060

@issacg issacg closed this Mar 11, 2018
curzon01 pushed a commit to curzon01/Tasmota that referenced this pull request Sep 6, 2018
5.12.0e
 * Add a second TLS fingerprint to allow switching keys in TLS
mode (arendst#2033, arendst#2102)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Type - Enhancement that will be worked on
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants