Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
84e42e01
Commit
84e42e01
authored
May 18, 2006
by
Robert Shearman
Committed by
Alexandre Julliard
May 18, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rpcrt4: Support all available security packages in RpcBindingSetAuthInfoExA, instead of just NTLM.
parent
4e89efad
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
9 deletions
+29
-9
rpc_binding.c
dlls/rpcrt4/rpc_binding.c
+29
-9
No files found.
dlls/rpcrt4/rpc_binding.c
View file @
84e42e01
...
...
@@ -1017,9 +1017,12 @@ RpcBindingSetAuthInfoExA( RPC_BINDING_HANDLE Binding, unsigned char *ServerPrinc
RPC_SECURITY_QOS
*
SecurityQos
)
{
RpcBinding
*
bind
=
(
RpcBinding
*
)
Binding
;
RPC
_STATUS
r
;
SECURITY
_STATUS
r
;
CredHandle
cred
;
TimeStamp
exp
;
ULONG
package_count
;
ULONG
i
;
PSecPkgInfoA
packages
;
TRACE
(
"%p %s %lu %lu %p %lu %p
\n
"
,
Binding
,
debugstr_a
((
const
char
*
)
ServerPrincName
),
AuthnLevel
,
AuthnSvc
,
AuthIdentity
,
AuthzSvr
,
SecurityQos
);
...
...
@@ -1033,12 +1036,6 @@ RpcBindingSetAuthInfoExA( RPC_BINDING_HANDLE Binding, unsigned char *ServerPrinc
return
RPC_S_UNKNOWN_AUTHN_LEVEL
;
}
if
(
AuthnSvc
!=
RPC_C_AUTHN_WINNT
)
{
FIXME
(
"unsupported AuthnSvc %lu
\n
"
,
AuthnSvc
);
return
RPC_S_UNKNOWN_AUTHN_SERVICE
;
}
if
(
AuthzSvr
)
{
FIXME
(
"unsupported AuthzSvr %lu
\n
"
,
AuthzSvr
);
...
...
@@ -1048,8 +1045,28 @@ RpcBindingSetAuthInfoExA( RPC_BINDING_HANDLE Binding, unsigned char *ServerPrinc
if
(
SecurityQos
)
FIXME
(
"SecurityQos ignored
\n
"
);
r
=
AcquireCredentialsHandleA
(
NULL
,
"NTLM"
,
SECPKG_CRED_OUTBOUND
,
NULL
,
r
=
EnumerateSecurityPackagesA
(
&
package_count
,
&
packages
);
if
(
r
!=
SEC_E_OK
)
{
ERR
(
"EnumerateSecurityPackagesA failed with error 0x%08lx
\n
"
,
r
);
return
RPC_S_SEC_PKG_ERROR
;
}
for
(
i
=
0
;
i
<
package_count
;
i
++
)
if
(
packages
[
i
].
wRPCID
==
AuthnSvc
)
break
;
if
(
i
==
package_count
)
{
FIXME
(
"unsupported AuthnSvc %lu
\n
"
,
AuthnSvc
);
FreeContextBuffer
(
packages
);
return
RPC_S_UNKNOWN_AUTHN_SERVICE
;
}
TRACE
(
"found package %s for service %ld
\n
"
,
packages
[
i
].
Name
,
AuthnSvc
);
r
=
AcquireCredentialsHandleA
(
NULL
,
packages
[
i
].
Name
,
SECPKG_CRED_OUTBOUND
,
NULL
,
AuthIdentity
,
NULL
,
NULL
,
&
cred
,
&
exp
);
FreeContextBuffer
(
packages
);
if
(
r
==
ERROR_SUCCESS
)
{
if
(
bind
->
AuthInfo
)
RpcAuthInfo_Release
(
bind
->
AuthInfo
);
...
...
@@ -1057,10 +1074,13 @@ RpcBindingSetAuthInfoExA( RPC_BINDING_HANDLE Binding, unsigned char *ServerPrinc
r
=
RpcAuthInfo_Create
(
AuthnLevel
,
AuthnSvc
,
cred
,
exp
,
&
bind
->
AuthInfo
);
if
(
r
!=
RPC_S_OK
)
FreeCredentialsHandle
(
&
cred
);
return
RPC_S_OK
;
}
else
{
ERR
(
"AcquireCredentialsHandleA failed with error 0x%08lx
\n
"
,
r
);
return
r
;
return
RPC_S_SEC_PKG_ERROR
;
}
}
/***********************************************************************
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment