credentials::combine() methods updated with support for EAPMsg:
- Additional parameters - Additional result code - User impersonation now mounted inside of credentials::combine() when required
This commit is contained in:
@@ -292,10 +292,14 @@ std::wstring eap::credentials_tls::get_identity() const
|
||||
|
||||
|
||||
eap::credentials::source_t eap::credentials_tls::combine(
|
||||
_In_ DWORD dwFlags,
|
||||
_In_ HANDLE hTokenImpersonateUser,
|
||||
_In_opt_ const credentials *cred_cached,
|
||||
_In_ const config_method &cfg,
|
||||
_In_opt_z_ LPCTSTR pszTargetName)
|
||||
{
|
||||
UNREFERENCED_PARAMETER(dwFlags);
|
||||
|
||||
if (cred_cached) {
|
||||
// Using EAP service cached credentials.
|
||||
*this = *dynamic_cast<const credentials_tls*>(cred_cached);
|
||||
@@ -312,6 +316,9 @@ eap::credentials::source_t eap::credentials_tls::combine(
|
||||
}
|
||||
|
||||
if (pszTargetName) {
|
||||
// Switch user context.
|
||||
user_impersonator impersonating(hTokenImpersonateUser);
|
||||
|
||||
try {
|
||||
credentials_tls cred_loaded(m_module);
|
||||
cred_loaded.retrieve(pszTargetName, cfg.m_level);
|
||||
|
Reference in New Issue
Block a user