diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/Common/AuthManager.h | 1 | ||||
-rw-r--r-- | src/Core/ThreadManager.h | 1 | ||||
-rw-r--r-- | src/mad-server.conf | 1 | ||||
-rw-r--r-- | src/modules/UserConfigBackendKrb5/UserConfigBackendKrb5.cpp | 8 | ||||
-rw-r--r-- | src/modules/UserConfigBackendKrb5/UserConfigBackendKrb5.h | 2 |
5 files changed, 7 insertions, 6 deletions
diff --git a/src/Common/AuthManager.h b/src/Common/AuthManager.h index 0c249ad..1595495 100644 --- a/src/Common/AuthManager.h +++ b/src/Common/AuthManager.h @@ -28,6 +28,7 @@ #include <map> #include <set> +#include <vector> #include <boost/noncopyable.hpp> #include <boost/shared_ptr.hpp> diff --git a/src/Core/ThreadManager.h b/src/Core/ThreadManager.h index 9cae13c..d03dc5d 100644 --- a/src/Core/ThreadManager.h +++ b/src/Core/ThreadManager.h @@ -27,6 +27,7 @@ #include <boost/asio.hpp> +#include <boost/function.hpp> #include <boost/thread/thread.hpp> #include <boost/thread/condition_variable.hpp> #include <boost/thread/locks.hpp> diff --git a/src/mad-server.conf b/src/mad-server.conf index ad2a955..02ca76c 100644 --- a/src/mad-server.conf +++ b/src/mad-server.conf @@ -79,6 +79,7 @@ UserManager { } Krb5 { + Realm "EXAMPLE.COM" Principal "root/admin" Password "test" } diff --git a/src/modules/UserConfigBackendKrb5/UserConfigBackendKrb5.cpp b/src/modules/UserConfigBackendKrb5/UserConfigBackendKrb5.cpp index 72c8160..5f4e3cf 100644 --- a/src/modules/UserConfigBackendKrb5/UserConfigBackendKrb5.cpp +++ b/src/modules/UserConfigBackendKrb5/UserConfigBackendKrb5.cpp @@ -64,8 +64,8 @@ void UserConfigBackendKrb5::_connect() { princ += "@" + realm; if(!password.isEmpty() && keytab.isEmpty()) { - krb5_error_code err = kadm5_init_with_password(const_cast<char*>(princ.toLocale().c_str()), const_cast<char*>(password.toLocale().c_str()), - const_cast<char*>(KADM5_ADMIN_SERVICE), ¶ms, KADM5_STRUCT_VERSION, KADM5_API_VERSION_2, 0, &handle); + krb5_error_code err = kadm5_init_with_password(context, const_cast<char*>(princ.toLocale().c_str()), const_cast<char*>(password.toLocale().c_str()), + const_cast<char*>(KADM5_ADMIN_SERVICE), ¶ms, KADM5_STRUCT_VERSION, KADM5_API_VERSION_3, 0, &handle); if(err) { application->log(Core::Logger::LOG_USER, Core::Logger::LOG_ERROR, Core::Format("kadm5_init_with_password: %1%") % krb5_get_error_message(context, err)); @@ -80,8 +80,8 @@ void UserConfigBackendKrb5::_connect() { keytabName = const_cast<char*>(keytabStr.c_str()); } - krb5_error_code err = kadm5_init_with_skey(const_cast<char*>(princ.toLocale().c_str()), keytabName, - const_cast<char*>(KADM5_ADMIN_SERVICE), ¶ms, KADM5_STRUCT_VERSION, KADM5_API_VERSION_2, 0, &handle); + krb5_error_code err = kadm5_init_with_skey(context, const_cast<char*>(princ.toLocale().c_str()), keytabName, + const_cast<char*>(KADM5_ADMIN_SERVICE), ¶ms, KADM5_STRUCT_VERSION, KADM5_API_VERSION_3, 0, &handle); if(err) { application->log(Core::Logger::LOG_USER, Core::Logger::LOG_ERROR, Core::Format("kadm5_init_with_skey: %1%") % krb5_get_error_message(context, err)); diff --git a/src/modules/UserConfigBackendKrb5/UserConfigBackendKrb5.h b/src/modules/UserConfigBackendKrb5/UserConfigBackendKrb5.h index c02f868..34ab14c 100644 --- a/src/modules/UserConfigBackendKrb5/UserConfigBackendKrb5.h +++ b/src/modules/UserConfigBackendKrb5/UserConfigBackendKrb5.h @@ -27,8 +27,6 @@ #include <Core/ConfigManager.h> #include <boost/thread/mutex.hpp> - -#define USE_KADM5_API_VERSION 2 #include <kadm5/admin.h> namespace Mad { |