Nikolay Sivov : combase: Move CoSetProxyBlanket().
Alexandre Julliard
julliard at winehq.org
Thu Aug 6 16:33:43 CDT 2020
Module: wine
Branch: master
Commit: 28f325fd16369a6bc092b71ac6509c244cea4670
URL: https://source.winehq.org/git/wine.git/?a=commit;h=28f325fd16369a6bc092b71ac6509c244cea4670
Author: Nikolay Sivov <nsivov at codeweavers.com>
Date: Thu Aug 6 09:13:06 2020 +0300
combase: Move CoSetProxyBlanket().
Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
Signed-off-by: Huw Davies <huw at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/combase/combase.c | 24 ++++++++++++++++++++++++
dlls/combase/combase.spec | 2 +-
dlls/ole32/compobj.c | 45 ---------------------------------------------
dlls/ole32/ole32.spec | 2 +-
4 files changed, 26 insertions(+), 47 deletions(-)
diff --git a/dlls/combase/combase.c b/dlls/combase/combase.c
index c67cf2fbce..b87c6f19ba 100644
--- a/dlls/combase/combase.c
+++ b/dlls/combase/combase.c
@@ -479,3 +479,27 @@ HRESULT WINAPI CoQueryProxyBlanket(IUnknown *proxy, DWORD *authn_service,
if (FAILED(hr)) ERR("-- failed with %#x.\n", hr);
return hr;
}
+
+/******************************************************************************
+ * CoSetProxyBlanket (combase.@)
+ */
+HRESULT WINAPI CoSetProxyBlanket(IUnknown *proxy, DWORD authn_service, DWORD authz_service,
+ OLECHAR *servername, DWORD authn_level, DWORD imp_level, void *auth_info, DWORD capabilities)
+{
+ IClientSecurity *client_security;
+ HRESULT hr;
+
+ TRACE("%p, %u, %u, %p, %u, %u, %p, %#x.\n", proxy, authn_service, authz_service, servername,
+ authn_level, imp_level, auth_info, capabilities);
+
+ hr = IUnknown_QueryInterface(proxy, &IID_IClientSecurity, (void **)&client_security);
+ if (SUCCEEDED(hr))
+ {
+ hr = IClientSecurity_SetBlanket(client_security, proxy, authn_service, authz_service, servername, authn_level,
+ imp_level, auth_info, capabilities);
+ IClientSecurity_Release(client_security);
+ }
+
+ if (FAILED(hr)) ERR("-- failed with %#x.\n", hr);
+ return hr;
+}
diff --git a/dlls/combase/combase.spec b/dlls/combase/combase.spec
index ed6767263d..88d3adeec9 100644
--- a/dlls/combase/combase.spec
+++ b/dlls/combase/combase.spec
@@ -155,7 +155,7 @@
@ stdcall CoRevokeMallocSpy()
@ stub CoSetCancelObject
@ stub CoSetErrorInfo
-@ stdcall CoSetProxyBlanket(ptr long long ptr long long ptr long) ole32.CoSetProxyBlanket
+@ stdcall CoSetProxyBlanket(ptr long long ptr long long ptr long)
@ stdcall CoSuspendClassObjects() ole32.CoSuspendClassObjects
@ stdcall CoSwitchCallContext(ptr ptr) ole32.CoSwitchCallContext
@ stdcall CoTaskMemAlloc(long)
diff --git a/dlls/ole32/compobj.c b/dlls/ole32/compobj.c
index b96edf99bf..aeb7c4d29c 100644
--- a/dlls/ole32/compobj.c
+++ b/dlls/ole32/compobj.c
@@ -4192,51 +4192,6 @@ HRESULT WINAPI CoAllowSetForegroundWindow(IUnknown *pUnk, void *pvReserved)
return S_OK;
}
-/***********************************************************************
- * CoSetProxyBlanket [OLE32.@]
- *
- * Sets the security settings for a proxy.
- *
- * PARAMS
- * pProxy [I] Pointer to the proxy object.
- * AuthnSvc [I] The type of authentication service.
- * AuthzSvc [I] The type of authorization service.
- * pServerPrincName [I] The server prinicple name.
- * AuthnLevel [I] The authentication level.
- * ImpLevel [I] The impersonation level.
- * pAuthInfo [I] Information specific to the authorization/authentication service.
- * Capabilities [I] Flags affecting the security behaviour.
- *
- * RETURNS
- * Success: S_OK.
- * Failure: HRESULT code.
- *
- * SEE ALSO
- * CoQueryProxyBlanket, CoCopyProxy.
- */
-HRESULT WINAPI CoSetProxyBlanket(IUnknown *pProxy, DWORD AuthnSvc,
- DWORD AuthzSvc, OLECHAR *pServerPrincName, DWORD AuthnLevel,
- DWORD ImpLevel, void *pAuthInfo, DWORD Capabilities)
-{
- IClientSecurity *pCliSec;
- HRESULT hr;
-
- TRACE("%p\n", pProxy);
-
- hr = IUnknown_QueryInterface(pProxy, &IID_IClientSecurity, (void **)&pCliSec);
- if (SUCCEEDED(hr))
- {
- hr = IClientSecurity_SetBlanket(pCliSec, pProxy, AuthnSvc,
- AuthzSvc, pServerPrincName,
- AuthnLevel, ImpLevel, pAuthInfo,
- Capabilities);
- IClientSecurity_Release(pCliSec);
- }
-
- if (FAILED(hr)) ERR("-- failed with 0x%08x\n", hr);
- return hr;
-}
-
/***********************************************************************
* CoCopyProxy [OLE32.@]
*
diff --git a/dlls/ole32/ole32.spec b/dlls/ole32/ole32.spec
index c737b2e386..54725e406a 100644
--- a/dlls/ole32/ole32.spec
+++ b/dlls/ole32/ole32.spec
@@ -79,7 +79,7 @@
@ stdcall CoRevokeClassObject(long)
@ stdcall CoRevokeInitializeSpy(int64)
@ stdcall CoRevokeMallocSpy() combase.CoRevokeMallocSpy
-@ stdcall CoSetProxyBlanket(ptr long long ptr long long ptr long)
+@ stdcall CoSetProxyBlanket(ptr long long ptr long long ptr long) combase.CoSetProxyBlanket
@ stdcall CoSetState(ptr)
@ stdcall CoSuspendClassObjects()
@ stdcall CoSwitchCallContext(ptr ptr)
More information about the wine-cvs
mailing list