Closed AndiP1234 closed 4 years ago
Hello AndiP1234,
changing the source code of the library is not recommanded because upgrading the library to a new version will overwrite your changes.
There is a member function called useDNS(bool value)
: calling it with value=true
will use the URL instead of using the fixed IP.
Take in mind that if the DNS fail, it will try with the fixed IP.
Regarding the use of the fingerprint, I read that from the 2.5.0 version and above of the Library Core of the ESP8266, all HTTPS connection must provide the fingerprint as verification.
Maybe some things has been changed, I'll check it and if it work, I'll put inside the CTBOT_USE_FINGERPRINT = 0
define.
Another option is to use libraries like WiFiManager (https://github.com/tzapu/WiFiManager). This library provide a captive portal where you can change wifi network properties (SSID and password) but you can add more custom parameters. So you can add a way to update the Telegram IP / fingerprint with your PC/mobile in a easy way. There are lots of examples. Cheers
Stefano
Ok AndiP124: with the setInsecure() method all works without fingerprint.
Soon I'll upload the new version, changing the CTBOT_USE_FINGERPRINT
define to 0
will not use the fingerprint.
In the new version (2.0.0), the defines are located in the CTBotDefines.h
file.
Stefano
Hi,
is there a solution for long term support? With the last IP and fingerprint change it was necessary to download the sketch to my ESP again.
For the future I changed my code, it´s working but not secure: