git://stoneship.org.uk
/
doorlock_v1.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b091c74
)
Require a password to enable OTA mode
author
BuildTools
<unconfigured@null.spigotmc.org>
Mon, 8 May 2017 11:07:36 +0000
(12:07 +0100)
committer
BuildTools
<unconfigured@null.spigotmc.org>
Mon, 8 May 2017 11:07:36 +0000
(12:07 +0100)
door_wiegand.ino
patch
|
blob
|
blame
|
history
diff --git
a/door_wiegand.ino
b/door_wiegand.ino
index
b2ae15f
..
ee8b2e0
100644
(file)
--- a/
door_wiegand.ino
+++ b/
door_wiegand.ino
@@
-90,10
+90,13
@@
unsigned long ntp_lasttry = 0;
bool ota_enabled = false;
-
+/* User requests to enable OTA mode */
void enable_ota(void)
{
if (!ota_enabled) {
+ if (!server.authenticate(www_username, www_password))
+ return server.requestAuthentication();
+
Serial.println("Enabling OTA Mode.");
ArduinoOTA.begin();
ota_enabled = true;