summaryrefslogtreecommitdiffstats
path: root/src/modules/AuthBackendChallengeResponse
diff options
context:
space:
mode:
authorMatthias Schiffer <matthias@gamezock.de>2009-09-27 19:58:24 +0200
committerMatthias Schiffer <matthias@gamezock.de>2009-09-27 19:58:24 +0200
commitb40ba0cf91603b695f1f2380cbd39966a458f22f (patch)
tree1fec48ddc59eb1392fac38495b230e4b2cbf7528 /src/modules/AuthBackendChallengeResponse
parente1d8490f0654a3da0b900407d80d91d8d0da68c8 (diff)
downloadmad-b40ba0cf91603b695f1f2380cbd39966a458f22f.tar
mad-b40ba0cf91603b695f1f2380cbd39966a458f22f.zip
Use Unicode-aware String class instead of std::string
Diffstat (limited to 'src/modules/AuthBackendChallengeResponse')
-rw-r--r--src/modules/AuthBackendChallengeResponse/AuthBackendChallengeResponse.cpp8
-rw-r--r--src/modules/AuthBackendChallengeResponse/AuthBackendChallengeResponse.h12
2 files changed, 10 insertions, 10 deletions
diff --git a/src/modules/AuthBackendChallengeResponse/AuthBackendChallengeResponse.cpp b/src/modules/AuthBackendChallengeResponse/AuthBackendChallengeResponse.cpp
index fc6bd47..0785b7d 100644
--- a/src/modules/AuthBackendChallengeResponse/AuthBackendChallengeResponse.cpp
+++ b/src/modules/AuthBackendChallengeResponse/AuthBackendChallengeResponse.cpp
@@ -27,7 +27,7 @@ namespace Mad {
namespace Modules {
namespace AuthBackendChallengeResponse {
-const std::string AuthBackendChallengeResponse::methodName = "Challenge-Response";
+const Core::String AuthBackendChallengeResponse::methodName = "Challenge-Response";
AuthBackendChallengeResponse::AuthContextChallengeResponse::AuthContextChallengeResponse(AuthBackendChallengeResponse *backend) : authenticated(false) {
challenge.reserve(32);
@@ -38,13 +38,13 @@ AuthBackendChallengeResponse::AuthContextChallengeResponse::AuthContextChallenge
challenge.push_back(backend->randomGenerator());
}
-boost::shared_ptr<Common::AuthContext> AuthBackendChallengeResponse::authenticate(boost::shared_ptr<Common::AuthProvider> provider, const std::string &subMethod,
- const std::string &user, const std::vector<boost::uint8_t> &data, std::vector<boost::uint8_t> &response,
+boost::shared_ptr<Common::AuthContext> AuthBackendChallengeResponse::authenticate(boost::shared_ptr<Common::AuthProvider> provider, const Core::String &subMethod,
+ const Core::String &user, const std::vector<boost::uint8_t> &data, std::vector<boost::uint8_t> &response,
boost::shared_ptr<Common::AuthContext> context) throw(Core::Exception) {
if(context && dynamic_cast<AuthContextChallengeResponse*>(context.get()) == 0)
throw(Core::Exception(Core::Exception::INVALID_INPUT));
- std::vector<std::string> allowedMethods = getSubMethods(provider);
+ std::vector<Core::String> allowedMethods = getSubMethods(provider);
if(std::find(allowedMethods.begin(), allowedMethods.end(), subMethod) == allowedMethods.end())
throw(Core::Exception(Core::Exception::INVALID_INPUT));
diff --git a/src/modules/AuthBackendChallengeResponse/AuthBackendChallengeResponse.h b/src/modules/AuthBackendChallengeResponse/AuthBackendChallengeResponse.h
index dc1b60a..0d69eba 100644
--- a/src/modules/AuthBackendChallengeResponse/AuthBackendChallengeResponse.h
+++ b/src/modules/AuthBackendChallengeResponse/AuthBackendChallengeResponse.h
@@ -56,7 +56,7 @@ class MAD_MODULE_EXPORT AuthBackendChallengeResponse : public Common::AuthBacken
}
};
- static const std::string methodName;
+ static const Core::String methodName;
Common::Application *application;
@@ -68,19 +68,19 @@ class MAD_MODULE_EXPORT AuthBackendChallengeResponse : public Common::AuthBacken
protected:
- virtual const std::string& getMethodName() const {
+ virtual const Core::String& getMethodName() const {
return methodName;
}
- virtual std::vector<std::string> getSubMethods(boost::shared_ptr<Common::AuthProvider> provider) const {
- std::vector<std::string> ret;
+ virtual std::vector<Core::String> getSubMethods(boost::shared_ptr<Common::AuthProvider> provider) const {
+ std::vector<Core::String> ret;
ret.push_back(provider->getHashes().front());
return ret;
}
- virtual boost::shared_ptr<Common::AuthContext> authenticate(boost::shared_ptr<Common::AuthProvider> provider, const std::string &subMethod,
- const std::string &user, const std::vector<boost::uint8_t> &data, std::vector<boost::uint8_t> &response,
+ virtual boost::shared_ptr<Common::AuthContext> authenticate(boost::shared_ptr<Common::AuthProvider> provider, const Core::String &subMethod,
+ const Core::String &user, const std::vector<boost::uint8_t> &data, std::vector<boost::uint8_t> &response,
boost::shared_ptr<Common::AuthContext> context) throw(Core::Exception);
public: