Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3485284
D6251.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D6251.diff
View Options
diff --git a/services/tunnelbroker/src/libcpp/src/Tools/ConfigManager.h b/services/tunnelbroker/src/libcpp/src/Tools/ConfigManager.h
--- a/services/tunnelbroker/src/libcpp/src/Tools/ConfigManager.h
+++ b/services/tunnelbroker/src/libcpp/src/Tools/ConfigManager.h
@@ -26,10 +26,12 @@
static const std::string OPTION_NOTIFS_APNS_P12_CERT_PASSWORD;
static const std::string OPTION_NOTIFS_APNS_TOPIC;
static const std::string OPTION_NOTIFS_FCM_SERVER_KEY;
+ static const std::string OPTION_SESSIONS_SKIP_AUTH_KEY;
static ConfigManager &getInstance();
void load();
std::string getParameter(std::string param);
+ bool isParameterSet(std::string param);
};
} // namespace config
diff --git a/services/tunnelbroker/src/libcpp/src/Tools/ConfigManager.cpp b/services/tunnelbroker/src/libcpp/src/Tools/ConfigManager.cpp
--- a/services/tunnelbroker/src/libcpp/src/Tools/ConfigManager.cpp
+++ b/services/tunnelbroker/src/libcpp/src/Tools/ConfigManager.cpp
@@ -31,6 +31,8 @@
"notifications.apns_topic";
const std::string ConfigManager::OPTION_NOTIFS_FCM_SERVER_KEY =
"notifications.fcm_server_key";
+const std::string ConfigManager::OPTION_SESSIONS_SKIP_AUTH_KEY =
+ "sessions.skip_authentication";
ConfigManager &ConfigManager::getInstance() {
static ConfigManager instance;
@@ -113,6 +115,10 @@
boost::program_options::value<std::string>()->required(),
"Firebase Cloud Messaging server key for Android notifications");
+ description.add_options()(
+ this->OPTION_SESSIONS_SKIP_AUTH_KEY.c_str(),
+ "Skip sessions authentication mechanism");
+
boost::program_options::parsed_options parsedDescription =
boost::program_options::parse_config_file(
fileStream, description, true);
@@ -141,6 +147,10 @@
return parameterValue;
}
+bool ConfigManager::isParameterSet(std::string param) {
+ return this->variablesMap.count(param) != 0;
+}
+
} // namespace config
} // namespace network
} // namespace comm
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Dec 18, 7:52 PM (7 h, 49 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2674587
Default Alt Text
D6251.diff (1 KB)
Attached To
Mode
D6251: [services] Tunnelbroker - Add skip authentication config parameter
Attached
Detach File
Event Timeline
Log In to Comment