ReactOS.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
List overview
Download
Ros-diffs
August 2008
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
ros-diffs@reactos.org
27 participants
853 discussions
Start a n
N
ew thread
[sginsberg] 35042: - ExpLookupHandleTableEntry: Apply same changes as was done for ExpFreeHandleTable and ExpAllocateHandleTableEntrySlow in 34467 - ExpAllocateHandleTableEntry: Fail if we don't find a handle table entry
by sginsberg@svn.reactos.org
Author: sginsberg Date: Sat Aug 2 13:25:53 2008 New Revision: 35042 URL:
http://svn.reactos.org/svn/reactos?rev=35042&view=rev
Log: - ExpLookupHandleTableEntry: Apply same changes as was done for ExpFreeHandleTable and ExpAllocateHandleTableEntrySlow in 34467 - ExpAllocateHandleTableEntry: Fail if we don't find a handle table entry Modified: trunk/reactos/ntoskrnl/ex/handle.c Modified: trunk/reactos/ntoskrnl/ex/handle.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ex/handle.c?rev=3…
============================================================================== --- trunk/reactos/ntoskrnl/ex/handle.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/ex/handle.c [iso-8859-1] Sat Aug 2 13:25:53 2008 @@ -35,8 +35,10 @@ ExpLookupHandleTableEntry(IN PHANDLE_TABLE HandleTable, IN EXHANDLE LookupHandle) { - ULONG i, j, k, TableLevel, NextHandle; - ULONG_PTR TableBase; + ULONG i, j, k, NextHandle; + ULONG_PTR TableCode = HandleTable->TableCode; + ULONG_PTR TableBase = TableCode & ~3; + ULONG TableLevel = (ULONG)(TableCode & 3); PHANDLE_TABLE_ENTRY Entry = NULL; EXHANDLE Handle = LookupHandle; PUCHAR Level1, Level2, Level3; @@ -45,13 +47,6 @@ Handle.TagBits = 0; NextHandle = *(volatile ULONG*)&HandleTable->NextHandleNeedingPool; if (Handle.Value >= NextHandle) return NULL; - - /* Get the table code */ - TableBase = *(volatile ULONG_PTR*)&HandleTable->TableCode; - - /* Extract the table level and actual table base */ - TableLevel = (ULONG)(TableBase & 3); - TableBase = TableBase - TableLevel; /* Check what level we're running at */ switch (TableLevel) @@ -210,8 +205,8 @@ PEPROCESS Process = HandleTable->QuotaProcess; ULONG i, j; ULONG_PTR TableCode = HandleTable->TableCode; - ULONG TableLevel = TableCode & 3; ULONG_PTR TableBase = TableCode & ~3; + ULONG TableLevel = (ULONG)(TableCode & 3); PHANDLE_TABLE_ENTRY Level1, *Level2, **Level3; PAGED_CODE(); @@ -733,6 +728,13 @@ /* Lookup the entry for this handle */ Entry = ExpLookupHandleTableEntry(HandleTable, Handle); + + /* Make sure that we found an entry */ + if (!Entry) + { + /* We didn't, fail */ + return NULL; + } /* Get an available lock and acquire it */ i = ((OldValue & FREE_HANDLE_MASK) >> 2) % 4;
16 years, 4 months
1
0
0
0
[jmorlan] 35041: - Implement GenerateConsoleCtrlEvent. - Remove IgnoreCtrlEvents variable (which ConsoleControlDispatcher did not actually use); set ProcessParameters->ConsoleFlags instead. Despite the name "ConsoleFlags", SetConsoleCtrlHandler treats it like a boolean. - Preserve all 16 bits of the attribute set by SetConsoleTextAttribute. Even though the upper byte does not affect text colors, it should be retrievable with GetConsoleScreenBufferInfo. - Update OpenConsoleW prototype in kernel32
by jmorlan@svn.reactos.org
Author: jmorlan Date: Sat Aug 2 12:01:22 2008 New Revision: 35041 URL:
http://svn.reactos.org/svn/reactos?rev=35041&view=rev
Log: - Implement GenerateConsoleCtrlEvent. - Remove IgnoreCtrlEvents variable (which ConsoleControlDispatcher did not actually use); set ProcessParameters->ConsoleFlags instead. Despite the name "ConsoleFlags", SetConsoleCtrlHandler treats it like a boolean. - Preserve all 16 bits of the attribute set by SetConsoleTextAttribute. Even though the upper byte does not affect text colors, it should be retrievable with GetConsoleScreenBufferInfo. - Update OpenConsoleW prototype in kernel32.h to match the change made in r34694. Modified: trunk/reactos/dll/win32/kernel32/include/kernel32.h trunk/reactos/dll/win32/kernel32/misc/console.c trunk/reactos/include/reactos/subsys/csrss/csrss.h trunk/reactos/subsystems/win32/csrss/api/process.c trunk/reactos/subsystems/win32/csrss/include/api.h trunk/reactos/subsystems/win32/csrss/include/conio.h trunk/reactos/subsystems/win32/csrss/win32csr/conio.c trunk/reactos/subsystems/win32/csrss/win32csr/dllmain.c Modified: trunk/reactos/dll/win32/kernel32/include/kernel32.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/kernel32/include…
============================================================================== --- trunk/reactos/dll/win32/kernel32/include/kernel32.h [iso-8859-1] (original) +++ trunk/reactos/dll/win32/kernel32/include/kernel32.h [iso-8859-1] Sat Aug 2 12:01:22 2008 @@ -69,7 +69,7 @@ HANDLE STDCALL OpenConsoleW (LPCWSTR wsName, DWORD dwDesiredAccess, BOOL bInheritHandle, - DWORD dwCreationDistribution); + DWORD dwShareMode); PTEB GetTeb(VOID); Modified: trunk/reactos/dll/win32/kernel32/misc/console.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/kernel32/misc/co…
============================================================================== --- trunk/reactos/dll/win32/kernel32/misc/console.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/kernel32/misc/console.c [iso-8859-1] Sat Aug 2 12:01:22 2008 @@ -26,8 +26,6 @@ extern BOOL WINAPI IsDebuggerPresent(VOID); /* GLOBALS *******************************************************************/ - -static BOOL IgnoreCtrlEvents = FALSE; static PHANDLER_ROUTINE* CtrlHandlers = NULL; static ULONG NrCtrlHandlers = 0; @@ -3141,7 +3139,7 @@ CsrRequest = MAKE_CSR_API(SET_ATTRIB, CSR_CONSOLE); Request.Data.SetAttribRequest.ConsoleHandle = hConsoleOutput; - Request.Data.SetAttribRequest.Attrib = (CHAR)wAttributes; + Request.Data.SetAttribRequest.Attrib = wAttributes; Status = CsrClientCallServer( &Request, NULL, CsrRequest, sizeof( CSR_API_MESSAGE ) ); if( !NT_SUCCESS( Status ) || !NT_SUCCESS( Status = Request.Status ) ) { @@ -3157,7 +3155,7 @@ { if (HandlerRoutine == NULL) { - IgnoreCtrlEvents = TRUE; + NtCurrentPeb()->ProcessParameters->ConsoleFlags = TRUE; return(TRUE); } else @@ -3193,7 +3191,7 @@ if (HandlerRoutine == NULL) { - IgnoreCtrlEvents = FALSE; + NtCurrentPeb()->ProcessParameters->ConsoleFlags = FALSE; return(TRUE); } else @@ -3245,7 +3243,7 @@ /*-------------------------------------------------------------- * GenerateConsoleCtrlEvent * - * @unimplemented + * @implemented */ BOOL WINAPI GenerateConsoleCtrlEvent( @@ -3253,9 +3251,30 @@ DWORD dwProcessGroupId ) { - DPRINT1("GenerateConsoleCtrlEvent(0x%x, 0x%x) UNIMPLEMENTED!\n", dwCtrlEvent, dwProcessGroupId); - SetLastError(ERROR_CALL_NOT_IMPLEMENTED); - return FALSE; + CSR_API_MESSAGE Request; + ULONG CsrRequest; + NTSTATUS Status; + + if (dwCtrlEvent != CTRL_C_EVENT && dwCtrlEvent != CTRL_BREAK_EVENT) + { + SetLastError(ERROR_INVALID_PARAMETER); + return FALSE; + } + + CsrRequest = MAKE_CSR_API(GENERATE_CTRL_EVENT, CSR_CONSOLE); + Request.Data.GenerateCtrlEvent.Event = dwCtrlEvent; + Request.Data.GenerateCtrlEvent.ProcessGroup = dwProcessGroupId; + Status = CsrClientCallServer(&Request, + NULL, + CsrRequest, + sizeof(CSR_API_MESSAGE)); + if(!NT_SUCCESS(Status) || !(NT_SUCCESS(Status = Request.Status))) + { + SetLastErrorByStatus(Status); + return FALSE; + } + + return TRUE; } Modified: trunk/reactos/include/reactos/subsys/csrss/csrss.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/subsys/csr…
============================================================================== --- trunk/reactos/include/reactos/subsys/csrss/csrss.h [iso-8859-1] (original) +++ trunk/reactos/include/reactos/subsys/csrss/csrss.h [iso-8859-1] Sat Aug 2 12:01:22 2008 @@ -163,7 +163,7 @@ typedef struct { HANDLE ConsoleHandle; - CHAR Attrib; + WORD Attrib; } CSRSS_SET_ATTRIB, *PCSRSS_SET_ATTRIB; typedef struct @@ -459,6 +459,12 @@ { DWORD Length; } CSRSS_GET_CONSOLE_ALIASES_EXES_LENGTH, *PCSRSS_GET_CONSOLE_ALIASES_EXES_LENGTH; + +typedef struct +{ + DWORD Event; + DWORD ProcessGroup; +} CSRSS_GENERATE_CTRL_EVENT, *PCSRSS_GENERATE_CTRL_EVENT; @@ -537,6 +543,7 @@ #define GET_ALL_CONSOLE_ALIASES_LENGTH (0x3B) #define GET_CONSOLE_ALIASES_EXES (0x3C) #define GET_CONSOLE_ALIASES_EXES_LENGTH (0x3D) +#define GENERATE_CTRL_EVENT (0x3E) /* Keep in sync with definition below. */ #define CSRSS_HEADER_SIZE (sizeof(PORT_MESSAGE) + sizeof(ULONG) + sizeof(NTSTATUS)) @@ -608,6 +615,7 @@ CSRSS_GET_ALL_CONSOLE_ALIASES_LENGTH GetAllConsoleAliasesLength; CSRSS_GET_CONSOLE_ALIASES_EXES GetConsoleAliasesExes; CSRSS_GET_CONSOLE_ALIASES_EXES_LENGTH GetConsoleAliasesExesLength; + CSRSS_GENERATE_CTRL_EVENT GenerateCtrlEvent; } Data; } CSR_API_MESSAGE, *PCSR_API_MESSAGE; Modified: trunk/reactos/subsystems/win32/csrss/api/process.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/csrss/api…
============================================================================== --- trunk/reactos/subsystems/win32/csrss/api/process.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/csrss/api/process.c [iso-8859-1] Sat Aug 2 12:01:22 2008 @@ -242,6 +242,15 @@ } } + if (Request->Data.CreateProcessRequest.Flags & CREATE_NEW_PROCESS_GROUP) + { + NewProcessData->ProcessGroup = (DWORD)NewProcessData->ProcessId; + } + else + { + NewProcessData->ProcessGroup = ProcessData->ProcessGroup; + } + /* Set default shutdown parameters */ NewProcessData->ShutdownLevel = 0x280; NewProcessData->ShutdownFlags = 0; Modified: trunk/reactos/subsystems/win32/csrss/include/api.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/csrss/inc…
============================================================================== --- trunk/reactos/subsystems/win32/csrss/include/api.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/csrss/include/api.h [iso-8859-1] Sat Aug 2 12:01:22 2008 @@ -48,6 +48,7 @@ ULONG HandleTableSize; PCSRSS_HANDLE HandleTable; HANDLE ProcessId; + DWORD ProcessGroup; HANDLE Process; ULONG ShutdownLevel; ULONG ShutdownFlags; Modified: trunk/reactos/subsystems/win32/csrss/include/conio.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/csrss/inc…
============================================================================== --- trunk/reactos/subsystems/win32/csrss/include/conio.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/csrss/include/conio.h [iso-8859-1] Sat Aug 2 12:01:22 2008 @@ -41,7 +41,7 @@ USHORT ShowX, ShowY; /* beginning offset for the actual display area */ ULONG CurrentX; /* Current X cursor position */ ULONG CurrentY; /* Current Y cursor position */ - BYTE DefaultAttrib; /* default char attribute */ + WORD DefaultAttrib; /* default char attribute */ USHORT VirtualY; /* top row of buffer being displayed, reported to callers */ CONSOLE_CURSOR_INFO CursorInfo; USHORT Mode; @@ -135,6 +135,7 @@ CSR_API(CsrGetConsoleOutputCodePage); CSR_API(CsrSetConsoleOutputCodePage); CSR_API(CsrGetProcessList); +CSR_API(CsrGenerateCtrlEvent); #define ConioInitScreenBuffer(Console, Buff) (Console)->Vtbl->InitScreenBuffer((Console), (Buff)) #define ConioDrawRegion(Console, Region) (Console)->Vtbl->DrawRegion((Console), (Region)) Modified: trunk/reactos/subsystems/win32/csrss/win32csr/conio.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/csrss/win…
============================================================================== --- trunk/reactos/subsystems/win32/csrss/win32csr/conio.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/csrss/win32csr/conio.c [iso-8859-1] Sat Aug 2 12:01:22 2008 @@ -3129,4 +3129,40 @@ return Request->Status = STATUS_SUCCESS; } +CSR_API(CsrGenerateCtrlEvent) +{ + PCSRSS_CONSOLE Console; + PCSRSS_PROCESS_DATA current; + PLIST_ENTRY current_entry; + DWORD Group; + NTSTATUS Status; + + Request->Header.u1.s1.TotalLength = sizeof(CSR_API_MESSAGE); + Request->Header.u1.s1.DataLength = sizeof(CSR_API_MESSAGE) - sizeof(PORT_MESSAGE); + + Status = ConioConsoleFromProcessData(ProcessData, &Console); + if (! NT_SUCCESS(Status)) + { + return Request->Status = Status; + } + + Group = Request->Data.GenerateCtrlEvent.ProcessGroup; + Status = STATUS_INVALID_PARAMETER; + for (current_entry = Console->ProcessList.Flink; + current_entry != &Console->ProcessList; + current_entry = current_entry->Flink) + { + current = CONTAINING_RECORD(current_entry, CSRSS_PROCESS_DATA, ProcessEntry); + if (Group == 0 || current->ProcessGroup == Group) + { + ConioConsoleCtrlEvent(Request->Data.GenerateCtrlEvent.Event, current); + Status = STATUS_SUCCESS; + } + } + + ConioUnlockConsole(Console); + + return Request->Status = Status; +} + /* EOF */ Modified: trunk/reactos/subsystems/win32/csrss/win32csr/dllmain.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/csrss/win…
============================================================================== --- trunk/reactos/subsystems/win32/csrss/win32csr/dllmain.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/csrss/win32csr/dllmain.c [iso-8859-1] Sat Aug 2 12:01:22 2008 @@ -74,6 +74,7 @@ CSRSS_DEFINE_API(GET_ALL_CONSOLE_ALIASES_LENGTH, CsrGetAllConsoleAliasesLength), CSRSS_DEFINE_API(GET_CONSOLE_ALIASES_EXES, CsrGetConsoleAliasesExes), CSRSS_DEFINE_API(GET_CONSOLE_ALIASES_EXES_LENGTH, CsrGetConsoleAliasesExesLength), + CSRSS_DEFINE_API(GENERATE_CTRL_EVENT, CsrGenerateCtrlEvent), { 0, 0, NULL } };
16 years, 4 months
1
0
0
0
[hpoussin] 35040: Add lots of missing functions to LSA RPC interface Fix existing ones to have same prototypes as MS Windows
by hpoussin@svn.reactos.org
Author: hpoussin Date: Sat Aug 2 10:45:59 2008 New Revision: 35040 URL:
http://svn.reactos.org/svn/reactos?rev=35040&view=rev
Log: Add lots of missing functions to LSA RPC interface Fix existing ones to have same prototypes as MS Windows Modified: trunk/reactos/dll/win32/advapi32/sec/lsa.c trunk/reactos/dll/win32/lsasrv/lsarpc.c trunk/reactos/dll/win32/lsasrv/lsasrv.rbuild trunk/reactos/include/reactos/idl/lsa.idl Modified: trunk/reactos/dll/win32/advapi32/sec/lsa.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/advapi32/sec/lsa…
============================================================================== --- trunk/reactos/dll/win32/advapi32/sec/lsa.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/advapi32/sec/lsa.c [iso-8859-1] Sat Aug 2 10:45:59 2008 @@ -93,7 +93,7 @@ LSAHandleBind(); return LsarClose(LSABindingHandle, - (unsigned long)ObjectHandle); + (unsigned long *)&ObjectHandle); } Modified: trunk/reactos/dll/win32/lsasrv/lsarpc.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/lsasrv/lsarpc.c?…
============================================================================== --- trunk/reactos/dll/win32/lsasrv/lsarpc.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/lsasrv/lsarpc.c [iso-8859-1] Sat Aug 2 10:45:59 2008 @@ -8,8 +8,7 @@ #include "lsa_s.h" -#define NDEBUG -#include <debug.h> +#include <wine/debug.h> #define POLICY_DELETE (RTL_HANDLE_VALID << 1) typedef struct _LSAR_POLICY_HANDLE @@ -22,10 +21,12 @@ static RTL_CRITICAL_SECTION PolicyHandleTableLock; static RTL_HANDLE_TABLE PolicyHandleTable; +WINE_DEFAULT_DEBUG_CHANNEL(lsasrv); + /* FUNCTIONS ***************************************************************/ -static NTSTATUS -ReferencePolicyHandle(IN LSA_HANDLE ObjectHandle, +/*static*/ NTSTATUS +ReferencePolicyHandle(IN LSAPR_HANDLE ObjectHandle, IN ACCESS_MASK DesiredAccess, OUT PLSAR_POLICY_HANDLE *Policy) { @@ -56,7 +57,7 @@ return Status; } -static VOID +/*static*/ VOID DereferencePolicyHandle(IN OUT PLSAR_POLICY_HANDLE Policy, IN BOOLEAN Delete) { @@ -90,7 +91,7 @@ sizeof(LSAR_POLICY_HANDLE), &PolicyHandleTable); - DPRINT("LsarStartRpcServer() called"); + TRACE("LsarStartRpcServer() called"); Status = RpcServerUseProtseqEpW(L"ncacn_np", 10, @@ -98,7 +99,7 @@ NULL); if (Status != RPC_S_OK) { - DPRINT1("RpcServerUseProtseqEpW() failed (Status %lx)\n", Status); + WARN("RpcServerUseProtseqEpW() failed (Status %lx)\n", Status); return; } @@ -107,31 +108,33 @@ NULL); if (Status != RPC_S_OK) { - DPRINT1("RpcServerRegisterIf() failed (Status %lx)\n", Status); + WARN("RpcServerRegisterIf() failed (Status %lx)\n", Status); return; } Status = RpcServerListen(1, 20, TRUE); if (Status != RPC_S_OK) { - DPRINT1("RpcServerListen() failed (Status %lx)\n", Status); + WARN("RpcServerListen() failed (Status %lx)\n", Status); return; } - DPRINT("LsarStartRpcServer() done\n"); -} + TRACE("LsarStartRpcServer() done\n"); +} + /* Function 0 */ -NTSTATUS -LsarClose(IN handle_t BindingHandle, - IN unsigned long ObjectHandle) -{ +NTSTATUS LsarClose( + handle_t hBinding, + LSAPR_HANDLE *ObjectHandle) +{ +#if 0 PLSAR_POLICY_HANDLE Policy = NULL; NTSTATUS Status; - DPRINT("LsarClose(0x%p) called!\n", ObjectHandle); - - Status = ReferencePolicyHandle((LSA_HANDLE)ObjectHandle, + TRACE("0x%p\n", ObjectHandle); + + Status = ReferencePolicyHandle(*ObjectHandle, 0, &Policy); if (NT_SUCCESS(Status)) @@ -142,15 +145,974 @@ } return Status; -} +#endif + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + /* Function 1 */ -NTSTATUS -LsarDelete(IN handle_t BindingHandle, - IN unsigned long ObjectHandle) -{ - DPRINT1("LsarDelete(0x%p) UNIMPLEMENTED!\n", ObjectHandle); - return STATUS_ACCESS_DENIED; -} +NTSTATUS LsarDelete( + handle_t hBinding, + LSAPR_HANDLE ObjectHandle) +{ + /* Deprecated */ + return STATUS_NOT_SUPPORTED; +} + + +/* Function 2 */ +NTSTATUS LsarEnumeratePrivileges( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + DWORD *EnumerationContext, + PLSAPR_PRIVILEGE_ENUM_BUFFER EnumerationBuffer, + DWORD PreferedMaximumLength) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 3 */ +NTSTATUS LsarQuerySecurityObject( + handle_t hBinding, + LSAPR_HANDLE ObjectHandle, + SECURITY_INFORMATION SecurityInformation, + PLSAPR_SR_SECURITY_DESCRIPTOR *SecurityDescriptor) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 4 */ +NTSTATUS LsarSetSecurityObject( + handle_t hBinding, + LSAPR_HANDLE ObjectHandle, + SECURITY_INFORMATION SecurityInformation, + PLSAPR_SR_SECURITY_DESCRIPTOR SecurityDescriptor) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 5 */ +NTSTATUS LsarChangePassword( + handle_t hBinding, + PRPC_UNICODE_STRING String1, + PRPC_UNICODE_STRING String2, + PRPC_UNICODE_STRING String3, + PRPC_UNICODE_STRING String4, + PRPC_UNICODE_STRING String5) +{ + /* Deprecated */ + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 6 */ +NTSTATUS LsarOpenPolicy( + handle_t hBinding, + LPWSTR SystemName, + PLSAPR_OBJECT_ATTRIBUTES ObjectAttributes, + ACCESS_MASK DesiredAccess, + LSAPR_HANDLE *PolicyHandle) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 7 */ +NTSTATUS LsarQueryInformationPolicy( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + POLICY_INFORMATION_CLASS InformationClass, + unsigned long PolicyInformation) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 8 */ +NTSTATUS LsarSetInformationPolicy( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + POLICY_INFORMATION_CLASS InformationClass, + unsigned long *PolicyInformation) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 9 */ +NTSTATUS LsarClearAuditLog( + handle_t hBinding, + LSAPR_HANDLE ObjectHandle) +{ + /* Deprecated */ + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 10 */ +NTSTATUS LsarCreateAccount( + handle_t hBinding, + PRPC_SID AccountSid, + ACCESS_MASK DesiredAccess, + LSAPR_HANDLE *AccountHandle) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 11 */ +NTSTATUS LsarEnumerateAccounts( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + DWORD *EnumerationContext, + PLSAPR_ACCOUNT_ENUM_BUFFER EnumerationBuffer, + DWORD PreferedMaximumLength) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 12 */ +NTSTATUS LsarCreateTrustedDomain( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PLSAPR_TRUST_INFORMATION TrustedDomainInformation, + ACCESS_MASK DesiredAccess, + LSAPR_HANDLE *TrustedDomainHandle) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 13 */ +NTSTATUS LsarEnumerateTrustedDomains( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + DWORD *EnumerationContext, + PLSAPR_TRUSTED_ENUM_BUFFER EnumerationBuffer, + DWORD PreferedMaximumLength) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 14 */ +NTSTATUS LsarLookupNames( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + DWORD Count, + PRPC_UNICODE_STRING Names, + PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + PLSAPR_TRANSLATED_SIDS TranslatedSids, + LSAP_LOOKUP_LEVEL LookupLevel, + DWORD *MappedCount) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 15 */ +NTSTATUS LsarLookupSids( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PLSAPR_SID_ENUM_BUFFER SidEnumBuffer, + PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + PLSAPR_TRANSLATED_NAMES TranslatedNames, + LSAP_LOOKUP_LEVEL LookupLevel, + DWORD *MappedCount) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 16 */ +NTSTATUS LsarCreateSecret( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_UNICODE_STRING SecretName, + ACCESS_MASK DesiredAccess, + LSAPR_HANDLE *SecretHandle) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 17 */ +NTSTATUS LsarOpenAccount( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_SID AccountSid, + ACCESS_MASK DesiredAccess, + LSAPR_HANDLE *AccountHandle) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 18 */ +NTSTATUS LsarEnumeratePrivilegesAccount( + handle_t hBinding, + LSAPR_HANDLE AccountHandle, + PLSAPR_PRIVILEGE_SET *Privileges) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 19 */ +NTSTATUS LsarAddPrivilegesToAccount( + handle_t hBinding, + LSAPR_HANDLE AccountHandle, + PLSAPR_PRIVILEGE_SET Privileges) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 20 */ +NTSTATUS LsarRemovePrivilegesFromAccount( + handle_t hBinding, + LSAPR_HANDLE AccountHandle, + BOOL AllPrivileges, + PLSAPR_PRIVILEGE_SET Privileges) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 21 */ +NTSTATUS LsarGetQuotasForAccount( + handle_t hBinding, + LSAPR_HANDLE AccountHandle, + PQUOTA_LIMITS QuotaLimits) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 22 */ +NTSTATUS LsarSetQuotasForAccount( + handle_t hBinding, + LSAPR_HANDLE AccountHandle, + PQUOTA_LIMITS QuotaLimits) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 23 */ +NTSTATUS LsarGetSystemAccessAccount( + handle_t hBinding, + LSAPR_HANDLE AccountHandle, + ACCESS_MASK *SystemAccess) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 24 */ +NTSTATUS LsarSetSystemAccessAccount( + handle_t hBinding, + LSAPR_HANDLE AccountHandle, + ACCESS_MASK SystemAccess) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 25 */ +NTSTATUS LsarOpenTrustedDomain( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_SID TrustedDomainSid, + ACCESS_MASK DesiredAccess, + LSAPR_HANDLE *TrustedDomainHandle) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 26 */ +NTSTATUS LsarQueryInfoTrustedDomain( + handle_t hBinding, + LSAPR_HANDLE TrustedDomainHandle, + TRUSTED_INFORMATION_CLASS InformationClass, + PLSAPR_TRUSTED_DOMAIN_INFO *TrustedDomainInformation) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 27 */ +NTSTATUS LsarSetInformationTrustedDomain( + handle_t hBinding, + LSAPR_HANDLE TrustedDomainHandle, + TRUSTED_INFORMATION_CLASS InformationClass, + PLSAPR_TRUSTED_DOMAIN_INFO TrustedDomainInformation) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 28 */ +NTSTATUS LsarOpenSecret( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_UNICODE_STRING SecretName, + ACCESS_MASK DesiredAccess, + LSAPR_HANDLE *SecretHandle) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 29 */ +NTSTATUS LsarSetSecret( + handle_t hBinding, + LSAPR_HANDLE *SecretHandle, + PLSAPR_CR_CIPHER_VALUE EncryptedCurrentValue, + PLSAPR_CR_CIPHER_VALUE EncryptedOldValue) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 30 */ +NTSTATUS LsarQuerySecret( + handle_t hBinding, + LSAPR_HANDLE SecretHandle, + PLSAPR_CR_CIPHER_VALUE *EncryptedCurrentValue, + PLARGE_INTEGER CurrentValueSetTime, + PLSAPR_CR_CIPHER_VALUE *EncryptedOldValue, + PLARGE_INTEGER OldValueSetTime) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 31 */ +NTSTATUS LsarLookupPrivilegeValue( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_UNICODE_STRING Name, + PLUID Value) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 32 */ +NTSTATUS LsarLookupPrivilegeName( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PLUID Value, + PRPC_UNICODE_STRING *Name) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 33 */ +NTSTATUS LsarLookupPrivilegeDisplayName( + handle_t hBinding, + USHORT *LanguageReturned) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 34 */ +NTSTATUS LsarDeleteObject( + handle_t hBinding, + LSAPR_HANDLE *ObjectHandle) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 35 */ +NTSTATUS LsarEnumerateAccountsWithUserRight( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_UNICODE_STRING UserRight, + PLSAPR_ACCOUNT_ENUM_BUFFER EnumerationBuffer) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 36 */ +NTSTATUS LsarEnmuerateAccountRights( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_SID AccountSid, + PLSAPR_USER_RIGHT_SET UserRights) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 37 */ +NTSTATUS LsarAddAccountRights( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_SID AccountSid, + PLSAPR_USER_RIGHT_SET UserRights) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 38 */ +NTSTATUS LsarRemoveAccountRights( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_SID AccountSid, + BOOL AllRights, + PLSAPR_USER_RIGHT_SET UserRights) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 39 */ +NTSTATUS LsarQueryTrustedDomainInfo( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_SID TrustedDomainSid, + TRUSTED_INFORMATION_CLASS InformationClass, + PLSAPR_TRUSTED_DOMAIN_INFO *TrustedDomainInformation) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 40 */ +NTSTATUS LsarSetTrustedDomainInfo( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_SID TrustedDomainSid, + TRUSTED_INFORMATION_CLASS InformationClass, + PLSAPR_TRUSTED_DOMAIN_INFO TrustedDomainInformation) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 41 */ +NTSTATUS LsarDeleteTrustedDomain( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_SID TrustedDomainSid) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 42 */ +NTSTATUS LsarStorePrivateData( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_UNICODE_STRING KeyName, + PLSAPR_CR_CIPHER_VALUE EncryptedData) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 43 */ +NTSTATUS LsarRetrievePrivateData( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_UNICODE_STRING KeyName, + PLSAPR_CR_CIPHER_VALUE *EncryptedData) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 44 */ +NTSTATUS LsarOpenPolicy2( + handle_t hBinding, + LPWSTR SystemName, + PLSAPR_OBJECT_ATTRIBUTES ObjectAttributes, + ACCESS_MASK DesiredAccess, + LSAPR_HANDLE *PolicyHandle) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 45 */ +NTSTATUS LsarGetUserName( + handle_t hBinding, + LPWSTR SystemName, + PRPC_UNICODE_STRING *UserName, + PRPC_UNICODE_STRING *DomainName) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 46 */ +NTSTATUS LsarQueryInformationPolicy2( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + POLICY_INFORMATION_CLASS InformationClass, + unsigned long *PolicyInformation) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 47 */ +NTSTATUS LsarSetInformationPolicy2( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + POLICY_INFORMATION_CLASS InformationClass, + unsigned long PolicyInformation) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 48 */ +NTSTATUS LsarQueryTrustedDomainInfoByName( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_UNICODE_STRING TrustedDomainName, + POLICY_INFORMATION_CLASS InformationClass, + unsigned long *PolicyInformation) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 49 */ +NTSTATUS LsarSetTrustedDomainInfoByName( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_UNICODE_STRING TrustedDomainName, + POLICY_INFORMATION_CLASS InformationClass, + unsigned long PolicyInformation) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 50 */ +NTSTATUS LsarEnumerateTrustedDomainsEx( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + DWORD *EnumerationContext, + PLSAPR_TRUSTED_ENUM_BUFFER_EX EnumerationBuffer, + DWORD PreferedMaximumLength) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 51 */ +NTSTATUS LsarCreateTrustedDomainEx( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PLSAPR_TRUSTED_DOMAIN_INFORMATION_EX TrustedDomainInformation, + PLSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION AuthentificationInformation, + ACCESS_MASK DesiredAccess, + LSAPR_HANDLE *TrustedDomainHandle) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 52 */ +NTSTATUS LsarSetPolicyReplicationHandle( + handle_t hBinding, + PLSAPR_HANDLE PolicyHandle) +{ + /* Deprecated */ + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 53 */ +NTSTATUS LsarQueryDomainInformationPolicy( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + POLICY_INFORMATION_CLASS InformationClass, + unsigned long *PolicyInformation) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 54 */ +NTSTATUS LsarSetDomainInformationPolicy( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + POLICY_INFORMATION_CLASS InformationClass, + unsigned long PolicyInformation) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 55 */ +NTSTATUS LsarOpenTrustedDomainByName( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PRPC_UNICODE_STRING TrustedDomainName, + ACCESS_MASK DesiredAccess, + LSAPR_HANDLE *TrustedDomainHandle) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 56 */ +NTSTATUS LsarTestCall( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 57 */ +NTSTATUS LsarLookupSids2( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PLSAPR_SID_ENUM_BUFFER SidEnumBuffer, + PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + PLSAPR_TRANSLATED_NAMES_EX TranslatedNames, + LSAP_LOOKUP_LEVEL LookupLevel, + DWORD *MappedCount, + DWORD LookupOptions, + DWORD ClientRevision) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 58 */ +NTSTATUS LsarLookupNames2( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + DWORD Count, + PRPC_UNICODE_STRING Names, + PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + PLSAPR_TRANSLATED_SID_EX TranslatedSids, + LSAP_LOOKUP_LEVEL LookupLevel, + DWORD *MappedCount, + DWORD LookupOptions, + DWORD ClientRevision) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 59 */ +NTSTATUS LsarCreateTrustedDomainEx2( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PLSAPR_TRUSTED_DOMAIN_INFORMATION_EX TrustedDomainInformation, + PLSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION_INTERNAL AuthentificationInformation, + ACCESS_MASK DesiredAccess, + LSAPR_HANDLE *TrustedDomainHandle) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 60 */ +NTSTATUS CredrWrite( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 61 */ +NTSTATUS CredrRead( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 62 */ +NTSTATUS CredrEnumerate( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 63 */ +NTSTATUS CredrWriteDomainCredentials( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 64 */ +NTSTATUS CredrReadDomainCredentials( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 65 */ +NTSTATUS CredrDelete( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 66 */ +NTSTATUS CredrGetTargetInfo( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 67 */ +NTSTATUS CredrProfileLoaded( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 68 */ +NTSTATUS LsarLookupNames3( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + DWORD Count, + PRPC_UNICODE_STRING Names, + PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + PLSAPR_TRANSLATED_SID_EX2 TranslatedSids, + LSAP_LOOKUP_LEVEL LookupLevel, + DWORD *MappedCount, + DWORD LookupOptions, + DWORD ClientRevision) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 69 */ +NTSTATUS CredrGetSessionTypes( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 70 */ +NTSTATUS LsarRegisterAuditEvent( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 71 */ +NTSTATUS LsarGenAuditEvent( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 72 */ +NTSTATUS LsarUnregisterAuditEvent( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 73 */ +NTSTATUS LsarQueryForestTrustInformation( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PLSA_UNICODE_STRING TrustedDomainName, + LSA_FOREST_TRUST_RECORD_TYPE HighestRecordType, + PLSA_FOREST_TRUST_INFORMATION *ForestTrustInfo) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 74 */ +NTSTATUS LsarSetForestTrustInformation( + handle_t hBinding, + LSAPR_HANDLE PolicyHandle, + PLSA_UNICODE_STRING TrustedDomainName, + LSA_FOREST_TRUST_RECORD_TYPE HighestRecordType, + PLSA_FOREST_TRUST_INFORMATION ForestTrustInfo, + BOOL CheckOnly, + PLSA_FOREST_TRUST_COLLISION_INFORMATION *CollisionInfo) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 75 */ +NTSTATUS CredrRename( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 76 */ +NTSTATUS LsarLookupSids3( + handle_t hBinding, + PLSAPR_SID_ENUM_BUFFER SidEnumBuffer, + PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + PLSAPR_TRANSLATED_NAMES_EX TranslatedNames, + LSAP_LOOKUP_LEVEL LookupLevel, + DWORD *MappedCount, + DWORD LookupOptions, + DWORD ClientRevision) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 77 */ +NTSTATUS LsarLookupNames4( + handle_t hBinding, + handle_t RpcHandle, + DWORD Count, + PRPC_UNICODE_STRING Names, + PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + PLSAPR_TRANSLATED_SID_EX2 TranslatedSids, + LSAP_LOOKUP_LEVEL LookupLevel, + DWORD *MappedCount, + DWORD LookupOptions, + DWORD ClientRevision) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 78 */ +NTSTATUS LsarOpenPolicySce( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 79 */ +NTSTATUS LsarAdtRegisterSecurityEventSource( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 80 */ +NTSTATUS LsarAdtUnregisterSecurityEventSource( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + + +/* Function 81 */ +NTSTATUS LsarAdtReportSecurityEvent( + handle_t hBinding) +{ + UNIMPLEMENTED; + return STATUS_NOT_IMPLEMENTED; +} + /* EOF */ Modified: trunk/reactos/dll/win32/lsasrv/lsasrv.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/lsasrv/lsasrv.rb…
============================================================================== --- trunk/reactos/dll/win32/lsasrv/lsasrv.rbuild [iso-8859-1] (original) +++ trunk/reactos/dll/win32/lsasrv/lsasrv.rbuild [iso-8859-1] Sat Aug 2 10:45:59 2008 @@ -5,9 +5,10 @@ <define name="WINVER">0x600</define> <define name="_WIN32_WINNT">0x0600</define> <library>lsa_server</library> - <library>ntdll</library> + <library>wine</library> <library>kernel32</library> <library>rpcrt4</library> + <library>ntdll</library> <library>pseh</library> <file>lsarpc.c</file> <file>lsasrv.c</file> Modified: trunk/reactos/include/reactos/idl/lsa.idl URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/idl/lsa.id…
============================================================================== --- trunk/reactos/include/reactos/idl/lsa.idl [iso-8859-1] (original) +++ trunk/reactos/include/reactos/idl/lsa.idl [iso-8859-1] Sat Aug 2 10:45:59 2008 @@ -2,9 +2,590 @@ * Local Security Authority interface definition */ -#include "include/reactos/idl/wtypes.idl" - -#define LSA_HANDLE unsigned long +#include <ms-dtyp.idl> + +typedef [context_handle] unsigned long LSAPR_HANDLE; +typedef LSAPR_HANDLE *PLSAPR_HANDLE; + +cpp_quote("#ifndef _WINNT_H"); +typedef LARGE_INTEGER LUID; +cpp_quote("#endif"); + +cpp_quote("#ifndef _NTDEF_"); + +typedef long NTSTATUS; + +typedef struct _STRING { + WORD Length; + WORD MaximumLength; + [size_is(MaximumLength), length_is(Length)] LPSTR Buffer; +} STRING, *PSTRING; + +cpp_quote("#endif"); + +typedef struct _LSAPR_ACL { + BYTE AclRevision; + BYTE Sbz1; + WORD AclSize; + [size_is(AclSize - 4)] BYTE Dummy1[*]; +} LSAPR_ACL, *PLSAPR_ACL; + +typedef WORD SECURITY_DESCRIPTOR_CONTROL, *PSECURITY_DESCRIPTOR_CONTROL; + +typedef struct _LSAPR_SECURITY_DESCRIPTOR { + BYTE Revision; + BYTE Sbz1; + SECURITY_DESCRIPTOR_CONTROL Control; + PRPC_SID Owner; + PRPC_SID Group; + PLSAPR_ACL Sacl; + PLSAPR_ACL Dacl; +} LSAPR_SECURITY_DESCRIPTOR, *PLSAPR_SECURITY_DESCRIPTOR; + +cpp_quote("#if 0"); + +typedef enum _SECURITY_IMPERSONATION_LEVEL { + SecurityAnonymous = 0, + SecurityIdentification, + SecurityImpersonation, + SecurityDelegation, +} SECURITY_IMPERSONATION_LEVEL, *PSECURITY_IMPERSONATION_LEVEL; + +typedef BYTE SECURITY_CONTEXT_TRACKING_MODE, *PSECURITY_CONTEXT_TRACKING_MODE; + +typedef struct _SECURITY_QUALITY_OF_SERVICE { + DWORD Length; + SECURITY_IMPERSONATION_LEVEL ImpersonationLevel; + SECURITY_CONTEXT_TRACKING_MODE ContextTrackingMode; + BYTE EffectiveOnly; +} SECURITY_QUALITY_OF_SERVICE, *PSECURITY_QUALITY_OF_SERVICE; + +cpp_quote("#endif"); + +typedef struct _LSAPR_OBJECT_ATTRIBUTES { + DWORD Length; + BYTE *RootDirectory; + PSTRING ObjectName; + DWORD Attributes; + PLSAPR_SECURITY_DESCRIPTOR SecurityDescriptor; + PSECURITY_QUALITY_OF_SERVICE SecurityQualityOfService; +} LSAPR_OBJECT_ATTRIBUTES, *PLSAPR_OBJECT_ATTRIBUTES; + +typedef unsigned long ACCESS_MASK; + +typedef unsigned long SECURITY_INFORMATION; + +typedef struct _LSAPR_POLICY_PRIVILEGE_DEF { + RPC_UNICODE_STRING Name; + LUID LocalValue; +} LSAPR_POLICY_PRIVILEGE_DEF, *PLSAPR_POLICY_PRIVILEGE_DEF; + +typedef struct _LSAPR_PRIVILEGE_ENUM_BUFFER { + DWORD Entries; + [size_is(Entries)] PLSAPR_POLICY_PRIVILEGE_DEF Privileges; +} LSAPR_PRIVILEGE_ENUM_BUFFER, *PLSAPR_PRIVILEGE_ENUM_BUFFER; + +typedef struct _LSAPR_ACCOUNT_INFORMATION { + PRPC_SID Sid; +} LSAPR_ACCOUNT_INFORMATION, *PLSAPR_ACCOUNT_INFORMATION; + +typedef struct _LSAPR_ACCOUNT_ENUM_BUFFER { + DWORD EntriesRead; + [size_is(EntriesRead)] PLSAPR_ACCOUNT_INFORMATION Information; +} LSAPR_ACCOUNT_ENUM_BUFFER, *PLSAPR_ACCOUNT_ENUM_BUFFER; + +cpp_quote("#ifndef _NTSECAPI_H"); +typedef RPC_UNICODE_STRING LSA_UNICODE_STRING, *PLSA_UNICODE_STRING; +cpp_quote("#endif"); + +typedef struct _LSAPR_TRUST_INFORMATION { + RPC_UNICODE_STRING Name; + PRPC_SID Sid; +} LSAPR_TRUST_INFORMATION, *PLSAPR_TRUST_INFORMATION; + +typedef struct _LSAPR_REFERENCED_DOMAIN_LIST { + DWORD Entries; + [size_is(Entries)] PLSAPR_TRUST_INFORMATION Domains; + DWORD MaxEntries; +} LSAPR_REFERENCED_DOMAIN_LIST, *PLSAPR_REFERENCED_DOMAIN_LIST; + +cpp_quote("#if 0"); + +typedef enum _SID_NAME_USE { + SidTypeUser = 1, + SidTypeGroup, + SidTypeDomain, + SidTypeAlias, + SidTypeWellKnownGroup, + SidTypeDeletedAccount, + SidTypeInvalid, + SidTypeUnknown, + SidTypeComputer, + SidTypeLabel, +} SID_NAME_USE, *PSID_NAME_USE; + +cpp_quote("#endif"); + +cpp_quote("#ifndef _NTDEF_"); + +typedef struct _LSA_TRANSLATED_SID { + SID_NAME_USE Use; + DWORD RelativeId; + LONG DomainIndex; +} LSA_TRANSLATED_SID, *PLSA_TRANSLATED_SID; + +cpp_quote("#endif"); + +typedef struct _LSAPR_TRANSLATED_SIDS { + DWORD Entries; + [size_is(Entries)] PLSA_TRANSLATED_SID Sids; +} LSAPR_TRANSLATED_SIDS, *PLSAPR_TRANSLATED_SIDS; + +typedef enum _LSAP_LOOKUP_LEVEL { + LsapLookupWksta = 1, + LsapLookupPDC, + LsapLookupTDL, + LsapLookupGC, + LsapLookupXForestReferral, + LsapLookupXForestResolve, + LsapLookupRODCReferralToFullDC, +} LSAP_LOOKUP_LEVEL, *PLSAP_LOOKUP_LEVEL; + +typedef struct _LSAPR_SID_INFORMATION { + PRPC_SID Sid; +} LSAPR_SID_INFORMATION, *PLSAPR_SID_INFORMATION; + +typedef struct _LSAPR_SID_ENUM_BUFFER { + DWORD Entries; + [size_is(Entries)] PLSAPR_SID_INFORMATION SidInfo; +} LSAPR_SID_ENUM_BUFFER, *PLSAPR_SID_ENUM_BUFFER; + +typedef struct _LSAPR_TRANSLATED_NAME { + SID_NAME_USE Use; + RPC_UNICODE_STRING Name; + LONG DomainIndex; +} LSAPR_TRANSLATED_NAME, *PLSAPR_TRANSLATED_NAME; + +typedef struct _LSAPR_TRANSLATED_NAMES { + DWORD Entries; + [size_is(Entries)] PLSAPR_TRANSLATED_NAME Names; +} LSAPR_TRANSLATED_NAMES, *PLSAPR_TRANSLATED_NAMES; + +typedef struct _LSAPR_TRANSLATED_NAME_EX { + SID_NAME_USE Use; + RPC_UNICODE_STRING Name; + LONG DomainIndex; + DWORD Flags; +} LSAPR_TRANSLATED_NAME_EX, *PLSAPR_TRANSLATED_NAME_EX; + +typedef struct _LSAPR_TRANSLATED_NAMES_EX { + DWORD Entries; + [size_is(Entries)] PLSAPR_TRANSLATED_NAME_EX Names; +} LSAPR_TRANSLATED_NAMES_EX, *PLSAPR_TRANSLATED_NAMES_EX; + +typedef struct _LSAPR_TRANSLATED_SID_EX { + SID_NAME_USE Use; + DWORD RelativeId; + LONG DomainIndex; + DWORD Flags; +} LSAPR_TRANSLATED_SID_EX, *PLSAPR_TRANSLATED_SID_EX; + +typedef struct _LSAPR_TRANSLATED_SIDS_EX { + DWORD Entries; + [size_is(Entries)] PLSAPR_TRANSLATED_SID_EX Sids; +} LSAPR_TRANSLATED_SIDS_EX, *PLSAPR_TRANSLATED_SIDS_EX; + +typedef struct _LSAPR_TRANSLATED_SID_EX2 { + SID_NAME_USE Use; + PRPC_SID Sid; + LONG DomainIndex; + DWORD Flags; +} LSAPR_TRANSLATED_SID_EX2, *PLSAPR_TRANSLATED_SID_EX2; + +typedef struct _LSAPR_TRANSLATED_SIDS_EX2 { + DWORD Entries; + [size_is(Entries)] PLSAPR_TRANSLATED_SID_EX2 Sids; +} LSAPR_TRANSLATED_SIDS_EX2, *PLSAPR_TRANSLATED_SIDS_EX2; + +typedef LSAPR_TRUST_INFORMATION LSAPR_TRUSTED_DOMAIN_INFORMATION_BASIC; + +typedef struct _LSAPR_SR_SECURITY_DESCRIPTOR { + DWORD Length; + [size_is(Length)] BYTE *SecurityDescriptor; +} LSAPR_SR_SECURITY_DESCRIPTOR, *PLSAPR_SR_SECURITY_DESCRIPTOR; + +cpp_quote("#ifndef _NTSECAPI_H"); +typedef enum _POLICY_INFORMATION_CLASS { + PolicyAuditLogInformation = 1, + PolicyAuditEventsInformation, + PolicyPrimaryDomainInformation, + PolicyPdAccountInformation, + PolicyAccountDomainInformation, + PolicyLsaServerRoleInformation, + PolicyReplicaSourceInformation, + PolicyDefaultQuotaInformation, + PolicyModificationInformation, + PolicyAuditFullSetInformation, + PolicyAuditFullQueryInformation, + PolicyDnsDomainInformation, + PolicyDnsDomainInformationInt, + PolicyLocalAccountDomainInformation, + PolicyLastEntry, +} POLICY_INFORMATION_CLASS, *PPOLICY_INFORMATION_CLASS; + +typedef struct _POLICY_AUDIT_LOG_INFO { + DWORD AuditLogPercentFull; + DWORD MaximumLogSize; + LARGE_INTEGER AuditRetentionPeriod; + BYTE AuditLogFullShutdownInProgress; + LARGE_INTEGER TimeToShutdown; + DWORD NextAuditRecordId; +} POLICY_AUDIT_LOG_INFO, *PPOLICY_AUDIT_LOG_INFO; +cpp_quote("#endif"); + +typedef struct _LSAPR_POLICY_AUDIT_EVENTS_INFO { + BYTE AuditingMode; + [size_is(MaximumAuditEventCount)] DWORD *EventAuditingOptions; + DWORD MaximumAuditEventCount; +} LSAPR_POLICY_AUDIT_EVENTS_INFO, *PLSAPR_POLICY_AUDIT_EVENTS_INFO; + +typedef struct _LSAPR_POLICY_PRIMARY_DOM_INFO { + RPC_UNICODE_STRING Name; + PRPC_SID Sid; +} LSAPR_POLICY_PRIMARY_DOM_INFO, *PLSAPR_POLICY_PRIMARY_DOM_INFO; + +typedef struct _LSAPR_POLICY_ACCOUNT_DOM_INFO { + RPC_UNICODE_STRING DomainName; + PRPC_SID Sid; +} LSAPR_POLICY_ACCOUNT_DOM_INFO, *PLSAPR_POLICY_ACCOUNT_DOM_INFO; + +typedef struct _LSAPR_POLICY_PD_ACCOUNT_INFO { + RPC_UNICODE_STRING Name; +} LSAPR_POLICY_PD_ACCOUNT_INFO, *PLSAPR_POLICY_PD_ACCOUNT_INFO; + +cpp_quote("#ifndef _NTSECAPI_H"); +typedef enum _POLICY_LSA_SERVER_ROLE { + PolicyServerRoleBackup = 2, + PolicyServerRolePrimary, +} POLICY_LSA_SERVER_ROLE, *PPOLICY_LSA_SERVER_ROLE; + +typedef struct _POLICY_LSA_SERVER_ROLE_INFO { + POLICY_LSA_SERVER_ROLE LsaServerRole; +} POLICY_LSA_SERVER_ROLE_INFO, *PPOLICY_LSA_SERVER_ROLE_INFO; +cpp_quote("#endif"); + +typedef struct _POLICY_LSA_REPLICA_SRCE_INFO { + RPC_UNICODE_STRING ReplicaSource; + RPC_UNICODE_STRING ReplicaAccountName; +} POLICY_LSA_REPLICA_SRCE_INFO, *PPOLICY_LSA_REPLICA_SRCE_INFO; + +cpp_quote("#ifndef _WINNT_H"); +typedef struct _QUOTA_LIMITS { + INT64 PagedPoolLimit; + INT64 NonPagedPoolLimit; + INT64 MinimumWorkingSetSize; + INT64 MaximumWorkingSetSize; + INT64 PagefileLimit; + LARGE_INTEGER TimeLimit; +} QUOTA_LIMITS, *PQUOTA_LIMITS; +cpp_quote("#endif"); + +cpp_quote("#ifndef _NTSECAPI_H"); +typedef struct _POLICY_DEFAULT_QUOTA_INFO { + QUOTA_LIMITS QuotaLimits; +} POLICY_DEFAULT_QUOTA_INFO, *PPOLICY_DEFAULT_QUOTA_INFO; + +typedef struct _POLICY_MODIFICATION_INFO { + LARGE_INTEGER ModifiedId; + LARGE_INTEGER DatabaseCreationTime; +} POLICY_MODIFICATION_INFO, *PPOLICY_MODIFICATION_INFO; +cpp_quote("#endif"); + +typedef struct _POLICY_FULL_SET_INFO { + BOOL ShutDownOnFull; +} POLICY_FULL_SET_INFO, *PPOLICY_FULL_SET_INFO; + +cpp_quote("#ifndef _NTSECAPI_H"); +typedef struct _POLICY_AUDIT_FULL_QUERY_INFO { + BOOL ShutDownOnFull; + BOOL LogIsFull; +} POLICY_AUDIT_FULL_QUERY_INFO, *PPOLICY_AUDIT_FULL_QUERY_INFO; +cpp_quote("#endif"); + +typedef struct _LSAPR_POLICY_DNS_DOMAIN_INFO { + RPC_UNICODE_STRING Name; + RPC_UNICODE_STRING DnsDomainName; + RPC_UNICODE_STRING DnsForestName; + GUID DomainGuid; + PRPC_SID Sid; +} LSAPR_POLICY_DNS_DOMAIN_INFO, *PLSAPR_POLICY_DNS_DOMAIN_INFO; + +/*typedef +[switch_type(POLICY_INFORMATION_CLASS)] union _LSAPR_POLICY_INFORMATION { + [case(PolicyAuditLogInformation)] POLICY_AUDIT_LOG_INFO PolicyAuditLogInfo; + [case(PolicyAuditEventsInformation)] POLICY_AUDIT_EVENTS_INFO PolicyAuditEventsInfo; + [case(PolicyPrimaryDomainInformation)] POLICY_PRIMARY_DOM_INFO PolicyPrimaryDomInfo; + [case(PolicyPdAccountInformation)] POLICY_PD_ACCOUNT_INFO PolicyPdAccountInfo; + [case(PolicyAccountDomainInformation)] POLICY_ACCOUNT_DOM_INFO PolicyAccountDomainInfo; + [case(PolicyLsaServerRoleInformation)] POLICY_LSA_SERVER_ROLE_INFO PolicyServerRoleInfo; + [case(PolicyReplicaSourceInformation)] POLICY_REPLICA_SRCE_INFO PolicyReplicaSourceInfo; + [case(PolicyDefaultQuotaInformation)] POLICY_DEFAULT_QUOTA_INFO PolicyDefaultQuotaInfo; + [case(PolicyModificationInformation)] POLICY_MODIFICATION_INFO PolicyModificationInfo; + [case(PolicyAuditFullSetInformation)] POLICY_AUDIT_FULL_SET_INFO PolicyAuditFullSetInfo; + [case(PolicyAuditFullQueryInformation)] POLICY_AUDIT_FULL_QUERY_INFO PolicyAuditFullQueryInfo; + [case(PolicyDnsDomainInformation)] LSAPR_DNS_DOMAIN_INFO PolicyDnsDomainInfo; + [case(PolicyDnsDomainInformationInt)] LSAPR_DNS_DOMAIN_INFO PolicyDnsDomainInfoInt; + [case(PolicyLocalAccountDomainInformation)] LSAPR_POLICY_ACCOUNT_DOM_INFO PolicyLocalAccountDomainInfo; +} LSAPR_POLICY_INFORMATION, *PLSAPR_POLICY_INFORMATION;*/ + +typedef struct _LSAPR_TRUSTED_ENUM_BUFFER { + DWORD EntriesRead; + [size_is(EntriesRead)] PLSAPR_TRUST_INFORMATION Information; +} LSAPR_TRUSTED_ENUM_BUFFER, *PLSAPR_TRUSTED_ENUM_BUFFER; + +cpp_quote("#ifndef _NTSECAPI_H"); +typedef enum _TRUSTED_INFORMATION_CLASS { + TrustedDomainNameInformation = 1, + TrustedControllersInformation, + TrustedPosixOffsetInformation, + TrustedPasswordInformation, + TrustedDomainInformationBasic, + TrustedDomainInformationEx, + TrustedDomainAuthInformation, + TrustedDomainFullInformation, + TrustedDomainAuthInformationInternal, + TrustedDomainFullInformationInternal, + TrustedDomainInformationEx2Internal, + TrustedDomainFullInformation2Internal, + TrustedDomainSupportedEncryptionTypes, +} TRUSTED_INFORMATION_CLASS, *PTRUSTED_INFORMATION_CLASS; +cpp_quote("#endif"); + +typedef struct _LSAPR_TRUSTED_DOMAIN_NAME_INFO { + RPC_UNICODE_STRING Name; +} LSAPR_TRUSTED_DOMAIN_NAME_INFO, *PLSAPR_TRUSTED_DOMAIN_NAME_INFO; + +typedef struct _LSAPR_TRUSTED_CONTROLLERS_INFO { + DWORD Entries; + [size_is(Entries)] PRPC_UNICODE_STRING Names; +} LSAPR_TRUSTED_CONTROLLERS_INFO, *PLSAPR_TRUSTED_CONTROLLERS_INFO; + +cpp_quote("#ifndef _NTSECAPI_H"); +typedef struct _TRUSTED_POSIX_OFFSET_INFO { + DWORD Offset; +} TRUSTED_POSIX_OFFSET_INFO, *PTRUSTED_POSIX_OFFSET_INFO; +cpp_quote("#endif"); + +typedef struct _LSAPR_CR_CIPHER_VALUE { + DWORD Length; + DWORD MaximumLength; + [size_is(MaximumLength), length_is(Length)] BYTE *Buffer; +} LSAPR_CR_CIPHER_VALUE, *PLSAPR_CR_CIPHER_VALUE; + +typedef struct _LSAPR_TRUSTED_PASSWORD_INFO { + PLSAPR_CR_CIPHER_VALUE Password; + PLSAPR_CR_CIPHER_VALUE OldPassword; +} LSAPR_TRUSTED_PASSWORD_INFO, *PLSAPR_TRUSTED_PASSWORD_INFO; + +typedef struct _LSAPR_USER_RIGHT_SET { + DWORD Entries; + [size_is(Entries)] PRPC_UNICODE_STRING UserRights; +} LSAPR_USER_RIGHT_SET, *PLSAPR_USER_RIGHT_SET; + +cpp_quote("#ifndef _NTSECAPI_H"); +typedef enum _POLICY_DOMAIN_INFORMATION_CLASS { + PolicyDomainQualityOfServiceInformation = 1, + PolicyDomainEfsInformation = 2, + PolicyDomainKerberosTicketInformation = 3, +} POLICY_DOMAIN_INFORMATION_CLASS, *PPOLICY_DOMAIN_INFORMATION_CLASS; + +typedef struct _POLICY_DOMAIN_QUALITY_OF_SERVICE_INFO { + DWORD QualityOfService; +} POLICY_DOMAIN_QUALITY_OF_SERVICE_INFO, *PPOLICY_DOMAIN_QUALITY_OF_SERVICE_INFO; +cpp_quote("#endif"); + +typedef struct _LSAPR_POLICY_DOMAIN_EFS_INFO { + DWORD InfoLength; + [size_is(InfoLength)] BYTE *EfsBlob; +} LSAPR_POLICY_DOMAIN_EFS_INFO, *PLSAPR_POLICY_DOMAIN_EFS_INFO; + +cpp_quote("#ifndef _NTSECAPI_H"); +typedef struct _POLICY_DOMAIN_KERBEROS_TICKET_INFO { + DWORD AuthenticationOptions; + LARGE_INTEGER MaxServiceTicketAge; + LARGE_INTEGER MaxTicketAge; + LARGE_INTEGER MaxRenewAge; + LARGE_INTEGER MaxClockSkew; + LARGE_INTEGER Reserved; +} POLICY_DOMAIN_KERBEROS_TICKET_INFO, *PPOLICY_DOMAIN_KERBEROS_TICKET_INFO; +cpp_quote("#endif"); + +typedef +[switch_type(POLICY_DOMAIN_INFORMATION_CLASS)] union _LSAPR_POLICY_DOMAIN_INFORMATION { + [case(PolicyDomainQualityOfServiceInformation)] POLICY_DOMAIN_QUALITY_OF_SERVICE_INFO PolicyDomainQualityOfServiceInfo; + [case(PolicyDomainEfsInformation)] LSAPR_POLICY_DOMAIN_EFS_INFO PolicyDomainEfsInfo; + [case(PolicyDomainKerberosTicketInformation)] POLICY_DOMAIN_KERBEROS_TICKET_INFO PolicyDomainKerbTicketInfo; +} LSAPR_POLICY_DOMAIN_INFORMATION, *PLSAPR_POLICY_DOMAIN_INFORMATION; + +typedef struct _LSAPR_TRUSTED_DOMAIN_INFORMATION_EX { + RPC_UNICODE_STRING Name; + RPC_UNICODE_STRING FlatName; + PRPC_SID Sid; + DWORD TrustDirection; + DWORD TrustType; + DWORD TrustAttributes; +} LSAPR_TRUSTED_DOMAIN_INFORMATION_EX, *PLSAPR_TRUSTED_DOMAIN_INFORMATION_EX; + +typedef struct _LSAPR_TRUSTED_ENUM_BUFFER_EX { + DWORD EntriesRead; + [size_is(EntriesRead)] PLSAPR_TRUSTED_DOMAIN_INFORMATION_EX EnumerationBuffer; +} LSAPR_TRUSTED_ENUM_BUFFER_EX, *PLSAPR_TRUSTED_ENUM_BUFFER_EX; + +typedef struct _LSAPR_TRUSTED_DOMAIN_INFORMATION_EX2 { + RPC_UNICODE_STRING Name; + RPC_UNICODE_STRING FlatName; + PRPC_SID Sid; + DWORD TrustDirection; + DWORD TrustType; + DWORD TrustAttributes; + DWORD ForestTrustLength; + [size_is(ForestTrustLength)] BYTE *ForestTrustInfo; +} LSAPR_TRUSTED_DOMAIN_INFORMATION_EX2, *PLSAPR_TRUSTED_DOMAIN_INFORMATION_EX2; + +typedef struct _LSAPR_AUTH_INFORMATION { + LARGE_INTEGER LastUpdateTime; + DWORD AuthType; + DWORD AuthInfoLength; + [size_is(AuthInfoLength)] BYTE *AuthInfo; +} LSAPR_AUTH_INFORMATION, *PLSAPR_AUTH_INFORMATION; + +typedef struct _LSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION { + DWORD IncomingAuthInfos; + PLSAPR_AUTH_INFORMATION IncomingAuthenticationInformation; + PLSAPR_AUTH_INFORMATION IncomingPreviousAuthenticationInformation; + DWORD OutgoingAuthInfos; + PLSAPR_AUTH_INFORMATION OutgoingAuthenticationInformation; + PLSAPR_AUTH_INFORMATION OutgoingPreviousAuthenticationInformation; +} LSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION, *PLSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION; + +typedef struct _LSAPR_TRUSTED_DOMAIN_AUTH_BLOB { + DWORD AuthSize; + [size_is(AuthSize)] BYTE *AuthBlob; +} LSAPR_TRUSTED_DOMAIN_AUTH_BLOB, *PLSAPR_TRUSTED_DOMAIN_AUTH_BLOB; + +typedef struct _LSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION_INTERNAL { + LSAPR_TRUSTED_DOMAIN_AUTH_BLOB AuthBlob; +} LSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION_INTERNAL, *PLSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION_INTERNAL; + +typedef struct _LSAPR_TRUSTED_DOMAIN_FULL_INFORMATION { + LSAPR_TRUSTED_DOMAIN_INFORMATION_EX Information; + TRUSTED_POSIX_OFFSET_INFO PosixOffset; + LSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION AuthInformation; +} LSAPR_TRUSTED_DOMAIN_FULL_INFORMATION, *PLSAPR_TRUSTED_DOMAIN_FULL_INFORMATION; + +typedef struct _LSAPR_TRUSTED_DOMAIN_FULL_INFORMATION_INTERNAL { + LSAPR_TRUSTED_DOMAIN_INFORMATION_EX Information; + TRUSTED_POSIX_OFFSET_INFO PosixOffset; + LSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION_INTERNAL AuthInformation; +} LSAPR_TRUSTED_DOMAIN_FULL_INFORMATION_INTERNAL, *PLSAPR_TRUSTED_DOMAIN_FULL_INFORMATION_INTERNAL; + +typedef struct _LSAPR_TRUSTED_DOMAIN_FULL_INFORMATION2 { + LSAPR_TRUSTED_DOMAIN_INFORMATION_EX2 Information; + TRUSTED_POSIX_OFFSET_INFO PosixOffset; + LSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION AuthInformation; +} LSAPR_TRUSTED_DOMAIN_FULL_INFORMATION2, *PLSAPR_TRUSTED_DOMAIN_FULL_INFORMATION2; + +typedef struct _TRUSTED_DOMAIN_SUPPORTED_ENCRYPTION_TYPES { + DWORD SupportedEncryptionTypes; +} TRUSTED_DOMAIN_SUPPORTED_ENCRYPTION_TYPES, *PTRUSTED_DOMAIN_SUPPORTED_ENCRYPTION_TYPES; + +typedef +[switch_type(TRUSTED_INFORMATION_CLASS)] union _LSAPR_TRUSTED_DOMAIN_INFO { + [case(TrustedDomainNameInformation)] LSAPR_TRUSTED_DOMAIN_NAME_INFO TrustedDomainNameInfo; + [case(TrustedControllersInformation)] LSAPR_TRUSTED_CONTROLLERS_INFO TrustedControllersInfo; + [case(TrustedPosixOffsetInformation)] TRUSTED_POSIX_OFFSET_INFO TrustedPosixOffsetInfo; + [case(TrustedPasswordInformation)] LSAPR_TRUSTED_PASSWORD_INFO TrustedPasswordInfo; + [case(TrustedDomainInformationBasic)] LSAPR_TRUSTED_DOMAIN_INFORMATION_BASIC TrustedDomainInfoBasic; + [case(TrustedDomainInformationEx)] LSAPR_TRUSTED_DOMAIN_INFORMATION_EX TrustedDomainInfoEx; + [case(TrustedDomainAuthInformation)] LSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION TrustedAuthInfo; + [case(TrustedDomainFullInformation)] LSAPR_TRUSTED_DOMAIN_FULL_INFORMATION TrustedFullInfo; + [case(TrustedDomainAuthInformationInternal)] LSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION_INTERNAL TrustedAuthInfoInternal; + [case(TrustedDomainFullInformationInternal)] LSAPR_TRUSTED_DOMAIN_FULL_INFORMATION_INTERNAL TrustedFullInfoInternal; + [case(TrustedDomainInformationEx2Internal)] LSAPR_TRUSTED_DOMAIN_INFORMATION_EX2 TrustedDomainInfoEx2; + [case(TrustedDomainFullInformation2Internal)] LSAPR_TRUSTED_DOMAIN_FULL_INFORMATION2 TrustedFullInfo2; + [case(TrustedDomainSupportedEncryptionTypes)] TRUSTED_DOMAIN_SUPPORTED_ENCRYPTION_TYPES TrustedDomainSETs; +} LSAPR_TRUSTED_DOMAIN_INFO, *PLSAPR_TRUSTED_DOMAIN_INFO; + +cpp_quote("#ifndef _WINNT_H"); +typedef struct _LUID { + ULONG LowPart; + LONG HightPart; +} LUID, *PLUID; +cpp_quote("#endif"); + +typedef struct _LSAPR_LUID_AND_ATTRIBUTES { + LUID Luid; + DWORD Attributes; +} LSAPR_LUID_AND_ATTRIBUTES, *PLSAPR_LUID_AND_ATTRIBUTES; + +typedef struct _LSAPR_PRIVILEGE_SET { + DWORD PrivilegeCount; + DWORD Control; + [size_is(PrivilegeCount)] LSAPR_LUID_AND_ATTRIBUTES Privilege[*]; +} LSAPR_PRIVILEGE_SET, *PLSAPR_PRIVILEGE_SET; + +cpp_quote("#ifndef _NTSECAPI_H"); +typedef enum _LSA_FOREST_TRUST_RECORD_TYPE { + ForestTrustTopLevelName = 0, + ForestTrustTopLevelNameEx = 1, + ForestTrustDomainInfo = 2, +} LSA_FOREST_TRUST_RECORD_TYPE; + +typedef struct _LSA_FOREST_TRUST_BINARY_DATA { + DWORD Length; + [size_is(Length)] BYTE *Buffer; +} LSA_FOREST_TRUST_BINARY_DATA, *PLSA_FOREST_TRUST_BINARY_DATA; + +typedef struct _LSA_FOREST_TRUST_DOMAIN_INFO { + PRPC_SID Sid; + LSA_UNICODE_STRING DnsName; + LSA_UNICODE_STRING NetbiosName; +} LSA_FOREST_TRUST_DOMAIN_INFO, *PLSA_FOREST_TRUST_DOMAIN_INFO; + +typedef struct _LSA_FOREST_TRUST_RECORD { + DWORD Flags; + LSA_FOREST_TRUST_RECORD_TYPE ForestTrustType; + LARGE_INTEGER Time; + [switch_type(LSA_FOREST_TRUST_RECORD_TYPE), switch_is(ForestTrustType)] union { + [case(ForestTrustTopLevelName, ForestTrustTopLevelNameEx)] LSA_UNICODE_STRING TopLevelName; + [case(ForestTrustDomainInfo)] LSA_FOREST_TRUST_DOMAIN_INFO DomainInfo; + [default] LSA_FOREST_TRUST_BINARY_DATA Data; + } ForestTrustData; +} LSA_FOREST_TRUST_RECORD, *PLSA_FOREST_TRUST_RECORD; + +typedef struct _LSA_FOREST_TRUST_INFORMATION { + DWORD RecordCount; + [size_is(RecordCount)] PLSA_FOREST_TRUST_RECORD *Entries; +} LSA_FOREST_TRUST_INFORMATION, *PLSA_FOREST_TRUST_INFORMATION; + +typedef enum _LSA_FOREST_TRUST_COLLISION_RECORD_TYPE { + CollisionTdo = 0, + CollisionXref, + CollisionOther, +} LSA_FOREST_TRUST_COLLISION_RECORD_TYPE; + +typedef struct _LSA_FOREST_TRUST_COLLISION_RECORD { + DWORD Index; + LSA_FOREST_TRUST_COLLISION_RECORD_TYPE Type; + DWORD Flags; + LSA_UNICODE_STRING Name; +} LSA_FOREST_TRUST_COLLISION_RECORD, *PLSA_FOREST_TRUST_COLLISION_RECORD; + +typedef struct _LSA_FOREST_TRUST_COLLISION_INFORMATION { + DWORD RecordCount; + [size_is(RecordCount)] PLSA_FOREST_TRUST_COLLISION_RECORD *Entries; +} LSA_FOREST_TRUST_COLLISION_INFORMATION, *PLSA_FOREST_TRUST_COLLISION_INFORMATION; +cpp_quote("#endif"); [ uuid(12345778-1234-abcd-ef00-0123456789ab), @@ -16,29 +597,591 @@ ] interface lsarpc { -/* - cpp_quote("#if 0") - typedef [handle, unique] wchar_t *LPWSTR; - typedef [handle, unique] char *LPSTR; - cpp_quote("#endif") - typedef [context_handle] void *LSA_HANDLE; - typedef LSA_HANDLE *PLSA_HANDLE; - typedef unsigned int NTSTATUS; -*/ - - cpp_quote("#if 0") - typedef struct _LSA_UNICODE_STRING { - unsigned short Length; - unsigned short MaximumLength; - [size_is(MaximumLength)] wchar_t *Buffer; - } LSA_UNICODE_STRING, *PLSA_UNICODE_STRING; - cpp_quote("#endif") - /* Function 0 */ - NTSTATUS LsarClose(handle_t BindingHandle, - [in] LSA_HANDLE ObjectHandle); + NTSTATUS LsarClose( + [in] handle_t hBinding, + [in, out] LSAPR_HANDLE *ObjectHandle); /* Function 1 */ - NTSTATUS LsarDelete(handle_t BindingHandle, - [in] LSA_HANDLE ObjectHandle); + NTSTATUS LsarDelete( + [in] handle_t hBinding, + [in] LSAPR_HANDLE ObjectHandle); + + /* Function 2 */ + NTSTATUS LsarEnumeratePrivileges( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in, out] DWORD *EnumerationContext, + [out] PLSAPR_PRIVILEGE_ENUM_BUFFER EnumerationBuffer, + [in] DWORD PreferedMaximumLength); + + /* Function 3 */ + NTSTATUS LsarQuerySecurityObject( + [in] handle_t hBinding, + [in] LSAPR_HANDLE ObjectHandle, + [in] SECURITY_INFORMATION SecurityInformation, + [out] PLSAPR_SR_SECURITY_DESCRIPTOR *SecurityDescriptor); + + /* Function 4 */ + NTSTATUS LsarSetSecurityObject( + [in] handle_t hBinding, + [in] LSAPR_HANDLE ObjectHandle, + [in] SECURITY_INFORMATION SecurityInformation, + [in] PLSAPR_SR_SECURITY_DESCRIPTOR SecurityDescriptor); + + /* Function 5 */ + NTSTATUS LsarChangePassword( + [in] handle_t hBinding, + [in] PRPC_UNICODE_STRING String1, + [in] PRPC_UNICODE_STRING String2, + [in] PRPC_UNICODE_STRING String3, + [in] PRPC_UNICODE_STRING String4, + [in] PRPC_UNICODE_STRING String5); + + /* Function 6 */ + NTSTATUS LsarOpenPolicy( + [in] handle_t hBinding, + [in, unique] LPWSTR SystemName, + [in] PLSAPR_OBJECT_ATTRIBUTES ObjectAttributes, + [in] ACCESS_MASK DesiredAccess, + [out] LSAPR_HANDLE *PolicyHandle); + + /* Function 7 */ + NTSTATUS LsarQueryInformationPolicy( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] POLICY_INFORMATION_CLASS InformationClass, + [in] unsigned long PolicyInformation); + /* FIXME: should be [in, switch_is(InformationClass)] PLSAPR_POLICY_INFORMATION PolicyInformation); */ + + /* Function 8 */ + NTSTATUS LsarSetInformationPolicy( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] POLICY_INFORMATION_CLASS InformationClass, + [out] unsigned long *PolicyInformation); + /* FIXME: should be [out, switch_is(InformationClass)] PLSAPR_POLICY_INFORMATION *PolicyInformation); */ + + /* Function 9 */ + NTSTATUS LsarClearAuditLog( + [in] handle_t hBinding, + [in] LSAPR_HANDLE ObjectHandle); + + /* Function 10 */ + NTSTATUS LsarCreateAccount( + [in] handle_t hBinding, + [in] PRPC_SID AccountSid, + [in] ACCESS_MASK DesiredAccess, + [out] LSAPR_HANDLE *AccountHandle); + + /* Function 11 */ + NTSTATUS LsarEnumerateAccounts( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in, out] DWORD *EnumerationContext, + [out] PLSAPR_ACCOUNT_ENUM_BUFFER EnumerationBuffer, + [in] DWORD PreferedMaximumLength); + + /* Function 12 */ + NTSTATUS LsarCreateTrustedDomain( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PLSAPR_TRUST_INFORMATION TrustedDomainInformation, + [in] ACCESS_MASK DesiredAccess, + [out] LSAPR_HANDLE *TrustedDomainHandle); + + /* Function 13 */ + NTSTATUS LsarEnumerateTrustedDomains( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in, out] DWORD *EnumerationContext, + [out] PLSAPR_TRUSTED_ENUM_BUFFER EnumerationBuffer, + [in] DWORD PreferedMaximumLength); + + /* Function 14 */ + NTSTATUS LsarLookupNames( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] DWORD Count, + [in, size_is(Count)] PRPC_UNICODE_STRING Names, + [out] PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + [in, out] PLSAPR_TRANSLATED_SIDS TranslatedSids, + [in] LSAP_LOOKUP_LEVEL LookupLevel, + [in, out] DWORD *MappedCount); + + /* Function 15 */ + NTSTATUS LsarLookupSids( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PLSAPR_SID_ENUM_BUFFER SidEnumBuffer, + [out] PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + [in, out] PLSAPR_TRANSLATED_NAMES TranslatedNames, + [in] LSAP_LOOKUP_LEVEL LookupLevel, + [in, out] DWORD *MappedCount); + + /* Function 16 */ + NTSTATUS LsarCreateSecret( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_UNICODE_STRING SecretName, + [in] ACCESS_MASK DesiredAccess, + [out] LSAPR_HANDLE *SecretHandle); + + /* Function 17 */ + NTSTATUS LsarOpenAccount( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_SID AccountSid, + [in] ACCESS_MASK DesiredAccess, + [out] LSAPR_HANDLE *AccountHandle); + + /* Function 18 */ + NTSTATUS LsarEnumeratePrivilegesAccount( + [in] handle_t hBinding, + [in] LSAPR_HANDLE AccountHandle, + [out] PLSAPR_PRIVILEGE_SET *Privileges); + + /* Function 19 */ + NTSTATUS LsarAddPrivilegesToAccount( + [in] handle_t hBinding, + [in] LSAPR_HANDLE AccountHandle, + [in] PLSAPR_PRIVILEGE_SET Privileges); + + /* Function 20 */ + NTSTATUS LsarRemovePrivilegesFromAccount( + [in] handle_t hBinding, + [in] LSAPR_HANDLE AccountHandle, + [in] BOOL AllPrivileges, + [in, unique] PLSAPR_PRIVILEGE_SET Privileges); + + /* Function 21 */ + NTSTATUS LsarGetQuotasForAccount( + [in] handle_t hBinding, + [in] LSAPR_HANDLE AccountHandle, + [out] PQUOTA_LIMITS QuotaLimits); + + /* Function 22 */ + NTSTATUS LsarSetQuotasForAccount( + [in] handle_t hBinding, + [in] LSAPR_HANDLE AccountHandle, + [in] PQUOTA_LIMITS QuotaLimits); + + /* Function 23 */ + NTSTATUS LsarGetSystemAccessAccount( + [in] handle_t hBinding, + [in] LSAPR_HANDLE AccountHandle, + [out] ACCESS_MASK *SystemAccess); + + /* Function 24 */ + NTSTATUS LsarSetSystemAccessAccount( + [in] handle_t hBinding, + [in] LSAPR_HANDLE AccountHandle, + [in] ACCESS_MASK SystemAccess); + + /* Function 25 */ + NTSTATUS LsarOpenTrustedDomain( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_SID TrustedDomainSid, + [in] ACCESS_MASK DesiredAccess, + [out] LSAPR_HANDLE *TrustedDomainHandle); + + /* Function 26 */ + NTSTATUS LsarQueryInfoTrustedDomain( + [in] handle_t hBinding, + [in] LSAPR_HANDLE TrustedDomainHandle, + [in] TRUSTED_INFORMATION_CLASS InformationClass, + [out, switch_is(InformationClass)] PLSAPR_TRUSTED_DOMAIN_INFO *TrustedDomainInformation); + + /* Function 27 */ + NTSTATUS LsarSetInformationTrustedDomain( + [in] handle_t hBinding, + [in] LSAPR_HANDLE TrustedDomainHandle, + [in] TRUSTED_INFORMATION_CLASS InformationClass, + [in, switch_is(InformationClass)] PLSAPR_TRUSTED_DOMAIN_INFO TrustedDomainInformation); + + /* Function 28 */ + NTSTATUS LsarOpenSecret( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_UNICODE_STRING SecretName, + [in] ACCESS_MASK DesiredAccess, + [out] LSAPR_HANDLE *SecretHandle); + + /* Function 29 */ + NTSTATUS LsarSetSecret( + [in] handle_t hBinding, + [in] LSAPR_HANDLE *SecretHandle, + [in, unique] PLSAPR_CR_CIPHER_VALUE EncryptedCurrentValue, + [in, unique] PLSAPR_CR_CIPHER_VALUE EncryptedOldValue); + + /* Function 30 */ + NTSTATUS LsarQuerySecret( + [in] handle_t hBinding, + [in] LSAPR_HANDLE SecretHandle, + [in, out, unique] PLSAPR_CR_CIPHER_VALUE *EncryptedCurrentValue, + [in, out, unique] PLARGE_INTEGER CurrentValueSetTime, + [in, out, unique] PLSAPR_CR_CIPHER_VALUE *EncryptedOldValue, + [in, out, unique] PLARGE_INTEGER OldValueSetTime); + + /* Function 31 */ + NTSTATUS LsarLookupPrivilegeValue( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_UNICODE_STRING Name, + [out] PLUID Value); + + /* Function 32 */ + NTSTATUS LsarLookupPrivilegeName( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PLUID Value, + [out] PRPC_UNICODE_STRING *Name); + + /* Function 33 */ + NTSTATUS LsarLookupPrivilegeDisplayName( + [in] handle_t hBinding, + /*[in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_UNICODE_STRING Name, + [in] USHORT ClientLanguage, + [in] USHORT ClientSystemDefaultLanguage, + [out] PRPC_UNICODE_STRING *DisplayName,*/ + [out] USHORT *LanguageReturned); + + /* Function 34 */ + NTSTATUS LsarDeleteObject( + [in] handle_t hBinding, + [in, out] LSAPR_HANDLE *ObjectHandle); + +cpp_quote("#if _WIN32_WINNT >= 0x0351") + + /* Function 35 */ + NTSTATUS LsarEnumerateAccountsWithUserRight( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in, unique] PRPC_UNICODE_STRING UserRight, + [out] PLSAPR_ACCOUNT_ENUM_BUFFER EnumerationBuffer); + + /* Function 36 */ + NTSTATUS LsarEnmuerateAccountRights( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_SID AccountSid, + [out] PLSAPR_USER_RIGHT_SET UserRights); + + /* Function 37 */ + NTSTATUS LsarAddAccountRights( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_SID AccountSid, + [in] PLSAPR_USER_RIGHT_SET UserRights); + + /* Function 38 */ + NTSTATUS LsarRemoveAccountRights( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_SID AccountSid, + [in] BOOL AllRights, + [in] PLSAPR_USER_RIGHT_SET UserRights); + + /* Function 39 */ + NTSTATUS LsarQueryTrustedDomainInfo( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_SID TrustedDomainSid, + [in] TRUSTED_INFORMATION_CLASS InformationClass, + [out, switch_is(InformationClass)] PLSAPR_TRUSTED_DOMAIN_INFO *TrustedDomainInformation); + + /* Function 40 */ + NTSTATUS LsarSetTrustedDomainInfo( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_SID TrustedDomainSid, + [in] TRUSTED_INFORMATION_CLASS InformationClass, + [in, switch_is(InformationClass)] PLSAPR_TRUSTED_DOMAIN_INFO TrustedDomainInformation); + + /* Function 41 */ + NTSTATUS LsarDeleteTrustedDomain( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_SID TrustedDomainSid); + + /* Function 42 */ + NTSTATUS LsarStorePrivateData( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_UNICODE_STRING KeyName, + [in, unique] PLSAPR_CR_CIPHER_VALUE EncryptedData); + + /* Function 43 */ + NTSTATUS LsarRetrievePrivateData( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_UNICODE_STRING KeyName, + [in, out] PLSAPR_CR_CIPHER_VALUE *EncryptedData); + + /* Function 44 */ + NTSTATUS LsarOpenPolicy2( + [in] handle_t hBinding, + [in, unique, string] LPWSTR SystemName, + [in] PLSAPR_OBJECT_ATTRIBUTES ObjectAttributes, + [in] ACCESS_MASK DesiredAccess, + [out] LSAPR_HANDLE *PolicyHandle); + + /* Function 45 */ + NTSTATUS LsarGetUserName( + [in] handle_t hBinding, + [in, unique, string] LPWSTR SystemName, + [in, out] PRPC_UNICODE_STRING *UserName, + [in, out, unique] PRPC_UNICODE_STRING *DomainName); + +cpp_quote("#if _WIN32_WINNT >= 0x0500") + + /* Function 46 */ + NTSTATUS LsarQueryInformationPolicy2( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] POLICY_INFORMATION_CLASS InformationClass, + [out] unsigned long *PolicyInformation); + /* FIXME: should be [out, switch_is(InformationClass)] PLSAPR_POLICY_INFORMATION *PolicyInformation); */ + + /* Function 47 */ + NTSTATUS LsarSetInformationPolicy2( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] POLICY_INFORMATION_CLASS InformationClass, + [in] unsigned long PolicyInformation); + /* FIXME: should be [in, switch_is(InformationClass)] PLSAPR_POLICY_INFORMATION PolicyInformation); */ + + /* Function 48 */ + NTSTATUS LsarQueryTrustedDomainInfoByName( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_UNICODE_STRING TrustedDomainName, + [in] POLICY_INFORMATION_CLASS InformationClass, + [out] unsigned long *PolicyInformation); + /* FIXME: should be [out, switch_is(InformationClass)] PLSAPR_POLICY_INFORMATION *PolicyInformation); */ + + /* Function 49 */ + NTSTATUS LsarSetTrustedDomainInfoByName( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_UNICODE_STRING TrustedDomainName, + [in] POLICY_INFORMATION_CLASS InformationClass, + [in] unsigned long PolicyInformation); + /* FIXME: should be [in, switch_is(InformationClass)] PLSAPR_POLICY_INFORMATION PolicyInformation); */ + + /* Function 50 */ + NTSTATUS LsarEnumerateTrustedDomainsEx( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in, out] DWORD *EnumerationContext, + [out] PLSAPR_TRUSTED_ENUM_BUFFER_EX EnumerationBuffer, + [in] DWORD PreferedMaximumLength); + + /* Function 51 */ + NTSTATUS LsarCreateTrustedDomainEx( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PLSAPR_TRUSTED_DOMAIN_INFORMATION_EX TrustedDomainInformation, + [in] PLSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION AuthentificationInformation, + [in] ACCESS_MASK DesiredAccess, + [out] LSAPR_HANDLE *TrustedDomainHandle); + + /* Function 52 */ + NTSTATUS LsarSetPolicyReplicationHandle( + [in] handle_t hBinding, + [in, out] PLSAPR_HANDLE PolicyHandle); + + /* Function 53 */ + NTSTATUS LsarQueryDomainInformationPolicy( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] POLICY_INFORMATION_CLASS InformationClass, + [out] unsigned long *PolicyInformation); + /* FIXME: should be [out, switch_is(InformationClass)] PLSAPR_POLICY_INFORMATION *PolicyInformation); */ + + /* Function 54 */ + NTSTATUS LsarSetDomainInformationPolicy( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] POLICY_INFORMATION_CLASS InformationClass, + [in] unsigned long PolicyInformation); + /* FIXME: should be [in, switch_is(InformationClass)] PLSAPR_POLICY_INFORMATION PolicyInformation); */ + + /* Function 55 */ + NTSTATUS LsarOpenTrustedDomainByName( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PRPC_UNICODE_STRING TrustedDomainName, + [in] ACCESS_MASK DesiredAccess, + [out] LSAPR_HANDLE *TrustedDomainHandle); + + /* Function 56 */ + NTSTATUS LsarTestCall( + [in] handle_t hBinding); /* FIXME */ + + /* Function 57 */ + NTSTATUS LsarLookupSids2( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PLSAPR_SID_ENUM_BUFFER SidEnumBuffer, + [out] PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + [in, out] PLSAPR_TRANSLATED_NAMES_EX TranslatedNames, + [in] LSAP_LOOKUP_LEVEL LookupLevel, + [in, out] DWORD *MappedCount, + [in] DWORD LookupOptions, + [in] DWORD ClientRevision); + + /* Function 58 */ + NTSTATUS LsarLookupNames2( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] DWORD Count, + [in, size_is(Count)] PRPC_UNICODE_STRING Names, + [out] PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + [in, out] PLSAPR_TRANSLATED_SID_EX TranslatedSids, + [in] LSAP_LOOKUP_LEVEL LookupLevel, + [in, out] DWORD *MappedCount, + [in] DWORD LookupOptions, + [in] DWORD ClientRevision); + + /* Function 59 */ + NTSTATUS LsarCreateTrustedDomainEx2( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PLSAPR_TRUSTED_DOMAIN_INFORMATION_EX TrustedDomainInformation, + [in] PLSAPR_TRUSTED_DOMAIN_AUTH_INFORMATION_INTERNAL AuthentificationInformation, + [in] ACCESS_MASK DesiredAccess, + [out] LSAPR_HANDLE *TrustedDomainHandle); + +cpp_quote("#if _WIN32_WINNT >= 0x0501") + + /* Function 60 */ + NTSTATUS CredrWrite( + [in] handle_t hBinding); /* FIXME */ + + /* Function 61 */ + NTSTATUS CredrRead( + [in] handle_t hBinding); /* FIXME */ + + /* Function 62 */ + NTSTATUS CredrEnumerate( + [in] handle_t hBinding); /* FIXME */ + + /* Function 63 */ + NTSTATUS CredrWriteDomainCredentials( + [in] handle_t hBinding); /* FIXME */ + + /* Function 64 */ + NTSTATUS CredrReadDomainCredentials( + [in] handle_t hBinding); /* FIXME */ + + /* Function 65 */ + NTSTATUS CredrDelete( + [in] handle_t hBinding); /* FIXME */ + + /* Function 66 */ + NTSTATUS CredrGetTargetInfo( + [in] handle_t hBinding); /* FIXME */ + + /* Function 67 */ + NTSTATUS CredrProfileLoaded( + [in] handle_t hBinding); /* FIXME */ + + /* Function 68 */ + NTSTATUS LsarLookupNames3( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] DWORD Count, + [in, size_is(Count)] PRPC_UNICODE_STRING Names, + [out] PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + [in, out] PLSAPR_TRANSLATED_SID_EX2 TranslatedSids, + [in] LSAP_LOOKUP_LEVEL LookupLevel, + [in, out] DWORD *MappedCount, + [in] DWORD LookupOptions, + [in] DWORD ClientRevision); + + /* Function 69 */ + NTSTATUS CredrGetSessionTypes( + [in] handle_t hBinding); /* FIXME */ + + /* Function 70 */ + NTSTATUS LsarRegisterAuditEvent( + [in] handle_t hBinding); /* FIXME */ + + /* Function 71 */ + NTSTATUS LsarGenAuditEvent( + [in] handle_t hBinding); /* FIXME */ + + /* Function 72 */ + NTSTATUS LsarUnregisterAuditEvent( + [in] handle_t hBinding); /* FIXME */ + + /* Function 73 */ + NTSTATUS LsarQueryForestTrustInformation( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PLSA_UNICODE_STRING TrustedDomainName, + [in] LSA_FOREST_TRUST_RECORD_TYPE HighestRecordType, + [out] PLSA_FOREST_TRUST_INFORMATION *ForestTrustInfo); + + /* Function 74 */ + NTSTATUS LsarSetForestTrustInformation( + [in] handle_t hBinding, + [in] LSAPR_HANDLE PolicyHandle, + [in] PLSA_UNICODE_STRING TrustedDomainName, + [in] LSA_FOREST_TRUST_RECORD_TYPE HighestRecordType, + [in] PLSA_FOREST_TRUST_INFORMATION ForestTrustInfo, + [in] BOOL CheckOnly, + [out] PLSA_FOREST_TRUST_COLLISION_INFORMATION *CollisionInfo); + + /* Function 75 */ + NTSTATUS CredrRename( + [in] handle_t hBinding); /* FIXME */ + + /* Function 76 */ + NTSTATUS LsarLookupSids3( + [in] handle_t hBinding, + [in] PLSAPR_SID_ENUM_BUFFER SidEnumBuffer, + [out] PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + [in, out] PLSAPR_TRANSLATED_NAMES_EX TranslatedNames, + [in] LSAP_LOOKUP_LEVEL LookupLevel, + [in, out] DWORD *MappedCount, + [in] DWORD LookupOptions, + [in] DWORD ClientRevision); + + /* Function 77 */ + NTSTATUS LsarLookupNames4( + [in] handle_t hBinding, + [in] handle_t RpcHandle, + [in] DWORD Count, + [in, size_is(Count)] PRPC_UNICODE_STRING Names, + [out] PLSAPR_REFERENCED_DOMAIN_LIST *ReferencedDomains, + [in, out] PLSAPR_TRANSLATED_SID_EX2 TranslatedSids, + [in] LSAP_LOOKUP_LEVEL LookupLevel, + [in, out] DWORD *MappedCount, + [in] DWORD LookupOptions, + [in] DWORD ClientRevision); + + /* Function 78 */ + NTSTATUS LsarOpenPolicySce( + [in] handle_t hBinding); /* FIXME */ + + /* Function 79 */ + NTSTATUS LsarAdtRegisterSecurityEventSource( + [in] handle_t hBinding); /* FIXME */ + + /* Function 80 */ + NTSTATUS LsarAdtUnregisterSecurityEventSource( + [in] handle_t hBinding); /* FIXME */ + + /* Function 81 */ + NTSTATUS LsarAdtReportSecurityEvent( + [in] handle_t hBinding); /* FIXME */ + +cpp_quote("#endif /* _WIN32_WINNT >= 0x0501 */") +cpp_quote("#endif /* _WIN32_WINNT >= 0x0500 */") +cpp_quote("#endif /* _WIN32_WINNT >= 0x0351 */") + }
16 years, 4 months
1
0
0
0
[hpoussin] 35039: Support nested structures
by hpoussin@svn.reactos.org
Author: hpoussin Date: Sat Aug 2 10:34:14 2008 New Revision: 35039 URL:
http://svn.reactos.org/svn/reactos?rev=35039&view=rev
Log: Support nested structures Modified: trunk/reactos/tools/widl/typegen.c trunk/reactos/tools/widl/widl_ros.diff Modified: trunk/reactos/tools/widl/typegen.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/widl/typegen.c?rev=3…
============================================================================== --- trunk/reactos/tools/widl/typegen.c [iso-8859-1] (original) +++ trunk/reactos/tools/widl/typegen.c [iso-8859-1] Sat Aug 2 10:34:14 2008 @@ -3299,8 +3299,9 @@ print_file(file, 0, "static void __RPC_USER %s_%sExprEval_%04u(PMIDL_STUB_MESSAGE pStubMsg)\n", iface, name, callback_offset); print_file(file, 0, "{\n"); - print_file (file, 1, "%s *%s = (%s *)(pStubMsg->StackTop - %u);\n", - name, var_name, name, eval->baseoff); + print_file (file, 1, "%s%s *%s = (%s%s *)(pStubMsg->StackTop - %u);\n", + is_struct(eval->structure->type) ? "struct " : "", name, var_name, + is_struct(eval->structure->type) ? "struct " : "", name, eval->baseoff); print_file(file, 1, "pStubMsg->Offset = 0;\n"); /* FIXME */ print_file(file, 1, "pStubMsg->MaxCount = (unsigned long)"); write_struct_expr(file, eval->expr, 1, fields, var_name); Modified: trunk/reactos/tools/widl/widl_ros.diff URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/widl/widl_ros.diff?r…
============================================================================== --- trunk/reactos/tools/widl/widl_ros.diff [iso-8859-1] (original) +++ trunk/reactos/tools/widl/widl_ros.diff [iso-8859-1] Sat Aug 2 10:34:14 2008 @@ -46,6 +46,22 @@ print_server("#include \"%s\"\n", header_name); fprintf(server, "\n"); } +Index: typegen.c +=================================================================== +--- typegen.c (revision 32187) ++++ typegen.c (working copy) +@@ -3299,8 +3299,9 @@ + print_file(file, 0, "static void __RPC_USER %s_%sExprEval_%04u(PMIDL_STUB_MESSAGE pStubMsg)\n", + iface, name, callback_offset); + print_file(file, 0, "{\n"); +- print_file (file, 1, "%s *%s = (%s *)(pStubMsg->StackTop - %u);\n", +- name, var_name, name, eval->baseoff); ++ print_file (file, 1, "%s%s *%s = (%s%s *)(pStubMsg->StackTop - %u);\n", ++ is_struct(eval->structure->type) ? "struct " : "", name, var_name, ++ is_struct(eval->structure->type) ? "struct " : "", name, eval->baseoff); + print_file(file, 1, "pStubMsg->Offset = 0;\n"); /* FIXME */ + print_file(file, 1, "pStubMsg->MaxCount = (unsigned long)"); + write_struct_expr(file, eval->expr, 1, fields, var_name); Index: typelib.c =================================================================== --- typelib.c (revision 32187)
16 years, 4 months
1
0
0
0
[cgutman] 35038: - We must complete the IRP if we fail because the function we were called from expects the IRP to be completed after this call - Return the correct status
by cgutman@svn.reactos.org
Author: cgutman Date: Sat Aug 2 09:52:19 2008 New Revision: 35038 URL:
http://svn.reactos.org/svn/reactos?rev=35038&view=rev
Log: - We must complete the IRP if we fail because the function we were called from expects the IRP to be completed after this call - Return the correct status Modified: branches/aicom-network-fixes/drivers/network/afd/afd/listen.c Modified: branches/aicom-network-fixes/drivers/network/afd/afd/listen.c URL:
http://svn.reactos.org/svn/reactos/branches/aicom-network-fixes/drivers/net…
============================================================================== --- branches/aicom-network-fixes/drivers/network/afd/afd/listen.c [iso-8859-1] (original) +++ branches/aicom-network-fixes/drivers/network/afd/afd/listen.c [iso-8859-1] Sat Aug 2 09:52:19 2008 @@ -18,7 +18,10 @@ PAFD_TDI_OBJECT_QELT Qelt ) { PAFD_FCB FCB = NewFileObject->FsContext; - if( !SocketAcquireStateLock( FCB ) ) return; + if( !SocketAcquireStateLock( FCB ) ) { + LostSocket( Irp ); + return; + } /* Transfer the connection to the new socket, launch the opening read */ AFD_DbgPrint(MID_TRACE,("Completing a real accept (FCB %x)\n", FCB)); @@ -203,7 +206,6 @@ NTSTATUS AfdWaitForListen( PDEVICE_OBJECT DeviceObject, PIRP Irp, PIO_STACK_LOCATION IrpSp ) { - NTSTATUS Status = STATUS_SUCCESS; PFILE_OBJECT FileObject = IrpSp->FileObject; PAFD_FCB FCB = FileObject->FsContext; @@ -226,7 +228,7 @@ PollReeval( FCB->DeviceExt, FCB->FileObject ); SocketStateUnlock( FCB ); - return Status; + return Irp->IoStatus.Status; } else { AFD_DbgPrint(MID_TRACE,("Holding\n")); @@ -311,10 +313,9 @@ FCB->PollState &= ~AFD_EVENT_ACCEPT; SocketStateUnlock( FCB ); - return Status; + return Irp->IoStatus.Status; } } - SocketStateUnlock( FCB ); - return STATUS_UNSUCCESSFUL; -} + return UnlockAndMaybeComplete( FCB, STATUS_UNSUCCESSFUL, Irp, 0 , NULL ); +}
16 years, 4 months
1
0
0
0
[fireball] 35037: - Add dosfsck to the build.
by fireball@svn.reactos.org
Author: fireball Date: Sat Aug 2 09:45:18 2008 New Revision: 35037 URL:
http://svn.reactos.org/svn/reactos?rev=35037&view=rev
Log: - Add dosfsck to the build. Added: trunk/rosapps/applications/sysutils/dosfsck/dosfsck.rbuild (with props) trunk/rosapps/applications/sysutils/dosfsck/dosfsck.rc (with props) Modified: trunk/rosapps/applications/sysutils/sysutils.rbuild Added: trunk/rosapps/applications/sysutils/dosfsck/dosfsck.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/applications/sysutils/dosf…
============================================================================== --- trunk/rosapps/applications/sysutils/dosfsck/dosfsck.rbuild (added) +++ trunk/rosapps/applications/sysutils/dosfsck/dosfsck.rbuild [iso-8859-1] Sat Aug 2 09:45:18 2008 @@ -1,0 +1,15 @@ +<module name="dosfsck" type="win32cui" installbase="system32" installname="dosfsck.exe" unicode="no" allowwarnings="true"> + <library>kernel32</library> + <library>user32</library> + + <file>boot.c</file> + <file>check.c</file> + <file>common.c</file> + <file>dosfsck.c</file> + <file>fat.c</file> + <file>file.c</file> + <file>io.c</file> + <file>lfn.c</file> + + <file>dosfsck.rc</file> +</module> Propchange: trunk/rosapps/applications/sysutils/dosfsck/dosfsck.rbuild ------------------------------------------------------------------------------ svn:eol-style = native Added: trunk/rosapps/applications/sysutils/dosfsck/dosfsck.rc URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/applications/sysutils/dosf…
============================================================================== --- trunk/rosapps/applications/sysutils/dosfsck/dosfsck.rc (added) +++ trunk/rosapps/applications/sysutils/dosfsck/dosfsck.rc [iso-8859-1] Sat Aug 2 09:45:18 2008 @@ -1,0 +1,7 @@ +#include <windows.h> + +#define REACTOS_STR_FILE_DESCRIPTION "ReactOS FAT checker\0" +#define REACTOS_STR_INTERNAL_NAME "dosfsck\0" +#define REACTOS_STR_ORIGINAL_FILENAME "dosfsck.exe\0" +#define REACTOS_STR_ORIGINAL_COPYRIGHT "Copyright ReactOS Development team\0" +#include <reactos/version.rc> Propchange: trunk/rosapps/applications/sysutils/dosfsck/dosfsck.rc ------------------------------------------------------------------------------ svn:eol-style = native Modified: trunk/rosapps/applications/sysutils/sysutils.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/applications/sysutils/sysu…
============================================================================== --- trunk/rosapps/applications/sysutils/sysutils.rbuild [iso-8859-1] (original) +++ trunk/rosapps/applications/sysutils/sysutils.rbuild [iso-8859-1] Sat Aug 2 09:45:18 2008 @@ -10,6 +10,10 @@ <directory name="chklib"> <xi:include href="chklib/chklib.rbuild" /> + </directory> + + <directory name="dosfsck"> + <xi:include href="dosfsck/dosfsck.rbuild" /> </directory> <directory name="gettype">
16 years, 4 months
1
0
0
0
[hpoussin] 35036: Support GetObjectW() failure Reformat code
by hpoussin@svn.reactos.org
Author: hpoussin Date: Sat Aug 2 09:11:48 2008 New Revision: 35036 URL:
http://svn.reactos.org/svn/reactos?rev=35036&view=rev
Log: Support GetObjectW() failure Reformat code Modified: trunk/reactos/dll/cpl/desk/settings.c Modified: trunk/reactos/dll/cpl/desk/settings.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/settings.c?re…
============================================================================== --- trunk/reactos/dll/cpl/desk/settings.c [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/settings.c [iso-8859-1] Sat Aug 2 09:11:48 2008 @@ -57,8 +57,7 @@ HDC hDC; PSETTINGS_ENTRY Current; DWORD bpp, xres, yres, checkbpp; - DWORD curDispFreq; - + DWORD curDispFreq; /* Get current settings */ *CurrentSettings = NULL; @@ -80,12 +79,12 @@ while (EnumDisplaySettingsEx(DeviceName, iMode, &devmode, dwFlags)) { - if ((devmode.dmBitsPerPel==4 || - devmode.dmBitsPerPel==8 || - devmode.dmBitsPerPel==16 || - devmode.dmBitsPerPel==24 || - devmode.dmBitsPerPel==32) && - devmode.dmDisplayFrequency==curDispFreq) + if ((devmode.dmBitsPerPel == 4 || + devmode.dmBitsPerPel == 8 || + devmode.dmBitsPerPel == 16 || + devmode.dmBitsPerPel == 24 || + devmode.dmBitsPerPel == 32) && + devmode.dmDisplayFrequency == curDispFreq) { checkbpp=1; } @@ -286,7 +285,7 @@ BITMAP bitmap; DWORD Result = 0; DWORD iDevNum = 0; - INT i; + INT i; DISPLAY_DEVICE displayDevice; PGLOBAL_DATA pGlobalData; @@ -365,44 +364,52 @@ } /* Initialize the color spectrum bitmaps */ - for(i = 0; i < NUM_SPECTRUM_BITMAPS; i++) - { - pGlobalData->hSpectrumBitmaps[i] = LoadImageW(hApplet, MAKEINTRESOURCEW(IDB_SPECTRUM_4 + i), IMAGE_BITMAP, 0, 0, LR_DEFAULTCOLOR); - - if (pGlobalData->hSpectrumBitmaps[i] != NULL) - { - GetObjectW(pGlobalData->hSpectrumBitmaps[i], sizeof(BITMAP), &bitmap); - - pGlobalData->cxSource[i] = bitmap.bmWidth; - pGlobalData->cySource[i] = bitmap.bmHeight; - } - } + for(i = 0; i < NUM_SPECTRUM_BITMAPS; i++) + { + pGlobalData->hSpectrumBitmaps[i] = LoadImageW(hApplet, MAKEINTRESOURCEW(IDB_SPECTRUM_4 + i), IMAGE_BITMAP, 0, 0, LR_DEFAULTCOLOR); + + if (pGlobalData->hSpectrumBitmaps[i] != NULL) + { + if (GetObjectW(pGlobalData->hSpectrumBitmaps[i], sizeof(BITMAP), &bitmap) != 0) + { + pGlobalData->cxSource[i] = bitmap.bmWidth; + pGlobalData->cySource[i] = bitmap.bmHeight; + } + else + { + pGlobalData->cxSource[i] = 0; + pGlobalData->cySource[i] = 0; + } + } + } } /* Get the ID for GLOBAL_DATA::hSpectrumBitmaps */ static VOID ShowColorSpectrum(IN HDC hDC, IN LPRECT client, IN DWORD BitsPerPel, IN PGLOBAL_DATA pGlobalData) { - HDC hdcMem; - hdcMem = CreateCompatibleDC(hDC); - - if (hdcMem) - { - INT iBitmap; - - switch(BitsPerPel) - { - case 4: iBitmap = 0; break; - case 8: iBitmap = 1; break; - default: iBitmap = 2; - } - - SelectObject(hdcMem, pGlobalData->hSpectrumBitmaps[iBitmap]); - StretchBlt(hDC, client->left, client->top, client->right - client->left, - client->bottom - client->top, hdcMem, 0, 0, - pGlobalData->cxSource[iBitmap], pGlobalData->cySource[iBitmap], SRCCOPY); - DeleteDC(hdcMem); - } + HDC hdcMem; + INT iBitmap; + + hdcMem = CreateCompatibleDC(hDC); + + if (!hdcMem) + return; + + switch(BitsPerPel) + { + case 4: iBitmap = 0; break; + case 8: iBitmap = 1; break; + default: iBitmap = 2; + } + + SelectObject(hdcMem, pGlobalData->hSpectrumBitmaps[iBitmap]); + StretchBlt(hDC, + client->left, client->top, client->right - client->left, client->bottom - client->top, + hdcMem, 0, 0, + pGlobalData->cxSource[iBitmap], + pGlobalData->cySource[iBitmap], SRCCOPY); + DeleteDC(hdcMem); } static VOID @@ -415,18 +422,18 @@ PSETTINGS_ENTRY Current; DWORD dmNewBitsPerPel; DWORD index; - HDC hSpectrumDC; - HWND hSpectrumControl; - RECT client; + HDC hSpectrumDC; + HWND hSpectrumControl; + RECT client; index = (DWORD) SendDlgItemMessage(hwndDlg, IDC_SETTINGS_BPP, CB_GETCURSEL, 0, 0); dmNewBitsPerPel = (DWORD) SendDlgItemMessage(hwndDlg, IDC_SETTINGS_BPP, CB_GETITEMDATA, index, 0); - /* Show a new spectrum bitmap */ - hSpectrumControl = GetDlgItem(hwndDlg, IDC_SETTINGS_SPECTRUM); - hSpectrumDC = GetDC(hSpectrumControl); - GetClientRect(hSpectrumControl, &client); - ShowColorSpectrum(hSpectrumDC, &client, dmNewBitsPerPel, pGlobalData); + /* Show a new spectrum bitmap */ + hSpectrumControl = GetDlgItem(hwndDlg, IDC_SETTINGS_SPECTRUM); + hSpectrumDC = GetDC(hSpectrumControl); + GetClientRect(hSpectrumControl, &client); + ShowColorSpectrum(hSpectrumDC, &client, dmNewBitsPerPel, pGlobalData); /* find if new parameters are valid */ Current = pGlobalData->CurrentDisplayDevice->CurrentSettings; @@ -588,20 +595,20 @@ UINT CALLBACK SettingsPageCallbackProc(HWND hwnd, UINT uMsg, LPPROPSHEETPAGE ppsp) { - UINT Ret = 0; - - switch (uMsg) - { - case PSPCB_CREATE: - Ret = RegisterMonitorSelectionControl(hApplet); - break; - - case PSPCB_RELEASE: - UnregisterMonitorSelectionControl(hApplet); - break; - } - - return Ret; + UINT Ret = 0; + + switch (uMsg) + { + case PSPCB_CREATE: + Ret = RegisterMonitorSelectionControl(hApplet); + break; + + case PSPCB_RELEASE: + UnregisterMonitorSelectionControl(hApplet); + break; + } + + return Ret; } /* Property page dialog callback */ @@ -612,7 +619,6 @@ pGlobalData = (PGLOBAL_DATA)GetWindowLongPtr(hwndDlg, DWLP_USER); - switch(uMsg) { case WM_INITDIALOG: @@ -625,8 +631,8 @@ LPDRAWITEMSTRUCT lpDrawItem; lpDrawItem = (LPDRAWITEMSTRUCT) lParam; - if(lpDrawItem->CtlID == IDC_SETTINGS_SPECTRUM) - ShowColorSpectrum(lpDrawItem->hDC, &lpDrawItem->rcItem, pGlobalData->CurrentDisplayDevice->CurrentSettings->dmBitsPerPel, pGlobalData); + if (lpDrawItem->CtlID == IDC_SETTINGS_SPECTRUM) + ShowColorSpectrum(lpDrawItem->hDC, &lpDrawItem->rcItem, pGlobalData->CurrentDisplayDevice->CurrentSettings->dmBitsPerPel, pGlobalData); break; } @@ -711,111 +717,111 @@ break; } - case WM_CONTEXTMENU: - { - HWND hwndMonSel; - HMENU hPopup; - UINT uiCmd; - POINT pt, ptClient; - INT Index; - - pt.x = (SHORT)LOWORD(lParam); - pt.y = (SHORT)HIWORD(lParam); - - hwndMonSel = GetDlgItem(hwndDlg, - IDC_SETTINGS_MONSEL); - if ((HWND)wParam == hwndMonSel) - { - if (pt.x == -1 && pt.y == -1) - { - RECT rcMon; - - Index = (INT)SendMessage(hwndMonSel, - MSLM_GETCURSEL, - 0, - 0); - - if (Index >= 0 && - (INT)SendMessage(hwndMonSel, - MSLM_GETMONITORRECT, - Index, - (LPARAM)&rcMon) > 0) - { - pt.x = rcMon.left + ((rcMon.right - rcMon.left) / 2); - pt.y = rcMon.top + ((rcMon.bottom - rcMon.top) / 2); - } - else - pt.x = pt.y = 0; - - MapWindowPoints(hwndMonSel, - NULL, - &pt, - 1); - } - else - { - ptClient = pt; - MapWindowPoints(NULL, - hwndMonSel, - &ptClient, - 1); - - Index = (INT)SendMessage(hwndMonSel, - MSLM_HITTEST, - (WPARAM)&ptClient, - 0); - } - - if (Index >= 0) - { - hPopup = LoadPopupMenu(hApplet, - MAKEINTRESOURCE(IDM_MONITOR_MENU)); - if (hPopup != NULL) - { - /* FIXME: Enable/Disable menu items */ - EnableMenuItem(hPopup, - ID_MENU_ATTACHED, - MF_BYCOMMAND | MF_DISABLED | MF_GRAYED); - EnableMenuItem(hPopup, - ID_MENU_PRIMARY, - MF_BYCOMMAND | MF_DISABLED | MF_GRAYED); - EnableMenuItem(hPopup, - ID_MENU_IDENTIFY, - MF_BYCOMMAND | MF_DISABLED | MF_GRAYED); - EnableMenuItem(hPopup, - ID_MENU_PROPERTIES, - MF_BYCOMMAND | MF_DISABLED | MF_GRAYED); - - uiCmd = (UINT)TrackPopupMenu(hPopup, - TPM_RETURNCMD | TPM_RIGHTBUTTON, - pt.x, - pt.y, - 0, - hwndDlg, - NULL); - - switch (uiCmd) - { - case ID_MENU_ATTACHED: - case ID_MENU_PRIMARY: - case ID_MENU_IDENTIFY: - case ID_MENU_PROPERTIES: - /* FIXME: Implement */ - break; - } - - DestroyMenu(hPopup); - } - } - } - break; - } + case WM_CONTEXTMENU: + { + HWND hwndMonSel; + HMENU hPopup; + UINT uiCmd; + POINT pt, ptClient; + INT Index; + + pt.x = (SHORT)LOWORD(lParam); + pt.y = (SHORT)HIWORD(lParam); + + hwndMonSel = GetDlgItem(hwndDlg, + IDC_SETTINGS_MONSEL); + if ((HWND)wParam == hwndMonSel) + { + if (pt.x == -1 && pt.y == -1) + { + RECT rcMon; + + Index = (INT)SendMessage(hwndMonSel, + MSLM_GETCURSEL, + 0, + 0); + + if (Index >= 0 && + (INT)SendMessage(hwndMonSel, + MSLM_GETMONITORRECT, + Index, + (LPARAM)&rcMon) > 0) + { + pt.x = rcMon.left + ((rcMon.right - rcMon.left) / 2); + pt.y = rcMon.top + ((rcMon.bottom - rcMon.top) / 2); + } + else + pt.x = pt.y = 0; + + MapWindowPoints(hwndMonSel, + NULL, + &pt, + 1); + } + else + { + ptClient = pt; + MapWindowPoints(NULL, + hwndMonSel, + &ptClient, + 1); + + Index = (INT)SendMessage(hwndMonSel, + MSLM_HITTEST, + (WPARAM)&ptClient, + 0); + } + + if (Index >= 0) + { + hPopup = LoadPopupMenu(hApplet, + MAKEINTRESOURCE(IDM_MONITOR_MENU)); + if (hPopup != NULL) + { + /* FIXME: Enable/Disable menu items */ + EnableMenuItem(hPopup, + ID_MENU_ATTACHED, + MF_BYCOMMAND | MF_DISABLED | MF_GRAYED); + EnableMenuItem(hPopup, + ID_MENU_PRIMARY, + MF_BYCOMMAND | MF_DISABLED | MF_GRAYED); + EnableMenuItem(hPopup, + ID_MENU_IDENTIFY, + MF_BYCOMMAND | MF_DISABLED | MF_GRAYED); + EnableMenuItem(hPopup, + ID_MENU_PROPERTIES, + MF_BYCOMMAND | MF_DISABLED | MF_GRAYED); + + uiCmd = (UINT)TrackPopupMenu(hPopup, + TPM_RETURNCMD | TPM_RIGHTBUTTON, + pt.x, + pt.y, + 0, + hwndDlg, + NULL); + + switch (uiCmd) + { + case ID_MENU_ATTACHED: + case ID_MENU_PRIMARY: + case ID_MENU_IDENTIFY: + case ID_MENU_PROPERTIES: + /* FIXME: Implement */ + break; + } + + DestroyMenu(hPopup); + } + } + } + break; + } case WM_DESTROY: { - INT i; - + INT i; PDISPLAY_DEVICE_ENTRY Current = pGlobalData->DisplayDeviceList; + while (Current != NULL) { PDISPLAY_DEVICE_ENTRY Next = Current->Flink; @@ -832,11 +838,11 @@ HeapFree(GetProcessHeap(), 0, pGlobalData); - for(i = 0; i < NUM_SPECTRUM_BITMAPS; i++) - { - if(pGlobalData->hSpectrumBitmaps[i]) - DeleteObject(pGlobalData->hSpectrumBitmaps[i]); - } + for (i = 0; i < NUM_SPECTRUM_BITMAPS; i++) + { + if (pGlobalData->hSpectrumBitmaps[i]) + DeleteObject(pGlobalData->hSpectrumBitmaps[i]); + } } } return FALSE;
16 years, 4 months
1
0
0
0
[cfinck] 35035: - Set "lake.bmp" as the default wallpaper - Add a shortcut to "Download !" to the Desktop - Change the version number in the Explorer start menu bitmap
by cfinck@svn.reactos.org
Author: cfinck Date: Sat Aug 2 08:10:59 2008 New Revision: 35035 URL:
http://svn.reactos.org/svn/reactos?rev=35035&view=rev
Log: - Set "lake.bmp" as the default wallpaper - Add a shortcut to "Download !" to the Desktop - Change the version number in the Explorer start menu bitmap Modified: branches/ros-branch-0_3_6/reactos/base/shell/explorer/res/logov.bmp branches/ros-branch-0_3_6/reactos/boot/bootdata/hivedef_i386.inf branches/ros-branch-0_3_6/reactos/dll/win32/syssetup/install.c Modified: branches/ros-branch-0_3_6/reactos/base/shell/explorer/res/logov.bmp URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_6/reactos/base/s…
============================================================================== Binary files - no diff available. Modified: branches/ros-branch-0_3_6/reactos/boot/bootdata/hivedef_i386.inf URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_6/reactos/boot/b…
============================================================================== --- branches/ros-branch-0_3_6/reactos/boot/bootdata/hivedef_i386.inf [iso-8859-1] (original) +++ branches/ros-branch-0_3_6/reactos/boot/bootdata/hivedef_i386.inf [iso-8859-1] Sat Aug 2 08:10:59 2008 @@ -20,7 +20,7 @@ HKCU,"Control Panel\Desktop","HungAppTimeout",0x00000002,"5000" HKCU,"Control Panel\Desktop","SCRNSAVE.EXE",0x00000000,"" HKCU,"Control Panel\Desktop","WaitToKillAppTimeout",0x00000002,"20000" -HKCU,"Control Panel\Desktop","Wallpaper",0x00000000,"" +HKCU,"Control Panel\Desktop","Wallpaper",0x00000000,"%SystemRoot%\lake.bmp" HKCU,"Control Panel\International",,0x00000012 HKCU,"Control Panel\International","Locale",0x00000000,"0409" HKCU,"Control Panel\International\Geo","Nation",0x00000000,"1" Modified: branches/ros-branch-0_3_6/reactos/dll/win32/syssetup/install.c URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_6/reactos/dll/wi…
============================================================================== --- branches/ros-branch-0_3_6/reactos/dll/win32/syssetup/install.c [iso-8859-1] (original) +++ branches/ros-branch-0_3_6/reactos/dll/win32/syssetup/install.c [iso-8859-1] Sat Aug 2 08:10:59 2008 @@ -756,6 +756,7 @@ /* Create desktop shortcuts */ CreateShortcut(CSIDL_DESKTOP, NULL, IDS_SHORT_CMD, _T("%SystemRoot%\\system32\\cmd.exe"), IDS_CMT_CMD, TRUE); + CreateShortcut(CSIDL_DESKTOP, NULL, IDS_SHORT_DOWNLOADER, _T("%SystemRoot%\\system32\\downloader.exe"), IDS_CMT_DOWNLOADER, TRUE); /* Create program startmenu shortcuts */ CreateShortcut(CSIDL_PROGRAMS, NULL, IDS_SHORT_EXPLORER, _T("%SystemRoot%\\explorer.exe"), IDS_CMT_EXPLORER, TRUE);
16 years, 4 months
1
0
0
0
[cfinck] 35034: Hack: Copy the toolbar image on our own instead of using CopyImage to hackfix the messed up toolbar graphics as it was done for previous releases.
by cfinck@svn.reactos.org
Author: cfinck Date: Sat Aug 2 08:02:42 2008 New Revision: 35034 URL:
http://svn.reactos.org/svn/reactos?rev=35034&view=rev
Log: Hack: Copy the toolbar image on our own instead of using CopyImage to hackfix the messed up toolbar graphics as it was done for previous releases. Modified: branches/ros-branch-0_3_6/reactos/dll/win32/comctl32/toolbar.c Modified: branches/ros-branch-0_3_6/reactos/dll/win32/comctl32/toolbar.c URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_6/reactos/dll/wi…
============================================================================== --- branches/ros-branch-0_3_6/reactos/dll/win32/comctl32/toolbar.c [iso-8859-1] (original) +++ branches/ros-branch-0_3_6/reactos/dll/win32/comctl32/toolbar.c [iso-8859-1] Sat Aug 2 08:02:42 2008 @@ -2665,7 +2665,33 @@ TRACE("adding hInst=%p nID=%d nButtons=%d\n", bitmap->hInst, bitmap->nID, bitmap->nButtons); /* Add bitmaps to the default image list */ if (bitmap->hInst == NULL) /* a handle was passed */ - hbmLoad = (HBITMAP)CopyImage(ULongToHandle(bitmap->nID), IMAGE_BITMAP, 0, 0, 0); + { + BITMAP bmp; + HBITMAP hOldBitmapBitmap, hOldBitmapLoad; + HDC hdcImage, hdcBitmap; + + /* copy the bitmap before adding it so that the user's bitmap + * doesn't get modified. + */ + GetObjectW ((HBITMAP)bitmap->nID, sizeof(BITMAP), (LPVOID)&bmp); + + hdcImage = CreateCompatibleDC(0); + hdcBitmap = CreateCompatibleDC(0); + + /* create new bitmap */ + hbmLoad = CreateBitmap (bmp.bmWidth, bmp.bmHeight, bmp.bmPlanes, bmp.bmBitsPixel, NULL); + hOldBitmapBitmap = SelectObject(hdcBitmap, (HBITMAP)bitmap->nID); + hOldBitmapLoad = SelectObject(hdcImage, hbmLoad); + + /* Copy the user's image */ + BitBlt (hdcImage, 0, 0, bmp.bmWidth, bmp.bmHeight, + hdcBitmap, 0, 0, SRCCOPY); + + SelectObject (hdcImage, hOldBitmapLoad); + SelectObject (hdcBitmap, hOldBitmapBitmap); + DeleteDC (hdcImage); + DeleteDC (hdcBitmap); + } else hbmLoad = CreateMappedBitmap(bitmap->hInst, bitmap->nID, 0, NULL, 0);
16 years, 4 months
1
0
0
0
[cfinck] 35033: Hack: Hackfix the HitTest problem in mstsc as it was done for previous releases
by cfinck@svn.reactos.org
Author: cfinck Date: Sat Aug 2 08:01:08 2008 New Revision: 35033 URL:
http://svn.reactos.org/svn/reactos?rev=35033&view=rev
Log: Hack: Hackfix the HitTest problem in mstsc as it was done for previous releases Modified: branches/ros-branch-0_3_6/reactos/base/applications/mstsc/connectdialog.c Modified: branches/ros-branch-0_3_6/reactos/base/applications/mstsc/connectdialog.c URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_6/reactos/base/a…
============================================================================== --- branches/ros-branch-0_3_6/reactos/base/applications/mstsc/connectdialog.c [iso-8859-1] (original) +++ branches/ros-branch-0_3_6/reactos/base/applications/mstsc/connectdialog.c [iso-8859-1] Sat Aug 2 08:01:08 2008 @@ -197,19 +197,12 @@ static VOID -GeneralOnInit(HWND hwnd, - PINFO pInfo) -{ - SetWindowLongPtrW(hwnd, - GWLP_USERDATA, - (LONG_PTR)pInfo); - - pInfo->hGeneralPage = hwnd; - +GeneralOnInit(PINFO pInfo) +{ SetWindowPos(pInfo->hGeneralPage, NULL, - 2, - 22, + 13, + 110, 0, 0, SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOSIZE | SWP_NOZORDER); @@ -255,13 +248,14 @@ WPARAM wParam, LPARAM lParam) { - PINFO pInfo = (PINFO)GetWindowLongPtrW(hDlg, + PINFO pInfo = (PINFO)GetWindowLongPtrW(GetParent(hDlg), GWLP_USERDATA); switch (message) { case WM_INITDIALOG: - GeneralOnInit(hDlg, (PINFO)lParam); + pInfo->hGeneralPage = hDlg; + GeneralOnInit(pInfo); return TRUE; case WM_COMMAND: @@ -745,23 +739,16 @@ static VOID -DisplayOnInit(HWND hwnd, - PINFO pInfo) +DisplayOnInit(PINFO pInfo) { DISPLAY_DEVICEW displayDevice; DWORD iDevNum = 0; BOOL GotDev = FALSE; - SetWindowLongPtrW(hwnd, - GWLP_USERDATA, - (LONG_PTR)pInfo); - - pInfo->hDisplayPage = hwnd; - SetWindowPos(pInfo->hDisplayPage, NULL, - 2, - 22, + 13, + 110, 0, 0, SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOSIZE | SWP_NOZORDER); @@ -835,13 +822,14 @@ WPARAM wParam, LPARAM lParam) { - PINFO pInfo = (PINFO)GetWindowLongPtrW(hDlg, + PINFO pInfo = (PINFO)GetWindowLongPtrW(GetParent(hDlg), GWLP_USERDATA); switch (message) { case WM_INITDIALOG: - DisplayOnInit(hDlg, (PINFO)lParam); + pInfo->hDisplayPage = hDlg; + DisplayOnInit(pInfo); return TRUE; case WM_DRAWITEM: @@ -983,11 +971,10 @@ pInfo->hTab = GetDlgItem(hwnd, IDC_TAB); if (pInfo->hTab) { - if (CreateDialogParamW(hInst, - MAKEINTRESOURCEW(IDD_GENERAL), - pInfo->hTab, - (DLGPROC)GeneralDlgProc, - (LPARAM)pInfo)) + if (CreateDialogW(hInst, + MAKEINTRESOURCEW(IDD_GENERAL), + hwnd, + (DLGPROC)GeneralDlgProc)) { WCHAR str[256]; ZeroMemory(&item, sizeof(TCITEM)); @@ -998,11 +985,10 @@ (void)TabCtrl_InsertItem(pInfo->hTab, 0, &item); } - if (CreateDialogParamW(hInst, - MAKEINTRESOURCEW(IDD_DISPLAY), - pInfo->hTab, - (DLGPROC)DisplayDlgProc, - (LPARAM)pInfo)) + if (CreateDialogW(hInst, + MAKEINTRESOURCEW(IDD_DISPLAY), + hwnd, + (DLGPROC)DisplayDlgProc)) { WCHAR str[256]; ZeroMemory(&item, sizeof(TCITEM));
16 years, 4 months
1
0
0
0
← Newer
1
...
78
79
80
81
82
83
84
85
86
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
Results per page:
10
25
50
100
200