---
 dlls/advapi32/advapi32.spec |    2 +-
 dlls/advapi32/security.c    |   19 +++++++++++++++++++
 2 files changed, 20 insertions(+), 1 deletion(-)

diff --git a/dlls/advapi32/advapi32.spec b/dlls/advapi32/advapi32.spec
index 38342dc..027d9d2 100644
--- a/dlls/advapi32/advapi32.spec
+++ b/dlls/advapi32/advapi32.spec
@@ -126,7 +126,7 @@
 # @ stub CreateProcessAsUserSecure
 @ stdcall CreateProcessAsUserW(long wstr wstr ptr ptr long long ptr wstr ptr ptr)
 @ stdcall CreateProcessWithLogonW(wstr wstr wstr long wstr wstr long ptr wstr ptr ptr)
-# @ stub CreateProcessWithTokenW
+@ stdcall CreateProcessWithTokenW(long long wstr wstr long ptr wstr ptr ptr)
 @ stdcall CreateRestrictedToken(long long long ptr long ptr long ptr ptr)
 @ stdcall CreateServiceA(long str str long long long long str str ptr str str str)
 @ stdcall CreateServiceW(long wstr wstr long long long long wstr wstr ptr wstr wstr wstr)
diff --git a/dlls/advapi32/security.c b/dlls/advapi32/security.c
index ac642b6..f714749 100644
--- a/dlls/advapi32/security.c
+++ b/dlls/advapi32/security.c
@@ -5275,6 +5275,25 @@ BOOL WINAPI CreateProcessWithLogonW( LPCWSTR lpUsername, LPCWSTR lpDomain, LPCWS
     return FALSE;
 }
 
+BOOL WINAPI CreateProcessWithTokenW(HANDLE token, DWORD logon_flags, LPCWSTR application_name, LPWSTR command_line,
+        DWORD creation_flags, void *environment, LPCWSTR current_directory, STARTUPINFOW *startup_info,
+        PROCESS_INFORMATION *process_information )
+{
+    FIXME("%p 0x%08x %s %s 0x%08x %p %s %p %p - semi-stub\n", token,
+          logon_flags, debugstr_w(application_name), debugstr_w(command_line),
+          creation_flags, environment, debugstr_w(current_directory),
+          startup_info, process_information);
+
+    /* FIXME: check if handles should be inherited */
+    if (!CreateProcessW (application_name, command_line, NULL, NULL, FALSE, creation_flags, environment,
+            current_directory, startup_info, process_information))
+    {
+        return FALSE;
+    }
+
+    return TRUE;
+}
+
 /******************************************************************************
  * DuplicateTokenEx [ADVAPI32.@]
  */
-- 
1.7.10.4
