Skip to content

Commit

Permalink
Merge pull request #100 from omersiar/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
omersiar authored Apr 2, 2018
2 parents 604d667 + b0c46a3 commit 37c8a77
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 19 deletions.
10 changes: 7 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,21 @@
# Change Log
All notable changes to this project will be documented in this file.

## [Unreleased]
## [0.7.2] - 2018-04-02
#### Fixed
- [webui] We were checking wrongly if the browser has previously had authentication over /login.
- [webui] MQTT listed disabled even if it is enabled #92 @pidiet
- [webui] MQTT is enabled by default.

## [0.7.1] - 2018-03-30
#### Added
- [firmware] + [webui] Option to use static IP address #89 @nbaglietto
- [firmware] + [webui] Option to hide SSID on AP Mode #89 @nbaglietto
- [webui] Auto focus on login password #94 @pidiet
- [firmware] event log for MQTT

#### Fixed
- [webui] We were checking wrongly if the browser has previously had authentication over /login.
- [webui] MQTT listed disabled even if it is enabled #92 @pidiet

## [0.7.0] - 2018-03-23
#### Added
- [firmware] !!! BREAKING CHANGE !!! 2 MB Flash 2 MB SPIFFS size for future proof firmware updates plase make sure you made a backup before updating to this version. You need to format SPIFFS.
Expand Down
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,8 @@ For Wiegand based readers, you can configure D0 and D1 pins via settings page. B
* Congratulations, everything went well, if you encounter any issue feel free to ask help on GitHub.

### Known Issues
* MQTT does not publish the UID anymore when disconnected from MQTT server.
* MQTT functionality is not stable for now.
* See [#99](https://github.com/omersiar/esp-rfid/issues/99).
* Please also check [GitHub issues](https://github.com/omersiar/esp-rfid/issues).


Expand All @@ -111,7 +112,7 @@ This will require you to do syncing manually. ESP can store and hold time for yo
So you have to login to settings page and sync it in a timely fashion.

## **Security**
We assume **ESP-RFID** project -as a whole- does not offer strong security. There are PICCs available that their UID (Unique Identification Numbers) can be set manually (Currently esp-rfid relies only UID to identify it's users). Also there may be a bug in the code that may result free access to your belongings. And also, like every other network connected device esp-rfid is vulnerable to many attacks including Man-in-the-middle, Brute-force, etc.
We assume **ESP-RFID** project -as a whole- does not offer strong security. There are PICCs available that their UID (Unique Identification Numbers) can be set manually (Currently esp-rfid relies only UID to identify its users). Also there may be a bug in the code that may result free access to your belongings. And also, like every other network connected device esp-rfid is vulnerable to many attacks including Man-in-the-middle, Brute-force, etc.

This is a simple, hobby grade project, do not use it where strong security is needed.

Expand Down
Binary file modified bin/firmware.bin
Binary file not shown.
5 changes: 4 additions & 1 deletion src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -885,7 +885,7 @@ void onMqttDisconnect(AsyncMqttClientDisconnectReason reason) {
}
writeEvent("WARN", "mqtt", "Disconnected from MQTT server", reasonstr);
if (WiFi.isConnected()) {
mqttReconnectTimer.once(2, connectToMqtt);
mqttReconnectTimer.once(60, connectToMqtt);
}
}

Expand All @@ -894,7 +894,10 @@ void onMqttPublish(uint16_t packetId) {
}

void onMqttConnect(bool sessionPresent) {
Serial.println("MQTT Connected session");
uint16_t packetIdPub1 = mqttClient.publish("test/lol", 1, true, "test 2");
if (sessionPresent == true) {
Serial.println("MQTT Connected session");
writeEvent("INFO", "mqtt", "Connected to MQTT Server", "Session Present");
}
}
Expand Down
18 changes: 9 additions & 9 deletions src/webh/esprfid.js.gz.h

Large diffs are not rendered by default.

9 changes: 5 additions & 4 deletions src/websrc/js/esprfid.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ var config = {
"version": ""
},
"mqtt": {
"enabled": "",
"enabled": "0",
"host": "",
"port": "",
"topic": "",
Expand Down Expand Up @@ -203,20 +203,21 @@ function checkOctects(input) {
}

function savenetwork() {
var wmode = "0";
config.network.dhcp = "0";
config.network.hide = "0";
if (document.getElementById("inputtohide").style.display === "none") {
var b = document.getElementById("ssid");
config.network.ssid = b.options[b.selectedIndex].value;
} else {
config.network.ssid = document.getElementById("inputtohide").value;
}
var wmode = "0";
if (document.getElementById("wmodeap").checked) {
wmode = "1";
config.network.bssid = document.getElementById("wifibssid").value = 0;
if (document.querySelector('input[name="hideapenable"]:checked').value === "1") {
config.network.hide = "1";
} else { config.network.hide = "0"; }

} else {
config.network.bssid = document.getElementById("wifibssid").value;
if (document.querySelector('input[name="dhcpenabled"]:checked').value === "1") {
Expand Down Expand Up @@ -957,7 +958,7 @@ function socketMessageListener(evt) {
break;
case "configfile":
config = obj;
config.general.version = "v0.7";
config.general.version = "v0.7.2";
break;
default:
break;
Expand Down

0 comments on commit 37c8a77

Please sign in to comment.