Commit 39e7a31b authored by Eric Duminil's avatar Eric Duminil
Browse files

AMPEL_PASSWORD instead of HTTP_PASSWORD

parent b4b5658b
Pipeline #5825 passed with stage
in 2 minutes and 31 seconds
......@@ -2,6 +2,9 @@
# define CONFIG_H_INCLUDED
// This file is a config template, and can be copied to config.h. Please don't save any important password in this template.
// NOTE: Every parameter can be modified and saved later via the web-config.
// Some of those parameters can also be modified via commands in the Serial monitor :
// e.g. 'wifi 0' to turn WiFi off, or 'csv 60' to log data in csv every minute.
/**
* SERVICES
......@@ -68,13 +71,14 @@
# define LED_COUNT 12
/**
* WEB SERVER
* available at http://local_ip, with user HTTP_USER and password HTTP_PASSWORD
* AMPEL PASSWORD
* will be used for Access Point (without username), and for web-server available at http://local_ip
* with user 'admin', without quotes.
*/
// Define empty strings in order to disable authentication, or remove the constants altogether.
# define HTTP_USER "co2ampel"
# define HTTP_PASSWORD "my_password"
// If left empty, the password will be set during the first configuration, via access point.
// In order to be set successfully, it should have at least 8 characters.
# define AMPEL_PASSWORD ""
/**
* MQTT
......
......@@ -179,7 +179,7 @@ namespace web_config {
}
void initialize() {
iotWebConf = new IotWebConf(ampel.sensorId, &dnsServer, &http, HTTP_PASSWORD, config_version);
iotWebConf = new IotWebConf(ampel.sensorId, &dnsServer, &http, AMPEL_PASSWORD, config_version);
iotWebConf->setHtmlFormatProvider(&optionalGroupHtmlFormatProvider);
......@@ -340,10 +340,6 @@ namespace config {
bool &mqtt_encryption = web_config::mqttEncryptionParam.value();
bool &allow_mqtt_commands = web_config::mqttCommandsParam.value();
// HTTP
// const char *http_user = IOTWEBCONF_ADMIN_USER_NAME; // "admin" by default
// char *http_password = web_config::iotWebConf->getApPasswordParameter()->valueBuffer;
// LORAWAN
#if defined(ESP32)
bool is_lorawan_active() {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment