https://git.reactos.org/?p=reactos.git;a=commitdiff;h=da73c812598b56d137632…
commit da73c812598b56d137632f033afa51a68f022ca4
Author: Eric Kohl <eric.kohl(a)reactos.org>
AuthorDate: Tue Sep 18 15:55:18 2018 +0200
Commit: Eric Kohl <eric.kohl(a)reactos.org>
CommitDate: Tue Sep 18 15:55:18 2018 +0200
[IDL][LSASRV] Improve the credentials interface a little and update the lsa server
code accordingly.
---
dll/win32/lsasrv/lsarpc.c | 42 +++++++++++++++++++++++--------
sdk/include/reactos/idl/lsa.idl | 56 ++++++++++++++++++++++++++++++++++-------
2 files changed, 79 insertions(+), 19 deletions(-)
diff --git a/dll/win32/lsasrv/lsarpc.c b/dll/win32/lsasrv/lsarpc.c
index 987d9701c6..517b89a23c 100644
--- a/dll/win32/lsasrv/lsarpc.c
+++ b/dll/win32/lsasrv/lsarpc.c
@@ -1409,7 +1409,7 @@ LsarpOpenAccount(
AccountObject);
if (!NT_SUCCESS(Status))
{
- ERR("LsapOpenDbObject failed (Status 0x%08lx)\n", Status);
+ ERR("LsapOpenDbObject(Accounts/%S) failed (Status 0x%08lx)\n",
SidString, Status);
}
if (SidString != NULL)
@@ -3918,8 +3918,13 @@ NTSTATUS WINAPI CredrReadDomainCredentials(
/* Function 65 */
-NTSTATUS WINAPI CredrDelete(
- handle_t hBinding)
+NTSTATUS
+WINAPI
+CredrDelete(
+ handle_t hBinding,
+ LPWSTR TargetName,
+ DWORD Type,
+ DWORD Flags)
{
UNIMPLEMENTED;
return STATUS_NOT_IMPLEMENTED;
@@ -3927,8 +3932,13 @@ NTSTATUS WINAPI CredrDelete(
/* Function 66 */
-NTSTATUS WINAPI CredrGetTargetInfo(
- handle_t hBinding)
+NTSTATUS
+WINAPI
+CredrGetTargetInfo(
+ handle_t hBinding,
+ LPWSTR TargetName,
+ DWORD Flags,
+ CREDPR_TARGET_INFORMATION *TargetInformation)
{
UNIMPLEMENTED;
return STATUS_NOT_IMPLEMENTED;
@@ -3936,7 +3946,9 @@ NTSTATUS WINAPI CredrGetTargetInfo(
/* Function 67 */
-NTSTATUS WINAPI CredrProfileLoaded(
+NTSTATUS
+WINAPI
+CredrProfileLoaded(
handle_t hBinding)
{
UNIMPLEMENTED;
@@ -3983,8 +3995,12 @@ NTSTATUS WINAPI LsarLookupNames3(
/* Function 69 */
-NTSTATUS WINAPI CredrGetSessionTypes(
- handle_t hBinding)
+NTSTATUS
+WINAPI
+CredrGetSessionTypes(
+ handle_t hBinding,
+ DWORD MaximumPersistCount,
+ DWORD *MaximumPersist)
{
UNIMPLEMENTED;
return STATUS_NOT_IMPLEMENTED;
@@ -4045,8 +4061,14 @@ NTSTATUS WINAPI LsarSetForestTrustInformation(
/* Function 75 */
-NTSTATUS WINAPI CredrRename(
- handle_t hBinding)
+NTSTATUS
+WINAPI
+CredrRename(
+ handle_t hBinding,
+ LPWSTR OldTargetName,
+ LPWSTR NewTargetName,
+ DWORD Type,
+ DWORD Flags)
{
UNIMPLEMENTED;
return STATUS_NOT_IMPLEMENTED;
diff --git a/sdk/include/reactos/idl/lsa.idl b/sdk/include/reactos/idl/lsa.idl
index 93c2bc3d6b..a7be25b1ea 100644
--- a/sdk/include/reactos/idl/lsa.idl
+++ b/sdk/include/reactos/idl/lsa.idl
@@ -581,6 +581,22 @@ typedef struct _LSA_FOREST_TRUST_COLLISION_INFORMATION {
} LSA_FOREST_TRUST_COLLISION_INFORMATION, *PLSA_FOREST_TRUST_COLLISION_INFORMATION;
cpp_quote("#endif")
+
+/* Credentials */
+
+typedef struct _CREDPR_TARGET_INFORMATION
+{
+ LPWSTR TargetName;
+ LPWSTR NetbiosServerName;
+ LPWSTR DnsServerName;
+ LPWSTR NetbiosDomainName;
+ LPWSTR DnsDomainName;
+ LPWSTR DnsTreeName;
+ LPWSTR PackageName;
+ ULONG Flags;
+} CREDPR_TARGET_INFORMATION, *PCREDPR_TARGET_INFORMATION;
+
+
[
uuid(12345778-1234-abcd-ef00-0123456789ab),
version(0.0),
@@ -1007,15 +1023,27 @@ cpp_quote("#if _WIN32_WINNT >= 0x0501")
[in] handle_t hBinding); /* FIXME */
/* Function 65 */
- NTSTATUS __stdcall CredrDelete(
- [in] handle_t hBinding); /* FIXME */
+ NTSTATUS
+ __stdcall
+ CredrDelete(
+ [in] handle_t hBinding,
+ [in, unique, string] LPWSTR TargetName,
+ [in] DWORD Type,
+ [in] DWORD Flags); /* FIXME */
/* Function 66 */
- NTSTATUS __stdcall CredrGetTargetInfo(
- [in] handle_t hBinding); /* FIXME */
+ NTSTATUS
+ __stdcall
+ CredrGetTargetInfo(
+ [in] handle_t hBinding,
+ [in, unique, string] LPWSTR TargetName,
+ [in] DWORD Flags,
+ [out] CREDPR_TARGET_INFORMATION *TargetInformation); /* FIXME */
/* Function 67 */
- NTSTATUS __stdcall CredrProfileLoaded(
+ NTSTATUS
+ __stdcall
+ CredrProfileLoaded(
[in] handle_t hBinding); /* FIXME */
/* Function 68 */
@@ -1031,8 +1059,12 @@ cpp_quote("#if _WIN32_WINNT >= 0x0501")
[in] DWORD ClientRevision);
/* Function 69 */
- NTSTATUS __stdcall CredrGetSessionTypes(
- [in] handle_t hBinding); /* FIXME */
+ NTSTATUS
+ __stdcall
+ CredrGetSessionTypes(
+ [in] handle_t hBinding,
+ [in] DWORD MaximumPersistCount,
+ [out, size_is(MaximumPersistCount)] DWORD *MaximumPersist); /* FIXME */
/* Function 70 */
NTSTATUS __stdcall LsarRegisterAuditEvent(
@@ -1063,8 +1095,14 @@ cpp_quote("#if _WIN32_WINNT >= 0x0501")
[out] PLSA_FOREST_TRUST_COLLISION_INFORMATION *CollisionInfo);
/* Function 75 */
- NTSTATUS __stdcall CredrRename(
- [in] handle_t hBinding); /* FIXME */
+ NTSTATUS
+ __stdcall
+ CredrRename(
+ [in] handle_t hBinding,
+ [in, unique, string] LPWSTR OldTargetName,
+ [in, unique, string] LPWSTR NewTargetName,
+ [in] DWORD Type,
+ [in] DWORD Flags); /* FIXME */
/* Function 76 */
NTSTATUS __stdcall LsarLookupSids3(