MCPcopy Create free account
hub / github.com/apache/mesos / createCustomAuthenticator

Function createCustomAuthenticator

src/common/http.cpp:1326–1345  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1324
1325
1326Result<process::http::authentication::Authenticator*> createCustomAuthenticator(
1327 const string& realm,
1328 const string& authenticatorName)
1329{
1330 if (!modules::ModuleManager::contains<
1331 process::http::authentication::Authenticator>(authenticatorName)) {
1332 return Error(
1333 "HTTP authenticator '" + authenticatorName + "' not found. "
1334 "Check the spelling (compare to '" +
1335 string(internal::DEFAULT_BASIC_HTTP_AUTHENTICATOR) +
1336 "') or verify that the authenticator was loaded "
1337 "successfully (see --modules)");
1338 }
1339
1340 LOG(INFO) << "Creating '" << authenticatorName << "' HTTP authenticator "
1341 << "for realm '" << realm << "'";
1342
1343 return modules::ModuleManager::create<
1344 process::http::authentication::Authenticator>(authenticatorName);
1345}
1346
1347} // namespace {
1348

Callers 2

foreachFunction · 0.85

Calls 1

ErrorFunction · 0.50

Tested by

no test coverage detected