You've already forked wine-staging
mirror of
https://gitlab.winehq.org/wine/wine-staging.git
synced 2025-04-13 14:42:51 -07:00
Compare commits
137 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
34ba08404f | ||
|
7b199110bb | ||
|
3d3cbfce86 | ||
|
0547bb4578 | ||
|
f20c33fa04 | ||
|
a644c49d6d | ||
|
d2102728fe | ||
|
a93d3b6369 | ||
|
09fdb3b5c9 | ||
|
5897bc1d27 | ||
|
f8b6fde40c | ||
|
34d5c3568f | ||
|
44af049de7 | ||
|
c747e46d75 | ||
|
1f89c15143 | ||
|
7ec998e17a | ||
|
186c17f454 | ||
|
4a427fa757 | ||
|
5bcba4ef5a | ||
|
acc0de4def | ||
|
3790a70510 | ||
|
e7c08665ab | ||
|
a11594e19e | ||
|
bbebe570f3 | ||
|
89c049ee68 | ||
|
f4cb879b3d | ||
|
cb2a6e06e1 | ||
|
3a33c70a9a | ||
|
64efb6f0d3 | ||
|
404b698d44 | ||
|
a2ca43d98b | ||
|
0b1ffe4b94 | ||
|
5d8901ac21 | ||
|
6b24c39d32 | ||
|
15f4220e49 | ||
|
b0ddfb4172 | ||
|
0fb17feeaa | ||
|
ba02aa0e4d | ||
|
e83fdffe77 | ||
|
750044c08c | ||
|
dfc989712e | ||
|
783002b5de | ||
|
806bbc0198 | ||
|
e4debaae9b | ||
|
9a7b25dfd2 | ||
|
43a3110e95 | ||
|
0d3a7a3596 | ||
|
101e672955 | ||
|
29ce68fa31 | ||
|
3486cceeba | ||
|
37fa6ccbbd | ||
|
9aeea5d12e | ||
|
aa8a3d90cb | ||
|
811467bf6a | ||
|
2a9a56c4d0 | ||
|
d0873d2c72 | ||
|
4046ffe6c9 | ||
|
3b5ea332d6 | ||
|
81e3e6dafa | ||
|
41cb9f5179 | ||
|
41e15516bd | ||
|
6347bdd1fc | ||
|
677b445b0d | ||
|
a2f82c5c85 | ||
|
cfe1b94e0f | ||
|
2be4bfb8fe | ||
|
cae1b3eba0 | ||
|
32b29ad4d8 | ||
|
a6054cf2e9 | ||
|
f6dacd2f9a | ||
|
43c064ef3c | ||
|
5c5a8f3b2c | ||
|
bd135b1477 | ||
|
9692b2e5eb | ||
|
bcf5899a3c | ||
|
73480ec459 | ||
|
fd3372e71c | ||
|
3dec70bf32 | ||
|
b201ee708b | ||
|
74534094a0 | ||
|
1830eaa655 | ||
|
f168899ce1 | ||
|
f8ce6cbb21 | ||
|
64877514fb | ||
|
310072bb63 | ||
|
2f619b2a53 | ||
|
76f8eb15f1 | ||
|
6364ada0ad | ||
|
caa2471e20 | ||
|
2414b1da6a | ||
|
7ab49f09a2 | ||
|
a3d08de2b8 | ||
|
1c969cbbed | ||
|
0e7472e7a3 | ||
|
f3e785a3a8 | ||
|
dfddef9654 | ||
|
d87ec36ccf | ||
|
a3710ff21f | ||
|
0e67af3d09 | ||
|
8b1e0eec1d | ||
|
b8ca0eae9f | ||
|
350eb136a5 | ||
|
f40763d8a5 | ||
|
4462586c80 | ||
|
aae98229b0 | ||
|
7ad10427be | ||
|
9912133b6a | ||
|
14450482bc | ||
|
a8947d8016 | ||
|
a5a402a003 | ||
|
2505882bc6 | ||
|
760b2fbc35 | ||
|
909415c8d0 | ||
|
5cd622f667 | ||
|
4004f81390 | ||
|
28c6e62cb9 | ||
|
df37ef7599 | ||
|
3b4ce945a6 | ||
|
6d67766abd | ||
|
143e59bfe2 | ||
|
7dbce711de | ||
|
53bbade133 | ||
|
fe5b02cbbc | ||
|
abb7ae8b1c | ||
|
0fc2f15ac5 | ||
|
c646dc9283 | ||
|
d0b0b5be24 | ||
|
8cbc70df46 | ||
|
a8684593e2 | ||
|
e015f0590c | ||
|
dea57ccd5f | ||
|
fd8727a320 | ||
|
dc77e28b0f | ||
|
213037cb33 | ||
|
fce121fcd9 | ||
|
2dc013940d | ||
|
8229c98169 |
128
.github/workflows/macOS.yml
vendored
Normal file
128
.github/workflows/macOS.yml
vendored
Normal file
@@ -0,0 +1,128 @@
|
||||
name: MacOS
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ master ]
|
||||
pull_request:
|
||||
branches: [ master ]
|
||||
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
wine-staging:
|
||||
runs-on: macos-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
brew install --cask xquartz
|
||||
brew install bison \
|
||||
faudio \
|
||||
gphoto2 \
|
||||
gst-plugins-base \
|
||||
little-cms2 \
|
||||
mingw-w64 \
|
||||
molten-vk \
|
||||
mpg123
|
||||
|
||||
- name: Add bison & krb5 to $PATH
|
||||
run: |
|
||||
set -eu
|
||||
echo "$(brew --prefix bison)/bin" >> $GITHUB_PATH
|
||||
echo "$(brew --prefix krb5)/bin" >> $GITHUB_PATH
|
||||
|
||||
- name: Get upstream-commit
|
||||
run: |
|
||||
mkdir $GITHUB_WORKSPACE/wine
|
||||
cd wine
|
||||
git init
|
||||
git fetch git://source.winehq.org/git/wine.git $($GITHUB_WORKSPACE/patches/patchinstall.sh --upstream-commit) --depth=1
|
||||
git checkout $($GITHUB_WORKSPACE/patches/patchinstall.sh --upstream-commit)
|
||||
|
||||
- name: Run patchinstall.sh --all
|
||||
run: |
|
||||
$GITHUB_WORKSPACE/patches/patchinstall.sh DESTDIR=$GITHUB_WORKSPACE/wine --all
|
||||
|
||||
- name: Configure wine64
|
||||
env:
|
||||
LDFLAGS: "-Wl,-rpath,/opt/X11/lib"
|
||||
# Avoid weird linker errors with Xcode 10 and later
|
||||
MACOSX_DEPLOYMENT_TARGET: "10.14"
|
||||
run: |
|
||||
cd $GITHUB_WORKSPACE/wine
|
||||
./configure --enable-win64 \
|
||||
--without-alsa \
|
||||
--without-capi \
|
||||
--without-dbus \
|
||||
--without-inotify \
|
||||
--without-oss \
|
||||
--without-pulse \
|
||||
--without-udev \
|
||||
--without-v4l2 \
|
||||
--x-include=/opt/X11/include \
|
||||
--x-lib=/opt/X11/lib
|
||||
|
||||
- name: Build wine64
|
||||
run: |
|
||||
cd $GITHUB_WORKSPACE/wine
|
||||
make -j$(sysctl -n hw.ncpu 2>/dev/null)
|
||||
|
||||
wine-devel:
|
||||
runs-on: macos-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
brew install --cask xquartz
|
||||
brew install bison \
|
||||
faudio \
|
||||
gphoto2 \
|
||||
gst-plugins-base \
|
||||
little-cms2 \
|
||||
mingw-w64 \
|
||||
molten-vk \
|
||||
mpg123
|
||||
|
||||
- name: Add bison & krb5 to $PATH
|
||||
run: |
|
||||
set -eu
|
||||
echo "$(brew --prefix bison)/bin" >> $GITHUB_PATH
|
||||
echo "$(brew --prefix krb5)/bin" >> $GITHUB_PATH
|
||||
|
||||
- name: Get upstream-commit
|
||||
run: |
|
||||
mkdir $GITHUB_WORKSPACE/wine
|
||||
cd wine
|
||||
git init
|
||||
git fetch git://source.winehq.org/git/wine.git $($GITHUB_WORKSPACE/patches/patchinstall.sh --upstream-commit) --depth=1
|
||||
git checkout $($GITHUB_WORKSPACE/patches/patchinstall.sh --upstream-commit)
|
||||
|
||||
- name: Configure wine64
|
||||
env:
|
||||
LDFLAGS: "-Wl,-rpath,/opt/X11/lib"
|
||||
# Avoid weird linker errors with Xcode 10 and later
|
||||
MACOSX_DEPLOYMENT_TARGET: "10.14"
|
||||
run: |
|
||||
cd $GITHUB_WORKSPACE/wine
|
||||
|
||||
cd $GITHUB_WORKSPACE/wine
|
||||
./configure --enable-win64 \
|
||||
--without-alsa \
|
||||
--without-capi \
|
||||
--without-dbus \
|
||||
--without-inotify \
|
||||
--without-oss \
|
||||
--without-pulse \
|
||||
--without-udev \
|
||||
--without-v4l2 \
|
||||
--x-include=/opt/X11/include \
|
||||
--x-lib=/opt/X11/lib
|
||||
|
||||
- name: Build wine64
|
||||
run: |
|
||||
cd $GITHUB_WORKSPACE/wine
|
||||
make -j$(sysctl -n hw.ncpu 2>/dev/null)
|
@@ -1,15 +1,14 @@
|
||||
From ce5e1fc75139e4de9d92dfe27b4a513a96da013c Mon Sep 17 00:00:00 2001
|
||||
From cfcc687562d4fa68b507cbf2c29722ef523d26aa Mon Sep 17 00:00:00 2001
|
||||
From: Sebastian Lackner <sebastian@fds-team.de>
|
||||
Date: Thu, 2 Oct 2014 19:53:46 +0200
|
||||
Subject: [PATCH] winelib: Append '(Staging)' at the end of the version string.
|
||||
|
||||
---
|
||||
Makefile.in | 2 +-
|
||||
dlls/ntdll/Makefile.in | 1 +
|
||||
2 files changed, 2 insertions(+), 1 deletion(-)
|
||||
Makefile.in | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Makefile.in b/Makefile.in
|
||||
index 307a95b3b1a..61019fed949 100644
|
||||
index b52495f741f..d5a8cad20da 100644
|
||||
--- a/Makefile.in
|
||||
+++ b/Makefile.in
|
||||
@@ -116,7 +116,7 @@ install-manpages:: manpages
|
||||
@@ -21,15 +20,6 @@ index 307a95b3b1a..61019fed949 100644
|
||||
|
||||
programs/winetest/build.rc: dummy
|
||||
@build="STRINGTABLE { 1 \"`GIT_DIR=$(srcdir)/.git git rev-parse HEAD 2>/dev/null`\" }" && (echo $$build | cmp -s - $@) || echo $$build >$@ || (rm -f $@ && exit 1)
|
||||
diff --git a/dlls/ntdll/Makefile.in b/dlls/ntdll/Makefile.in
|
||||
index f39ffb42c6f..67847bb9392 100644
|
||||
--- a/dlls/ntdll/Makefile.in
|
||||
+++ b/dlls/ntdll/Makefile.in
|
||||
@@ -79,3 +79,4 @@ unix_loader_EXTRADEFS = \
|
||||
-DBINDIR=\"${bindir}\" \
|
||||
-DDLL_TO_BINDIR=\"`${MAKEDEP} -R ${dlldir} ${bindir}`\" \
|
||||
-DBIN_TO_DATADIR=\"`${MAKEDEP} -R ${bindir} ${datadir}/wine`\"
|
||||
+
|
||||
--
|
||||
2.28.0
|
||||
2.20.1
|
||||
|
||||
|
@@ -1 +0,0 @@
|
||||
#Depends: ntdll-FLS_Callbacks
|
@@ -1,137 +0,0 @@
|
||||
From d2e98b2054a5af671fd81ded32f2cf60a062312c Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Sat, 5 Aug 2017 00:26:03 +0200
|
||||
Subject: [PATCH] server: Implement token elevation information.
|
||||
|
||||
---
|
||||
dlls/ntdll/unix/security.c | 16 ++++++++++++----
|
||||
server/protocol.def | 8 ++++++++
|
||||
server/token.c | 22 +++++++++++++++++++---
|
||||
3 files changed, 39 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/dlls/ntdll/unix/security.c b/dlls/ntdll/unix/security.c
|
||||
index d063d43d6d4..03a81afa46e 100644
|
||||
--- a/dlls/ntdll/unix/security.c
|
||||
+++ b/dlls/ntdll/unix/security.c
|
||||
@@ -390,19 +390,27 @@ NTSTATUS WINAPI NtQueryInformationToken( HANDLE token, TOKEN_INFORMATION_CLASS c
|
||||
break;
|
||||
|
||||
case TokenElevationType:
|
||||
+ SERVER_START_REQ( get_token_elevation_type )
|
||||
{
|
||||
TOKEN_ELEVATION_TYPE *type = info;
|
||||
- FIXME("QueryInformationToken( ..., TokenElevationType, ...) semi-stub\n");
|
||||
- *type = TokenElevationTypeFull;
|
||||
+ req->handle = wine_server_obj_handle( token );
|
||||
+ status = wine_server_call( req );
|
||||
+ if (status == STATUS_SUCCESS)
|
||||
+ *type = reply->elevation;
|
||||
}
|
||||
+ SERVER_END_REQ;
|
||||
break;
|
||||
|
||||
case TokenElevation:
|
||||
+ SERVER_START_REQ( get_token_elevation_type )
|
||||
{
|
||||
TOKEN_ELEVATION *elevation = info;
|
||||
- FIXME("QueryInformationToken( ..., TokenElevation, ...) semi-stub\n");
|
||||
- elevation->TokenIsElevated = TRUE;
|
||||
+ req->handle = wine_server_obj_handle( token );
|
||||
+ status = wine_server_call( req );
|
||||
+ if (status == STATUS_SUCCESS)
|
||||
+ elevation->TokenIsElevated = (reply->elevation == TokenElevationTypeFull);
|
||||
}
|
||||
+ SERVER_END_REQ;
|
||||
break;
|
||||
|
||||
case TokenSessionId:
|
||||
diff --git a/server/protocol.def b/server/protocol.def
|
||||
index ee07b1eca14..84f0b577d72 100644
|
||||
--- a/server/protocol.def
|
||||
+++ b/server/protocol.def
|
||||
@@ -3566,6 +3566,14 @@ struct handle_info
|
||||
@END
|
||||
|
||||
|
||||
+/* Get elevation level of token */
|
||||
+@REQ(get_token_elevation_type)
|
||||
+ obj_handle_t handle; /* handle to the object */
|
||||
+@REPLY
|
||||
+ unsigned int elevation; /* elevation level */
|
||||
+@END
|
||||
+
|
||||
+
|
||||
/* Create I/O completion port */
|
||||
@REQ(create_completion)
|
||||
unsigned int access; /* desired access to a port */
|
||||
diff --git a/server/token.c b/server/token.c
|
||||
index 38a4c203d54..14343637af5 100644
|
||||
--- a/server/token.c
|
||||
+++ b/server/token.c
|
||||
@@ -110,6 +110,7 @@ struct token
|
||||
ACL *default_dacl; /* the default DACL to assign to objects created by this user */
|
||||
TOKEN_SOURCE source; /* source of the token */
|
||||
int impersonation_level; /* impersonation level this token is capable of if non-primary token */
|
||||
+ TOKEN_ELEVATION_TYPE elevation; /* elevation level */
|
||||
};
|
||||
|
||||
struct privilege
|
||||
@@ -552,7 +553,7 @@ static struct token *create_token( unsigned primary, const SID *user,
|
||||
const LUID_AND_ATTRIBUTES *privs, unsigned int priv_count,
|
||||
const ACL *default_dacl, TOKEN_SOURCE source,
|
||||
const luid_t *modified_id,
|
||||
- int impersonation_level )
|
||||
+ int impersonation_level, TOKEN_ELEVATION_TYPE elevation )
|
||||
{
|
||||
struct token *token = alloc_object( &token_ops );
|
||||
if (token)
|
||||
@@ -574,6 +575,7 @@ static struct token *create_token( unsigned primary, const SID *user,
|
||||
token->impersonation_level = impersonation_level;
|
||||
token->default_dacl = NULL;
|
||||
token->primary_group = NULL;
|
||||
+ token->elevation = elevation;
|
||||
|
||||
/* copy user */
|
||||
token->user = memdup( user, security_sid_len( user ));
|
||||
@@ -689,7 +691,8 @@ struct token *token_duplicate( struct token *src_token, unsigned primary,
|
||||
token = create_token( primary, src_token->user, NULL, 0,
|
||||
NULL, 0, src_token->default_dacl,
|
||||
src_token->source, modified_id,
|
||||
- impersonation_level );
|
||||
+ impersonation_level,
|
||||
+ src_token->elevation );
|
||||
if (!token) return token;
|
||||
|
||||
/* copy groups */
|
||||
@@ -895,7 +898,7 @@ struct token *token_create_admin( void )
|
||||
static const TOKEN_SOURCE admin_source = {"SeMgr", {0, 0}};
|
||||
token = create_token( TRUE, user_sid, admin_groups, ARRAY_SIZE( admin_groups ),
|
||||
admin_privs, ARRAY_SIZE( admin_privs ), default_dacl,
|
||||
- admin_source, NULL, -1 );
|
||||
+ admin_source, NULL, -1, TokenElevationTypeFull );
|
||||
/* we really need a primary group */
|
||||
assert( token->primary_group );
|
||||
}
|
||||
@@ -1634,6 +1637,19 @@ DECL_HANDLER(get_token_statistics)
|
||||
}
|
||||
}
|
||||
|
||||
+DECL_HANDLER(get_token_elevation_type)
|
||||
+{
|
||||
+ struct token *token;
|
||||
+
|
||||
+ if ((token = (struct token *)get_handle_obj( current->process, req->handle,
|
||||
+ TOKEN_QUERY,
|
||||
+ &token_ops )))
|
||||
+ {
|
||||
+ reply->elevation = token->elevation;
|
||||
+ release_object( token );
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
DECL_HANDLER(get_token_default_dacl)
|
||||
{
|
||||
struct token *token;
|
||||
--
|
||||
2.27.0
|
||||
|
@@ -1,81 +0,0 @@
|
||||
From 7e73f449d158f0d6a6b6b421d073dbaf1741e1c7 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Mon, 7 Aug 2017 02:22:11 +0200
|
||||
Subject: server: Correctly treat zero access mask in duplicate_token
|
||||
wineserver call.
|
||||
|
||||
---
|
||||
dlls/advapi32/tests/security.c | 14 +++++++-------
|
||||
server/token.c | 3 ++-
|
||||
2 files changed, 9 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/dlls/advapi32/tests/security.c b/dlls/advapi32/tests/security.c
|
||||
index 4a03db27e69..f1a64e29dea 100644
|
||||
--- a/dlls/advapi32/tests/security.c
|
||||
+++ b/dlls/advapi32/tests/security.c
|
||||
@@ -7438,7 +7438,7 @@ static void test_token_security_descriptor(void)
|
||||
ret = DuplicateTokenEx(token4, 0, NULL, SecurityImpersonation, TokenImpersonation, &token5);
|
||||
ok(ret, "DuplicateTokenEx failed with error %u\n", GetLastError());
|
||||
ret = SetThreadToken(NULL, token5);
|
||||
- todo_wine ok(ret, "SetThreadToken failed with error %u\n", GetLastError());
|
||||
+ ok(ret, "SetThreadToken failed with error %u\n", GetLastError());
|
||||
CloseHandle(token4);
|
||||
|
||||
/* Restrict current process token while impersonating a medium integrity token */
|
||||
@@ -7503,16 +7503,16 @@ static void test_token_security_descriptor(void)
|
||||
|
||||
size = 0;
|
||||
ret = GetKernelObjectSecurity(token6, LABEL_SECURITY_INFORMATION, NULL, 0, &size);
|
||||
- todo_wine ok(!ret && GetLastError() == ERROR_INSUFFICIENT_BUFFER,
|
||||
+ ok(!ret && GetLastError() == ERROR_INSUFFICIENT_BUFFER,
|
||||
"Unexpected GetKernelObjectSecurity return value %u, error %u\n", ret, GetLastError());
|
||||
|
||||
sd3 = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, size);
|
||||
ret = GetKernelObjectSecurity(token6, LABEL_SECURITY_INFORMATION, sd3, size, &size);
|
||||
- todo_wine ok(ret, "GetKernelObjectSecurity failed with error %u\n", GetLastError());
|
||||
+ ok(ret, "GetKernelObjectSecurity failed with error %u\n", GetLastError());
|
||||
|
||||
sacl = NULL;
|
||||
ret = GetSecurityDescriptorSacl(sd3, &present, &sacl, &defaulted);
|
||||
- todo_wine ok(ret, "GetSecurityDescriptorSacl failed with error %u\n", GetLastError());
|
||||
+ ok(ret, "GetSecurityDescriptorSacl failed with error %u\n", GetLastError());
|
||||
todo_wine ok(present, "No SACL in the security descriptor\n");
|
||||
todo_wine ok(sacl != NULL, "NULL SACL in the security descriptor\n");
|
||||
|
||||
@@ -7606,16 +7606,16 @@ static void test_token_security_descriptor(void)
|
||||
|
||||
size = 0;
|
||||
ret = GetKernelObjectSecurity(token4, LABEL_SECURITY_INFORMATION, NULL, 0, &size);
|
||||
- todo_wine ok(!ret && GetLastError() == ERROR_INSUFFICIENT_BUFFER,
|
||||
+ ok(!ret && GetLastError() == ERROR_INSUFFICIENT_BUFFER,
|
||||
"Unexpected GetKernelObjectSecurity return value %u, error %u\n", ret, GetLastError());
|
||||
|
||||
sd3 = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, size);
|
||||
ret = GetKernelObjectSecurity(token4, LABEL_SECURITY_INFORMATION, sd3, size, &size);
|
||||
- todo_wine ok(ret, "GetKernelObjectSecurity failed with error %u\n", GetLastError());
|
||||
+ ok(ret, "GetKernelObjectSecurity failed with error %u\n", GetLastError());
|
||||
|
||||
sacl = NULL;
|
||||
ret = GetSecurityDescriptorSacl(sd3, &present, &sacl, &defaulted);
|
||||
- todo_wine ok(ret, "GetSecurityDescriptorSacl failed with error %u\n", GetLastError());
|
||||
+ ok(ret, "GetSecurityDescriptorSacl failed with error %u\n", GetLastError());
|
||||
todo_wine ok(present, "No SACL in the security descriptor\n");
|
||||
todo_wine ok(sacl != NULL, "NULL SACL in the security descriptor\n");
|
||||
|
||||
diff --git a/server/token.c b/server/token.c
|
||||
index 6a1085bae12..292e1df80fd 100644
|
||||
--- a/server/token.c
|
||||
+++ b/server/token.c
|
||||
@@ -1376,7 +1376,8 @@ DECL_HANDLER(duplicate_token)
|
||||
struct token *token = token_duplicate( src_token, req->primary, req->impersonation_level, sd, NULL, 0, NULL, 0 );
|
||||
if (token)
|
||||
{
|
||||
- reply->new_handle = alloc_handle_no_access_check( current->process, token, req->access, objattr->attributes );
|
||||
+ unsigned int access = req->access ? req->access : get_handle_access( current->process, req->handle );
|
||||
+ reply->new_handle = alloc_handle_no_access_check( current->process, token, access, objattr->attributes );
|
||||
release_object( token );
|
||||
}
|
||||
release_object( src_token );
|
||||
--
|
||||
2.13.1
|
||||
|
@@ -1,46 +0,0 @@
|
||||
From 48f4c131f9e8ffc091dde12437ad0772ed1c5ca6 Mon Sep 17 00:00:00 2001
|
||||
From: Sebastian Lackner <sebastian@fds-team.de>
|
||||
Date: Sun, 6 Aug 2017 15:16:33 +0200
|
||||
Subject: server: Use all group attributes in create_token.
|
||||
|
||||
---
|
||||
server/token.c | 14 +++++++-------
|
||||
1 file changed, 7 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/server/token.c b/server/token.c
|
||||
index 0019b3a..2a56664 100644
|
||||
--- a/server/token.c
|
||||
+++ b/server/token.c
|
||||
@@ -592,13 +592,13 @@ static struct token *create_token( unsigned primary, const SID *user,
|
||||
return NULL;
|
||||
}
|
||||
memcpy( &group->sid, groups[i].Sid, security_sid_len( groups[i].Sid ));
|
||||
- group->enabled = TRUE;
|
||||
- group->def = TRUE;
|
||||
- group->logon = (groups[i].Attributes & SE_GROUP_LOGON_ID) != 0;
|
||||
group->mandatory = (groups[i].Attributes & SE_GROUP_MANDATORY) != 0;
|
||||
- group->owner = (groups[i].Attributes & SE_GROUP_OWNER) != 0;
|
||||
- group->resource = FALSE;
|
||||
- group->deny_only = FALSE;
|
||||
+ group->def = (groups[i].Attributes & SE_GROUP_ENABLED_BY_DEFAULT) != 0;
|
||||
+ group->enabled = (groups[i].Attributes & SE_GROUP_ENABLED) != 0;
|
||||
+ group->owner = (groups[i].Attributes & SE_GROUP_OWNER) != 0;
|
||||
+ group->deny_only = (groups[i].Attributes & SE_GROUP_USE_FOR_DENY_ONLY) != 0;
|
||||
+ group->logon = (groups[i].Attributes & SE_GROUP_LOGON_ID) != 0;
|
||||
+ group->resource = (groups[i].Attributes & SE_GROUP_RESOURCE) != 0;
|
||||
list_add_tail( &token->groups, &group->entry );
|
||||
/* Use first owner capable group as owner and primary group */
|
||||
if (!token->primary_group && group->owner)
|
||||
@@ -1603,8 +1603,8 @@ DECL_HANDLER(get_token_groups)
|
||||
if (group->enabled) *attr_ptr |= SE_GROUP_ENABLED;
|
||||
if (group->owner) *attr_ptr |= SE_GROUP_OWNER;
|
||||
if (group->deny_only) *attr_ptr |= SE_GROUP_USE_FOR_DENY_ONLY;
|
||||
- if (group->resource) *attr_ptr |= SE_GROUP_RESOURCE;
|
||||
if (group->logon) *attr_ptr |= SE_GROUP_LOGON_ID;
|
||||
+ if (group->resource) *attr_ptr |= SE_GROUP_RESOURCE;
|
||||
|
||||
memcpy(sid_ptr, &group->sid, security_sid_len( &group->sid ));
|
||||
|
||||
--
|
||||
2.7.4
|
||||
|
@@ -1,219 +0,0 @@
|
||||
From c47977a8bbd739483589d1f01cfece435be1c100 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Sat, 5 Aug 2017 01:45:29 +0200
|
||||
Subject: [PATCH] ntdll: Add function to create new tokens for elevation
|
||||
purposes.
|
||||
|
||||
---
|
||||
dlls/ntdll/ntdll.spec | 3 ++
|
||||
dlls/ntdll/ntdll_misc.h | 3 ++
|
||||
dlls/ntdll/process.c | 18 +++++++++
|
||||
server/protocol.def | 8 ++++
|
||||
server/security.h | 1 +
|
||||
server/token.c | 84 +++++++++++++++++++++++++++++++++++++++++
|
||||
6 files changed, 117 insertions(+)
|
||||
|
||||
diff --git a/dlls/ntdll/ntdll.spec b/dlls/ntdll/ntdll.spec
|
||||
index 0997c310110..8e3786e1972 100644
|
||||
--- a/dlls/ntdll/ntdll.spec
|
||||
+++ b/dlls/ntdll/ntdll.spec
|
||||
@@ -1600,6 +1600,9 @@
|
||||
# Virtual memory
|
||||
@ cdecl __wine_locked_recvmsg(long ptr long)
|
||||
|
||||
+# Token
|
||||
+@ cdecl __wine_create_default_token(long)
|
||||
+
|
||||
# Version
|
||||
@ cdecl wine_get_version()
|
||||
@ cdecl wine_get_build_id()
|
||||
diff --git a/dlls/ntdll/ntdll_misc.h b/dlls/ntdll/ntdll_misc.h
|
||||
index 63ceac42e94..5a98501381b 100644
|
||||
--- a/dlls/ntdll/ntdll_misc.h
|
||||
+++ b/dlls/ntdll/ntdll_misc.h
|
||||
@@ -67,6 +67,9 @@ extern void init_user_process_params(void) DECLSPEC_HIDDEN;
|
||||
extern NTSTATUS restart_process( RTL_USER_PROCESS_PARAMETERS *params, NTSTATUS status ) DECLSPEC_HIDDEN;
|
||||
extern void CDECL DECLSPEC_NORETURN signal_start_thread( CONTEXT *ctx ) DECLSPEC_HIDDEN;
|
||||
|
||||
+/* token */
|
||||
+extern HANDLE CDECL __wine_create_default_token(BOOL admin);
|
||||
+
|
||||
/* server support */
|
||||
extern BOOL is_wow64 DECLSPEC_HIDDEN;
|
||||
|
||||
diff --git a/dlls/ntdll/process.c b/dlls/ntdll/process.c
|
||||
index 77ba5b371e2..3e91a1fa9c4 100644
|
||||
--- a/dlls/ntdll/process.c
|
||||
+++ b/dlls/ntdll/process.c
|
||||
@@ -72,6 +72,24 @@ HANDLE CDECL __wine_make_process_system(void)
|
||||
return ret;
|
||||
}
|
||||
|
||||
+/***********************************************************************
|
||||
+ * __wine_create_default_token (NTDLL.@)
|
||||
+ *
|
||||
+ * Creates a default limited or admin token.
|
||||
+ */
|
||||
+HANDLE CDECL __wine_create_default_token( BOOL admin )
|
||||
+{
|
||||
+ HANDLE ret = NULL;
|
||||
+ SERVER_START_REQ( create_token )
|
||||
+ {
|
||||
+ req->admin = admin;
|
||||
+ if (!wine_server_call( req ))
|
||||
+ ret = wine_server_ptr_handle( reply->token );
|
||||
+ }
|
||||
+ SERVER_END_REQ;
|
||||
+ return ret;
|
||||
+}
|
||||
+
|
||||
/***********************************************************************
|
||||
* restart_process
|
||||
*/
|
||||
diff --git a/server/protocol.def b/server/protocol.def
|
||||
index 30a102d7b82..a9308904afc 100644
|
||||
--- a/server/protocol.def
|
||||
+++ b/server/protocol.def
|
||||
@@ -3481,6 +3481,14 @@ struct handle_info
|
||||
@END
|
||||
|
||||
|
||||
+/* Create a new token */
|
||||
+@REQ(create_token)
|
||||
+ unsigned int admin; /* admin or limited token */
|
||||
+@REPLY
|
||||
+ obj_handle_t token; /* handle for new token */
|
||||
+@END
|
||||
+
|
||||
+
|
||||
/* Create I/O completion port */
|
||||
@REQ(create_completion)
|
||||
unsigned int access; /* desired access to a port */
|
||||
diff --git a/server/security.h b/server/security.h
|
||||
index 6c337143c3d..21e90ccf23f 100644
|
||||
--- a/server/security.h
|
||||
+++ b/server/security.h
|
||||
@@ -49,6 +49,7 @@ extern const PSID security_builtin_users_sid;
|
||||
extern const PSID security_builtin_admins_sid;
|
||||
extern const PSID security_domain_users_sid;
|
||||
extern const PSID security_high_label_sid;
|
||||
+extern const PSID security_medium_label_sid;
|
||||
|
||||
|
||||
/* token functions */
|
||||
diff --git a/server/token.c b/server/token.c
|
||||
index c4f1cd943c2..970ed1838da 100644
|
||||
--- a/server/token.c
|
||||
+++ b/server/token.c
|
||||
@@ -77,6 +77,7 @@ static const SID anonymous_logon_sid = { SID_REVISION, 1, { SECURITY_NT_AUTHORIT
|
||||
static const SID authenticated_user_sid = { SID_REVISION, 1, { SECURITY_NT_AUTHORITY }, { SECURITY_AUTHENTICATED_USER_RID } };
|
||||
static const SID local_system_sid = { SID_REVISION, 1, { SECURITY_NT_AUTHORITY }, { SECURITY_LOCAL_SYSTEM_RID } };
|
||||
static const SID high_label_sid = { SID_REVISION, 1, { SECURITY_MANDATORY_LABEL_AUTHORITY }, { SECURITY_MANDATORY_HIGH_RID } };
|
||||
+static const SID medium_label_sid = { SID_REVISION, 1, { SECURITY_MANDATORY_LABEL_AUTHORITY }, { SECURITY_MANDATORY_MEDIUM_RID } };
|
||||
static const SID_N(5) local_user_sid = { SID_REVISION, 5, { SECURITY_NT_AUTHORITY }, { SECURITY_NT_NON_UNIQUE, 0, 0, 0, 1000 } };
|
||||
static const SID_N(2) builtin_admins_sid = { SID_REVISION, 2, { SECURITY_NT_AUTHORITY }, { SECURITY_BUILTIN_DOMAIN_RID, DOMAIN_ALIAS_RID_ADMINS } };
|
||||
static const SID_N(2) builtin_users_sid = { SID_REVISION, 2, { SECURITY_NT_AUTHORITY }, { SECURITY_BUILTIN_DOMAIN_RID, DOMAIN_ALIAS_RID_USERS } };
|
||||
@@ -93,6 +94,7 @@ const PSID security_builtin_admins_sid = (PSID)&builtin_admins_sid;
|
||||
const PSID security_builtin_users_sid = (PSID)&builtin_users_sid;
|
||||
const PSID security_domain_users_sid = (PSID)&domain_users_sid;
|
||||
const PSID security_high_label_sid = (PSID)&high_label_sid;
|
||||
+const PSID security_medium_label_sid = (PSID)&medium_label_sid;
|
||||
|
||||
static luid_t prev_luid_value = { 1000, 0 };
|
||||
|
||||
@@ -915,6 +917,64 @@ struct token *token_create_admin( void )
|
||||
return token;
|
||||
}
|
||||
|
||||
+static struct token *token_create_limited( void )
|
||||
+{
|
||||
+ struct token *token = NULL;
|
||||
+ static const SID_IDENTIFIER_AUTHORITY nt_authority = { SECURITY_NT_AUTHORITY };
|
||||
+ static const unsigned int alias_admins_subauth[] = { SECURITY_BUILTIN_DOMAIN_RID, DOMAIN_ALIAS_RID_ADMINS };
|
||||
+ static const unsigned int alias_users_subauth[] = { SECURITY_BUILTIN_DOMAIN_RID, DOMAIN_ALIAS_RID_USERS };
|
||||
+ /* on Windows, this value changes every time the user logs on */
|
||||
+ static const unsigned int logon_subauth[] = { SECURITY_LOGON_IDS_RID, 0, 1 /* FIXME: should be randomly generated when tokens are inherited by new processes */ };
|
||||
+ PSID alias_admins_sid;
|
||||
+ PSID alias_users_sid;
|
||||
+ PSID logon_sid;
|
||||
+ const SID *user_sid = security_unix_uid_to_sid( getuid() );
|
||||
+ ACL *default_dacl = create_default_dacl( user_sid );
|
||||
+
|
||||
+ alias_admins_sid = security_sid_alloc( &nt_authority, sizeof(alias_admins_subauth)/sizeof(alias_admins_subauth[0]),
|
||||
+ alias_admins_subauth );
|
||||
+ alias_users_sid = security_sid_alloc( &nt_authority, sizeof(alias_users_subauth)/sizeof(alias_users_subauth[0]),
|
||||
+ alias_users_subauth );
|
||||
+ logon_sid = security_sid_alloc( &nt_authority, sizeof(logon_subauth)/sizeof(logon_subauth[0]),
|
||||
+ logon_subauth );
|
||||
+
|
||||
+ if (alias_admins_sid && alias_users_sid && logon_sid && default_dacl)
|
||||
+ {
|
||||
+ const LUID_AND_ATTRIBUTES user_privs[] =
|
||||
+ {
|
||||
+ { SeChangeNotifyPrivilege , SE_PRIVILEGE_ENABLED },
|
||||
+ { SeShutdownPrivilege , 0 },
|
||||
+ { SeUndockPrivilege , 0 },
|
||||
+ };
|
||||
+ /* note: we don't include non-builtin groups here for the user -
|
||||
+ * telling us these is the job of a client-side program */
|
||||
+ const SID_AND_ATTRIBUTES user_groups[] =
|
||||
+ {
|
||||
+ { security_world_sid, SE_GROUP_ENABLED|SE_GROUP_ENABLED_BY_DEFAULT|SE_GROUP_MANDATORY },
|
||||
+ { security_local_sid, SE_GROUP_ENABLED|SE_GROUP_ENABLED_BY_DEFAULT|SE_GROUP_MANDATORY },
|
||||
+ { security_interactive_sid, SE_GROUP_ENABLED|SE_GROUP_ENABLED_BY_DEFAULT|SE_GROUP_MANDATORY },
|
||||
+ { security_authenticated_user_sid, SE_GROUP_ENABLED|SE_GROUP_ENABLED_BY_DEFAULT|SE_GROUP_MANDATORY },
|
||||
+ { security_domain_users_sid, SE_GROUP_ENABLED|SE_GROUP_ENABLED_BY_DEFAULT|SE_GROUP_MANDATORY|SE_GROUP_OWNER },
|
||||
+ { alias_admins_sid, SE_GROUP_USE_FOR_DENY_ONLY },
|
||||
+ { alias_users_sid, SE_GROUP_ENABLED|SE_GROUP_ENABLED_BY_DEFAULT|SE_GROUP_MANDATORY },
|
||||
+ { logon_sid, SE_GROUP_ENABLED|SE_GROUP_ENABLED_BY_DEFAULT|SE_GROUP_MANDATORY|SE_GROUP_LOGON_ID },
|
||||
+ };
|
||||
+ static const TOKEN_SOURCE admin_source = {"SeMgr", {0, 0}};
|
||||
+ token = create_token( TRUE, user_sid, user_groups, sizeof(user_groups)/sizeof(user_groups[0]),
|
||||
+ user_privs, sizeof(user_privs)/sizeof(user_privs[0]), default_dacl,
|
||||
+ admin_source, NULL, -1, TokenElevationTypeLimited, &medium_label_sid );
|
||||
+ /* we really need a primary group */
|
||||
+ assert( token->primary_group );
|
||||
+ }
|
||||
+
|
||||
+ free( logon_sid );
|
||||
+ free( alias_admins_sid );
|
||||
+ free( alias_users_sid );
|
||||
+ free( default_dacl );
|
||||
+
|
||||
+ return token;
|
||||
+}
|
||||
+
|
||||
static struct privilege *token_find_privilege( struct token *token, const LUID *luid, int enabled_only )
|
||||
{
|
||||
struct privilege *privilege;
|
||||
@@ -1720,3 +1780,27 @@ DECL_HANDLER(set_token_default_dacl)
|
||||
release_object( token );
|
||||
}
|
||||
}
|
||||
+
|
||||
+DECL_HANDLER(create_token)
|
||||
+{
|
||||
+ struct token *token;
|
||||
+ PSID label;
|
||||
+
|
||||
+ if (req->admin)
|
||||
+ {
|
||||
+ token = token_create_admin();
|
||||
+ label = security_high_label_sid;
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ token = token_create_limited();
|
||||
+ label = security_medium_label_sid;
|
||||
+ }
|
||||
+
|
||||
+ if (token)
|
||||
+ {
|
||||
+ if (token_assign_label( token, label ))
|
||||
+ reply->token = alloc_handle( current->process, token, TOKEN_ALL_ACCESS, 0 );
|
||||
+ release_object( token );
|
||||
+ }
|
||||
+}
|
||||
--
|
||||
2.28.0
|
||||
|
@@ -1,66 +0,0 @@
|
||||
From cf24ca0854a5b0dca2055f0991fd9a932125c65e Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Sat, 5 Aug 2017 02:03:20 +0200
|
||||
Subject: shell32: Implement process elevation using runas verb.
|
||||
|
||||
---
|
||||
dlls/shell32/shlexec.c | 22 ++++++++++++++++++++--
|
||||
1 file changed, 20 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/dlls/shell32/shlexec.c b/dlls/shell32/shlexec.c
|
||||
index 0cf112b6373..af50078dbca 100644
|
||||
--- a/dlls/shell32/shlexec.c
|
||||
+++ b/dlls/shell32/shlexec.c
|
||||
@@ -50,6 +50,8 @@
|
||||
|
||||
WINE_DEFAULT_DEBUG_CHANNEL(exec);
|
||||
|
||||
+extern HANDLE CDECL __wine_create_default_token(BOOL admin);
|
||||
+
|
||||
static const WCHAR wszOpen[] = {'o','p','e','n',0};
|
||||
static const WCHAR wszExe[] = {'.','e','x','e',0};
|
||||
static const WCHAR wszILPtr[] = {':','%','p',0};
|
||||
@@ -312,6 +314,8 @@ static HRESULT SHELL_GetPathFromIDListForExecuteW(LPCITEMIDLIST pidl, LPWSTR psz
|
||||
static UINT_PTR SHELL_ExecuteW(const WCHAR *lpCmd, WCHAR *env, BOOL shWait,
|
||||
const SHELLEXECUTEINFOW *psei, LPSHELLEXECUTEINFOW psei_out)
|
||||
{
|
||||
+ static WCHAR runasW[] = {'r','u','n','a','s',0};
|
||||
+ HANDLE token = NULL;
|
||||
STARTUPINFOW startup;
|
||||
PROCESS_INFORMATION info;
|
||||
UINT_PTR retval = SE_ERR_NOASSOC;
|
||||
@@ -344,8 +348,20 @@ static UINT_PTR SHELL_ExecuteW(const WCHAR *lpCmd, WCHAR *env, BOOL shWait,
|
||||
dwCreationFlags = CREATE_UNICODE_ENVIRONMENT;
|
||||
if (!(psei->fMask & SEE_MASK_NO_CONSOLE))
|
||||
dwCreationFlags |= CREATE_NEW_CONSOLE;
|
||||
- if (CreateProcessW(NULL, (LPWSTR)lpCmd, NULL, NULL, FALSE, dwCreationFlags, env,
|
||||
- lpDirectory, &startup, &info))
|
||||
+
|
||||
+ /* Spawning a process with runas verb means that the process should be
|
||||
+ * executed with admin rights. This function ignores the manifest data,
|
||||
+ * and allows programs to elevate rights on-demand. On Windows a complex
|
||||
+ * RPC menchanism is used, using CreateProcessAsUser would fail because
|
||||
+ * it can only be used to drop rights. */
|
||||
+ if (psei->lpVerb && !strcmpiW(psei->lpVerb, runasW))
|
||||
+ {
|
||||
+ if (!(token = __wine_create_default_token(TRUE)))
|
||||
+ ERR("Failed to create admin token\n");
|
||||
+ }
|
||||
+
|
||||
+ if (CreateProcessAsUserW(token, NULL, (LPWSTR)lpCmd, NULL, NULL, FALSE,
|
||||
+ dwCreationFlags, env, lpDirectory, &startup, &info))
|
||||
{
|
||||
/* Give 30 seconds to the app to come up, if desired. Probably only needed
|
||||
when starting app immediately before making a DDE connection. */
|
||||
@@ -365,6 +381,8 @@ static UINT_PTR SHELL_ExecuteW(const WCHAR *lpCmd, WCHAR *env, BOOL shWait,
|
||||
retval = ERROR_BAD_FORMAT;
|
||||
}
|
||||
|
||||
+ if (token) CloseHandle(token);
|
||||
+
|
||||
TRACE("returning %lu\n", retval);
|
||||
|
||||
psei_out->hInstApp = (HINSTANCE)retval;
|
||||
--
|
||||
2.13.1
|
||||
|
@@ -1,67 +0,0 @@
|
||||
From e34d019222909281390f83149be755a4145024c4 Mon Sep 17 00:00:00 2001
|
||||
From: Sebastian Lackner <sebastian@fds-team.de>
|
||||
Date: Mon, 7 Aug 2017 15:28:33 +0200
|
||||
Subject: [PATCH] ntdll: Add semi-stub for TokenLinkedToken info class.
|
||||
|
||||
---
|
||||
dlls/ntdll/unix/security.c | 30 +++++++++++++++++++++++++++++-
|
||||
1 file changed, 29 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/dlls/ntdll/unix/security.c b/dlls/ntdll/unix/security.c
|
||||
index f0057116dee..2769e5f6a7b 100644
|
||||
--- a/dlls/ntdll/unix/security.c
|
||||
+++ b/dlls/ntdll/unix/security.c
|
||||
@@ -138,6 +138,7 @@ NTSTATUS WINAPI NtDuplicateToken( HANDLE token, ACCESS_MASK access, OBJECT_ATTRI
|
||||
return status;
|
||||
}
|
||||
|
||||
+extern HANDLE CDECL __wine_create_default_token(BOOL admin);
|
||||
|
||||
/***********************************************************************
|
||||
* NtQueryInformationToken (NTDLL.@)
|
||||
@@ -166,7 +167,7 @@ NTSTATUS WINAPI NtQueryInformationToken( HANDLE token, TOKEN_INFORMATION_CLASS c
|
||||
0, /* TokenAuditPolicy */
|
||||
0, /* TokenOrigin */
|
||||
sizeof(TOKEN_ELEVATION_TYPE), /* TokenElevationType */
|
||||
- 0, /* TokenLinkedToken */
|
||||
+ sizeof(TOKEN_LINKED_TOKEN), /* TokenLinkedToken */
|
||||
sizeof(TOKEN_ELEVATION), /* TokenElevation */
|
||||
0, /* TokenHasRestrictions */
|
||||
0, /* TokenAccessInformation */
|
||||
@@ -401,6 +402,33 @@ NTSTATUS WINAPI NtQueryInformationToken( HANDLE token, TOKEN_INFORMATION_CLASS c
|
||||
SERVER_END_REQ;
|
||||
break;
|
||||
|
||||
+ case TokenLinkedToken:
|
||||
+ SERVER_START_REQ( get_token_elevation_type )
|
||||
+ {
|
||||
+ TOKEN_LINKED_TOKEN *linked_token = info;
|
||||
+ req->handle = wine_server_obj_handle( token );
|
||||
+ status = wine_server_call( req );
|
||||
+ if (status == STATUS_SUCCESS)
|
||||
+ {
|
||||
+ HANDLE token;
|
||||
+ /* FIXME: On Wine we do not have real linked tokens yet. Typically, a
|
||||
+ * program running with admin privileges is linked to a limited token,
|
||||
+ * and vice versa. We just create a new token instead of storing links
|
||||
+ * on the wineserver side. Using TokenLinkedToken twice should return
|
||||
+ * back the original token. */
|
||||
+ if ((reply->elevation == TokenElevationTypeFull || reply->elevation == TokenElevationTypeLimited) &&
|
||||
+ (token = __wine_create_default_token( reply->elevation != TokenElevationTypeFull )))
|
||||
+ {
|
||||
+ status = NtDuplicateToken( token, 0, NULL, SecurityIdentification, TokenImpersonation, &linked_token->LinkedToken );
|
||||
+ NtClose( token );
|
||||
+ }
|
||||
+ else
|
||||
+ status = STATUS_NO_TOKEN;
|
||||
+ }
|
||||
+ }
|
||||
+ SERVER_END_REQ;
|
||||
+ break;
|
||||
+
|
||||
case TokenElevation:
|
||||
SERVER_START_REQ( get_token_elevation_type )
|
||||
{
|
||||
--
|
||||
2.27.0
|
||||
|
@@ -1,23 +1,23 @@
|
||||
From 19683a27eaaed9c23635e9b5fa768a6c120a2ace Mon Sep 17 00:00:00 2001
|
||||
From 9bdd47614e24f12a292c18bdc9d81e55744b6e5f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Sun, 17 Jan 2016 01:11:46 +0100
|
||||
Subject: [PATCH] iertutil: Add dll and add stub for ordinal 811.
|
||||
|
||||
---
|
||||
configure.ac | 1 +
|
||||
dlls/iertutil/Makefile.in | 4 +
|
||||
dlls/iertutil/iertutil.spec | 521 ++++++++++++++++++++++++++++++++++++++++++++
|
||||
dlls/iertutil/main.c | 48 ++++
|
||||
4 files changed, 574 insertions(+)
|
||||
dlls/iertutil/Makefile.in | 6 +
|
||||
dlls/iertutil/iertutil.spec | 521 ++++++++++++++++++++++++++++++++++++
|
||||
dlls/iertutil/main.c | 31 +++
|
||||
4 files changed, 559 insertions(+)
|
||||
create mode 100644 dlls/iertutil/Makefile.in
|
||||
create mode 100644 dlls/iertutil/iertutil.spec
|
||||
create mode 100644 dlls/iertutil/main.c
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 5c97c1c..d70dcea 100644
|
||||
index caff5d1fe52..91b95b8e7b1 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -3286,6 +3286,7 @@ WINE_CONFIG_MAKEFILE(dlls/icmp)
|
||||
@@ -3342,6 +3342,7 @@ WINE_CONFIG_MAKEFILE(dlls/icmp)
|
||||
WINE_CONFIG_MAKEFILE(dlls/ieframe)
|
||||
WINE_CONFIG_MAKEFILE(dlls/ieframe/tests)
|
||||
WINE_CONFIG_MAKEFILE(dlls/ieproxy)
|
||||
@@ -27,17 +27,19 @@ index 5c97c1c..d70dcea 100644
|
||||
WINE_CONFIG_MAKEFILE(dlls/imagehlp)
|
||||
diff --git a/dlls/iertutil/Makefile.in b/dlls/iertutil/Makefile.in
|
||||
new file mode 100644
|
||||
index 0000000..268026e
|
||||
index 00000000000..47f9d228812
|
||||
--- /dev/null
|
||||
+++ b/dlls/iertutil/Makefile.in
|
||||
@@ -0,0 +1,4 @@
|
||||
@@ -0,0 +1,6 @@
|
||||
+MODULE = iertutil.dll
|
||||
+
|
||||
+EXTRADLLFLAGS = -mno-cygwin -Wb,--prefer-native
|
||||
+
|
||||
+C_SRCS = \
|
||||
+ main.c
|
||||
diff --git a/dlls/iertutil/iertutil.spec b/dlls/iertutil/iertutil.spec
|
||||
new file mode 100644
|
||||
index 0000000..a13779b
|
||||
index 00000000000..a13779bebbd
|
||||
--- /dev/null
|
||||
+++ b/dlls/iertutil/iertutil.spec
|
||||
@@ -0,0 +1,521 @@
|
||||
@@ -564,10 +566,10 @@ index 0000000..a13779b
|
||||
+@ stub UriFromHostAndScheme
|
||||
diff --git a/dlls/iertutil/main.c b/dlls/iertutil/main.c
|
||||
new file mode 100644
|
||||
index 0000000..2b993a4
|
||||
index 00000000000..4e5e9f086b3
|
||||
--- /dev/null
|
||||
+++ b/dlls/iertutil/main.c
|
||||
@@ -0,0 +1,48 @@
|
||||
@@ -0,0 +1,31 @@
|
||||
+/*
|
||||
+ * Copyright 2016 Michael MĂĽller
|
||||
+ *
|
||||
@@ -586,7 +588,6 @@ index 0000000..2b993a4
|
||||
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
+ */
|
||||
+
|
||||
+#include "config.h"
|
||||
+#include <stdarg.h>
|
||||
+
|
||||
+#include "windef.h"
|
||||
@@ -595,27 +596,11 @@ index 0000000..2b993a4
|
||||
+
|
||||
+WINE_DEFAULT_DEBUG_CHANNEL(iertutil);
|
||||
+
|
||||
+BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, void *reserved)
|
||||
+{
|
||||
+ TRACE("(%p, %u, %p)\n", instance, reason, reserved);
|
||||
+
|
||||
+ switch (reason)
|
||||
+ {
|
||||
+ case DLL_WINE_PREATTACH:
|
||||
+ return FALSE; /* prefer native version */
|
||||
+ case DLL_PROCESS_ATTACH:
|
||||
+ DisableThreadLibraryCalls(instance);
|
||||
+ break;
|
||||
+ }
|
||||
+
|
||||
+ return TRUE;
|
||||
+}
|
||||
+
|
||||
+BOOL WINAPI IERTUTIL_811(void *unknown)
|
||||
+{
|
||||
+ FIXME("(%p): stub\n", unknown);
|
||||
+ return FALSE;
|
||||
+}
|
||||
--
|
||||
1.9.1
|
||||
2.20.1
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 21b4b65eadc9e39008ccadc48307fcfea05a24fb Mon Sep 17 00:00:00 2001
|
||||
From 0e65ed108eb8bab24668f9a58c5757a3ad36104f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Tue, 12 Apr 2016 01:02:34 +0200
|
||||
Subject: [PATCH] uiautomationcore: Add dll and stub some functions.
|
||||
@@ -9,7 +9,7 @@ Subject: [PATCH] uiautomationcore: Add dll and stub some functions.
|
||||
2 files changed, 48 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/dlls/uiautomationcore/Makefile.in b/dlls/uiautomationcore/Makefile.in
|
||||
index b6edec5f6a9..bf2204d5ab4 100644
|
||||
index 5c4acb232a4..412f1dbbe19 100644
|
||||
--- a/dlls/uiautomationcore/Makefile.in
|
||||
+++ b/dlls/uiautomationcore/Makefile.in
|
||||
@@ -1,5 +1,6 @@
|
||||
@@ -17,10 +17,10 @@ index b6edec5f6a9..bf2204d5ab4 100644
|
||||
IMPORTLIB = uiautomationcore
|
||||
+IMPORTS = uuid
|
||||
|
||||
EXTRADLLFLAGS = -mno-cygwin
|
||||
EXTRADLLFLAGS = -mno-cygwin -Wb,--prefer-native
|
||||
|
||||
diff --git a/dlls/uiautomationcore/uia_main.c b/dlls/uiautomationcore/uia_main.c
|
||||
index f0d8247724d..b9c24b4b963 100644
|
||||
index 42014af6035..61e165d83c0 100644
|
||||
--- a/dlls/uiautomationcore/uia_main.c
|
||||
+++ b/dlls/uiautomationcore/uia_main.c
|
||||
@@ -1,4 +1,5 @@
|
||||
@@ -29,7 +29,7 @@ index f0d8247724d..b9c24b4b963 100644
|
||||
* Copyright 2017 Jacek Caban for CodeWeavers
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
@@ -16,6 +17,7 @@
|
||||
@@ -16,18 +17,58 @@
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
@@ -37,9 +37,8 @@ index f0d8247724d..b9c24b4b963 100644
|
||||
#include "uiautomation.h"
|
||||
|
||||
#include "wine/debug.h"
|
||||
@@ -37,12 +39,51 @@ BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, void *lpv)
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
WINE_DEFAULT_DEBUG_CHANNEL(uiautomation);
|
||||
|
||||
+static HRESULT WINAPI dummy_QueryInterface(IUnknown *iface, REFIID iid, void **ppv)
|
||||
+{
|
||||
@@ -90,7 +89,7 @@ index f0d8247724d..b9c24b4b963 100644
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
@@ -51,8 +92,8 @@ BOOL WINAPI UiaClientsAreListening(void)
|
||||
@@ -36,8 +77,8 @@ BOOL WINAPI UiaClientsAreListening(void)
|
||||
*/
|
||||
HRESULT WINAPI UiaGetReservedMixedAttributeValue(IUnknown **value)
|
||||
{
|
||||
@@ -101,7 +100,7 @@ index f0d8247724d..b9c24b4b963 100644
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -61,8 +102,8 @@ HRESULT WINAPI UiaGetReservedMixedAttributeValue(IUnknown **value)
|
||||
@@ -46,8 +87,8 @@ HRESULT WINAPI UiaGetReservedMixedAttributeValue(IUnknown **value)
|
||||
*/
|
||||
HRESULT WINAPI UiaGetReservedNotSupportedValue(IUnknown **value)
|
||||
{
|
||||
@@ -112,7 +111,7 @@ index f0d8247724d..b9c24b4b963 100644
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -81,7 +122,7 @@ int WINAPI UiaLookupId(enum AutomationIdentifierType type, const GUID *guid)
|
||||
@@ -66,7 +107,7 @@ int WINAPI UiaLookupId(enum AutomationIdentifierType type, const GUID *guid)
|
||||
LRESULT WINAPI UiaReturnRawElementProvider(HWND hwnd, WPARAM wParam,
|
||||
LPARAM lParam, IRawElementProviderSimple *elprov)
|
||||
{
|
||||
@@ -122,5 +121,5 @@ index f0d8247724d..b9c24b4b963 100644
|
||||
}
|
||||
|
||||
--
|
||||
2.17.1
|
||||
2.20.1
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From eaab7eaeb7533445473bc19d947c34bdc360566e Mon Sep 17 00:00:00 2001
|
||||
From 3478a4e41c07a66e7e913c54bcf5ad52e16a8fee Mon Sep 17 00:00:00 2001
|
||||
From: Derek Lesho <dlesho@codeweavers.com>
|
||||
Date: Fri, 2 Oct 2020 11:29:24 -0500
|
||||
Subject: [PATCH] bcrypt: Allow multiple backends to coexist.
|
||||
@@ -8,13 +8,13 @@ Signed-off-by: Derek Lesho <dlesho@codeweavers.com>
|
||||
dlls/bcrypt/Makefile.in | 3 +-
|
||||
dlls/bcrypt/bcrypt_internal.h | 3 +
|
||||
dlls/bcrypt/gnutls.c | 32 ++++--
|
||||
dlls/bcrypt/macos.c | 18 +++-
|
||||
dlls/bcrypt/unixlib.c | 194 ++++++++++++++++++++++++++++++++++
|
||||
5 files changed, 235 insertions(+), 15 deletions(-)
|
||||
dlls/bcrypt/macos.c | 18 ++-
|
||||
dlls/bcrypt/unixlib.c | 211 ++++++++++++++++++++++++++++++++++
|
||||
5 files changed, 252 insertions(+), 15 deletions(-)
|
||||
create mode 100644 dlls/bcrypt/unixlib.c
|
||||
|
||||
diff --git a/dlls/bcrypt/Makefile.in b/dlls/bcrypt/Makefile.in
|
||||
index 24803fb2d7c..46a20d473dd 100644
|
||||
index 24803fb2d7cb..46a20d473dd7 100644
|
||||
--- a/dlls/bcrypt/Makefile.in
|
||||
+++ b/dlls/bcrypt/Makefile.in
|
||||
@@ -11,6 +11,7 @@ C_SRCS = \
|
||||
@@ -27,10 +27,10 @@ index 24803fb2d7c..46a20d473dd 100644
|
||||
|
||||
RC_SRCS = version.rc
|
||||
diff --git a/dlls/bcrypt/bcrypt_internal.h b/dlls/bcrypt/bcrypt_internal.h
|
||||
index e1777ed130b..86b1e3d28c3 100644
|
||||
index eb1361115093..3c7110d05f84 100644
|
||||
--- a/dlls/bcrypt/bcrypt_internal.h
|
||||
+++ b/dlls/bcrypt/bcrypt_internal.h
|
||||
@@ -217,4 +217,7 @@ struct key_funcs
|
||||
@@ -218,4 +218,7 @@ struct key_funcs
|
||||
NTSTATUS (CDECL *key_import_rsa)( struct key *, UCHAR *, ULONG );
|
||||
};
|
||||
|
||||
@@ -39,10 +39,10 @@ index e1777ed130b..86b1e3d28c3 100644
|
||||
+
|
||||
#endif /* __BCRYPT_INTERNAL_H */
|
||||
diff --git a/dlls/bcrypt/gnutls.c b/dlls/bcrypt/gnutls.c
|
||||
index 162ac9ea732..a7fd8428dec 100644
|
||||
index c065ac31fba3..9490ea8612a8 100644
|
||||
--- a/dlls/bcrypt/gnutls.c
|
||||
+++ b/dlls/bcrypt/gnutls.c
|
||||
@@ -358,9 +358,12 @@ fail:
|
||||
@@ -371,9 +371,12 @@ fail:
|
||||
|
||||
static void gnutls_uninitialize(void)
|
||||
{
|
||||
@@ -58,7 +58,7 @@ index 162ac9ea732..a7fd8428dec 100644
|
||||
}
|
||||
|
||||
struct buffer
|
||||
@@ -1906,19 +1909,28 @@ static const struct key_funcs key_funcs =
|
||||
@@ -1949,19 +1952,28 @@ static const struct key_funcs key_funcs =
|
||||
key_import_rsa
|
||||
};
|
||||
|
||||
@@ -95,10 +95,10 @@ index 162ac9ea732..a7fd8428dec 100644
|
||||
+}
|
||||
+#endif
|
||||
diff --git a/dlls/bcrypt/macos.c b/dlls/bcrypt/macos.c
|
||||
index 57edc3e262b..55dca5dde34 100644
|
||||
index 44906519cef0..2a88aec8362c 100644
|
||||
--- a/dlls/bcrypt/macos.c
|
||||
+++ b/dlls/bcrypt/macos.c
|
||||
@@ -294,11 +294,21 @@ static const struct key_funcs key_funcs =
|
||||
@@ -302,11 +302,21 @@ static const struct key_funcs key_funcs =
|
||||
key_import_rsa
|
||||
};
|
||||
|
||||
@@ -126,10 +126,10 @@ index 57edc3e262b..55dca5dde34 100644
|
||||
#endif
|
||||
diff --git a/dlls/bcrypt/unixlib.c b/dlls/bcrypt/unixlib.c
|
||||
new file mode 100644
|
||||
index 00000000000..a158ec1630a
|
||||
index 000000000000..9cbb25f5740c
|
||||
--- /dev/null
|
||||
+++ b/dlls/bcrypt/unixlib.c
|
||||
@@ -0,0 +1,194 @@
|
||||
@@ -0,0 +1,211 @@
|
||||
+#if 0
|
||||
+#pragma makedep unix
|
||||
+#endif
|
||||
@@ -261,6 +261,19 @@ index 00000000000..a158ec1630a
|
||||
+ FIXME( "not implemented\n" );
|
||||
+}
|
||||
+
|
||||
+static NTSTATUS CDECL key_asymmetric_decrypt( struct key *key, UCHAR *input, ULONG input_len,
|
||||
+ UCHAR *output, ULONG *output_len )
|
||||
+{
|
||||
+ FIXME( "not implemented\n" );
|
||||
+ return STATUS_NOT_IMPLEMENTED;
|
||||
+}
|
||||
+
|
||||
+static NTSTATUS CDECL key_import_rsa( struct key *key, UCHAR *input, ULONG input_len )
|
||||
+{
|
||||
+ FIXME( "not implemented\n" );
|
||||
+ return STATUS_NOT_IMPLEMENTED;
|
||||
+}
|
||||
+
|
||||
+static struct key_funcs key_funcs =
|
||||
+{
|
||||
+ key_set_property,
|
||||
@@ -273,6 +286,7 @@ index 00000000000..a158ec1630a
|
||||
+ key_symmetric_destroy,
|
||||
+ key_asymmetric_init,
|
||||
+ key_asymmetric_generate,
|
||||
+ key_asymmetric_decrypt,
|
||||
+ key_asymmetric_duplicate,
|
||||
+ key_asymmetric_sign,
|
||||
+ key_asymmetric_verify,
|
||||
@@ -280,7 +294,8 @@ index 00000000000..a158ec1630a
|
||||
+ key_export_dsa_capi,
|
||||
+ key_export_ecc,
|
||||
+ key_import_dsa_capi,
|
||||
+ key_import_ecc
|
||||
+ key_import_ecc,
|
||||
+ key_import_rsa,
|
||||
+};
|
||||
+
|
||||
+NTSTATUS CDECL __wine_init_unix_lib( HMODULE module, DWORD reason, const void *ptr_in, void *ptr_out )
|
||||
@@ -306,6 +321,7 @@ index 00000000000..a158ec1630a
|
||||
+ RESOLVE_FUNC(symmetric_destroy)
|
||||
+ RESOLVE_FUNC(asymmetric_init)
|
||||
+ RESOLVE_FUNC(asymmetric_generate)
|
||||
+ RESOLVE_FUNC(asymmetric_decrypt)
|
||||
+ RESOLVE_FUNC(asymmetric_duplicate)
|
||||
+ RESOLVE_FUNC(asymmetric_sign)
|
||||
+ RESOLVE_FUNC(asymmetric_verify)
|
||||
@@ -314,6 +330,7 @@ index 00000000000..a158ec1630a
|
||||
+ RESOLVE_FUNC(export_ecc)
|
||||
+ RESOLVE_FUNC(import_dsa_capi)
|
||||
+ RESOLVE_FUNC(import_ecc)
|
||||
+ RESOLVE_FUNC(import_rsa)
|
||||
+
|
||||
+#undef RESOLVE_FUNC
|
||||
+
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 6a38df1250c4bab1fab1a72e06fc347586a7c535 Mon Sep 17 00:00:00 2001
|
||||
From e2442f39015a5982bfd15479ee06d7163d36771d Mon Sep 17 00:00:00 2001
|
||||
From: Derek Lesho <dlesho@codeweavers.com>
|
||||
Date: Fri, 2 Oct 2020 12:11:49 -0500
|
||||
Subject: [PATCH] bcrypt: Implement BCryptSecretAgreement with libgcrypt.
|
||||
@@ -9,19 +9,19 @@ Signed-off-by: Derek Lesho <dlesho@codeweavers.com>
|
||||
dlls/bcrypt/Makefile.in | 1 +
|
||||
dlls/bcrypt/bcrypt_internal.h | 4 +
|
||||
dlls/bcrypt/bcrypt_main.c | 55 ++++++-
|
||||
dlls/bcrypt/gcrypt.c | 290 ++++++++++++++++++++++++++++++++++
|
||||
dlls/bcrypt/gcrypt.c | 292 ++++++++++++++++++++++++++++++++++
|
||||
dlls/bcrypt/gnutls.c | 3 +-
|
||||
dlls/bcrypt/macos.c | 3 +-
|
||||
dlls/bcrypt/tests/bcrypt.c | 2 +-
|
||||
dlls/bcrypt/unixlib.c | 15 +-
|
||||
9 files changed, 377 insertions(+), 10 deletions(-)
|
||||
dlls/bcrypt/unixlib.c | 13 +-
|
||||
9 files changed, 378 insertions(+), 9 deletions(-)
|
||||
create mode 100644 dlls/bcrypt/gcrypt.c
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 029dcd45187..a18e271dd4c 100644
|
||||
index b6b8d49342f3..7c1c8a7ddaf4 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -45,6 +45,7 @@ AC_ARG_WITH(faudio, AS_HELP_STRING([--without-faudio],[do not use FAudio (XAu
|
||||
@@ -46,6 +46,7 @@ AC_ARG_WITH(faudio, AS_HELP_STRING([--without-faudio],[do not use FAudio (XAu
|
||||
AC_ARG_WITH(float-abi, AS_HELP_STRING([--with-float-abi=abi],[specify the ABI (soft|softfp|hard) for ARM platforms]))
|
||||
AC_ARG_WITH(fontconfig,AS_HELP_STRING([--without-fontconfig],[do not use fontconfig]))
|
||||
AC_ARG_WITH(freetype, AS_HELP_STRING([--without-freetype],[do not use the FreeType library]))
|
||||
@@ -29,7 +29,7 @@ index 029dcd45187..a18e271dd4c 100644
|
||||
AC_ARG_WITH(gettext, AS_HELP_STRING([--without-gettext],[do not use gettext]))
|
||||
AC_ARG_WITH(gettextpo, AS_HELP_STRING([--with-gettextpo],[use the GetTextPO library to rebuild po files]),
|
||||
[if test "x$withval" = "xno"; then ac_cv_header_gettext_po_h=no; fi])
|
||||
@@ -1988,6 +1989,19 @@ WINE_NOTICE_WITH(vkd3d,[test "x$ac_cv_lib_soname_vkd3d" = "x"],
|
||||
@@ -1989,6 +1990,19 @@ WINE_NOTICE_WITH(vkd3d,[test "x$ac_cv_lib_soname_vkd3d" = "x"],
|
||||
[vkd3d ${notice_platform}development files not found (or too old), Direct3D 12 won't be supported.])
|
||||
test "x$ac_cv_lib_soname_vkd3d" != "x" || enable_d3d12=${enable_d3d12:-no}
|
||||
|
||||
@@ -50,7 +50,7 @@ index 029dcd45187..a18e271dd4c 100644
|
||||
|
||||
AC_SUBST(EXTRACFLAGS,"")
|
||||
diff --git a/dlls/bcrypt/Makefile.in b/dlls/bcrypt/Makefile.in
|
||||
index 46a20d473dd..4a3016784af 100644
|
||||
index 46a20d473dd7..4a3016784af3 100644
|
||||
--- a/dlls/bcrypt/Makefile.in
|
||||
+++ b/dlls/bcrypt/Makefile.in
|
||||
@@ -7,6 +7,7 @@ EXTRADLLFLAGS = -mno-cygwin
|
||||
@@ -62,7 +62,7 @@ index 46a20d473dd..4a3016784af 100644
|
||||
macos.c \
|
||||
md2.c \
|
||||
diff --git a/dlls/bcrypt/bcrypt_internal.h b/dlls/bcrypt/bcrypt_internal.h
|
||||
index 86b1e3d28c3..5d969b13dc3 100644
|
||||
index 3c7110d05f84..e7991eac077a 100644
|
||||
--- a/dlls/bcrypt/bcrypt_internal.h
|
||||
+++ b/dlls/bcrypt/bcrypt_internal.h
|
||||
@@ -192,6 +192,8 @@ struct key
|
||||
@@ -74,7 +74,7 @@ index 86b1e3d28c3..5d969b13dc3 100644
|
||||
};
|
||||
|
||||
struct key_funcs
|
||||
@@ -215,9 +217,11 @@ struct key_funcs
|
||||
@@ -216,9 +218,11 @@ struct key_funcs
|
||||
NTSTATUS (CDECL *key_import_dsa_capi)( struct key *, UCHAR *, ULONG );
|
||||
NTSTATUS (CDECL *key_import_ecc)( struct key *, UCHAR *, ULONG );
|
||||
NTSTATUS (CDECL *key_import_rsa)( struct key *, UCHAR *, ULONG );
|
||||
@@ -87,10 +87,10 @@ index 86b1e3d28c3..5d969b13dc3 100644
|
||||
|
||||
#endif /* __BCRYPT_INTERNAL_H */
|
||||
diff --git a/dlls/bcrypt/bcrypt_main.c b/dlls/bcrypt/bcrypt_main.c
|
||||
index 591c01c710c..f2c344f3275 100644
|
||||
index a1423dcd8368..0655c5dcfe81 100644
|
||||
--- a/dlls/bcrypt/bcrypt_main.c
|
||||
+++ b/dlls/bcrypt/bcrypt_main.c
|
||||
@@ -1914,9 +1914,12 @@ NTSTATUS WINAPI BCryptSecretAgreement(BCRYPT_KEY_HANDLE privatekey, BCRYPT_KEY_H
|
||||
@@ -1932,9 +1932,12 @@ NTSTATUS WINAPI BCryptSecretAgreement(BCRYPT_KEY_HANDLE privatekey, BCRYPT_KEY_H
|
||||
{
|
||||
struct key *privkey = privatekey;
|
||||
struct key *pubkey = publickey;
|
||||
@@ -104,7 +104,7 @@ index 591c01c710c..f2c344f3275 100644
|
||||
|
||||
if (!privkey || privkey->hdr.magic != MAGIC_KEY) return STATUS_INVALID_HANDLE;
|
||||
if (!pubkey || pubkey->hdr.magic != MAGIC_KEY) return STATUS_INVALID_HANDLE;
|
||||
@@ -1925,18 +1928,39 @@ NTSTATUS WINAPI BCryptSecretAgreement(BCRYPT_KEY_HANDLE privatekey, BCRYPT_KEY_H
|
||||
@@ -1943,18 +1946,39 @@ NTSTATUS WINAPI BCryptSecretAgreement(BCRYPT_KEY_HANDLE privatekey, BCRYPT_KEY_H
|
||||
if (!(secret = heap_alloc_zero( sizeof(*secret) ))) return STATUS_NO_MEMORY;
|
||||
secret->hdr.magic = MAGIC_SECRET;
|
||||
|
||||
@@ -146,7 +146,7 @@ index 591c01c710c..f2c344f3275 100644
|
||||
heap_free( secret );
|
||||
return STATUS_SUCCESS;
|
||||
}
|
||||
@@ -1946,12 +1970,33 @@ NTSTATUS WINAPI BCryptDeriveKey(BCRYPT_SECRET_HANDLE handle, LPCWSTR kdf, BCrypt
|
||||
@@ -1964,12 +1988,33 @@ NTSTATUS WINAPI BCryptDeriveKey(BCRYPT_SECRET_HANDLE handle, LPCWSTR kdf, BCrypt
|
||||
{
|
||||
struct secret *secret = handle;
|
||||
|
||||
@@ -184,10 +184,10 @@ index 591c01c710c..f2c344f3275 100644
|
||||
BOOL WINAPI DllMain( HINSTANCE hinst, DWORD reason, LPVOID reserved )
|
||||
diff --git a/dlls/bcrypt/gcrypt.c b/dlls/bcrypt/gcrypt.c
|
||||
new file mode 100644
|
||||
index 00000000000..00849358c68
|
||||
index 000000000000..e72c27feb519
|
||||
--- /dev/null
|
||||
+++ b/dlls/bcrypt/gcrypt.c
|
||||
@@ -0,0 +1,290 @@
|
||||
@@ -0,0 +1,292 @@
|
||||
+#if 0
|
||||
+#pragma makedep unix
|
||||
+#endif
|
||||
@@ -450,6 +450,8 @@ index 00000000000..00849358c68
|
||||
+ NULL,
|
||||
+ NULL,
|
||||
+ NULL,
|
||||
+ NULL,
|
||||
+ NULL,
|
||||
+ key_compute_secret_ecc
|
||||
+};
|
||||
+
|
||||
@@ -479,10 +481,10 @@ index 00000000000..00849358c68
|
||||
+}
|
||||
+#endif
|
||||
diff --git a/dlls/bcrypt/gnutls.c b/dlls/bcrypt/gnutls.c
|
||||
index a7fd8428dec..575aaa21309 100644
|
||||
index 9490ea8612a8..78d0f2d95966 100644
|
||||
--- a/dlls/bcrypt/gnutls.c
|
||||
+++ b/dlls/bcrypt/gnutls.c
|
||||
@@ -1906,7 +1906,8 @@ static const struct key_funcs key_funcs =
|
||||
@@ -1949,7 +1949,8 @@ static const struct key_funcs key_funcs =
|
||||
key_export_ecc,
|
||||
key_import_dsa_capi,
|
||||
key_import_ecc,
|
||||
@@ -493,10 +495,10 @@ index a7fd8428dec..575aaa21309 100644
|
||||
|
||||
struct key_funcs * gnutls_lib_init( DWORD reason )
|
||||
diff --git a/dlls/bcrypt/macos.c b/dlls/bcrypt/macos.c
|
||||
index 55dca5dde34..fd7aeae9ec2 100644
|
||||
index 2a88aec8362c..3ee3515f9de2 100644
|
||||
--- a/dlls/bcrypt/macos.c
|
||||
+++ b/dlls/bcrypt/macos.c
|
||||
@@ -291,7 +291,8 @@ static const struct key_funcs key_funcs =
|
||||
@@ -299,7 +299,8 @@ static const struct key_funcs key_funcs =
|
||||
key_export_ecc,
|
||||
key_import_dsa_capi,
|
||||
key_import_ecc,
|
||||
@@ -507,7 +509,7 @@ index 55dca5dde34..fd7aeae9ec2 100644
|
||||
|
||||
struct key_funcs * macos_lib_init( DWORD reason )
|
||||
diff --git a/dlls/bcrypt/tests/bcrypt.c b/dlls/bcrypt/tests/bcrypt.c
|
||||
index 456727d04a9..6be406dee21 100644
|
||||
index 456727d04a96..6be406dee21f 100644
|
||||
--- a/dlls/bcrypt/tests/bcrypt.c
|
||||
+++ b/dlls/bcrypt/tests/bcrypt.c
|
||||
@@ -2163,7 +2163,7 @@ static void test_ECDH(void)
|
||||
@@ -520,11 +522,11 @@ index 456727d04a9..6be406dee21 100644
|
||||
if (status != STATUS_SUCCESS)
|
||||
{
|
||||
diff --git a/dlls/bcrypt/unixlib.c b/dlls/bcrypt/unixlib.c
|
||||
index a158ec1630a..a01e2ad02ed 100644
|
||||
index 9cbb25f5740c..6f8ff7f97887 100644
|
||||
--- a/dlls/bcrypt/unixlib.c
|
||||
+++ b/dlls/bcrypt/unixlib.c
|
||||
@@ -129,6 +129,12 @@ static void CDECL key_asymmetric_destroy( struct key *key )
|
||||
FIXME( "not implemented\n" );
|
||||
@@ -142,6 +142,12 @@ static NTSTATUS CDECL key_import_rsa( struct key *key, UCHAR *input, ULONG input
|
||||
return STATUS_NOT_IMPLEMENTED;
|
||||
}
|
||||
|
||||
+static NTSTATUS CDECL key_compute_secret_ecc (unsigned char *privkey_in, struct key *pubkey_in, struct secret *secret)
|
||||
@@ -536,13 +538,11 @@ index a158ec1630a..a01e2ad02ed 100644
|
||||
static struct key_funcs key_funcs =
|
||||
{
|
||||
key_set_property,
|
||||
@@ -148,13 +154,15 @@ static struct key_funcs key_funcs =
|
||||
key_export_dsa_capi,
|
||||
key_export_ecc,
|
||||
@@ -164,12 +170,14 @@ static struct key_funcs key_funcs =
|
||||
key_import_dsa_capi,
|
||||
- key_import_ecc
|
||||
+ key_import_ecc,
|
||||
+ key_compute_secret_ecc
|
||||
key_import_ecc,
|
||||
key_import_rsa,
|
||||
+ key_compute_secret_ecc,
|
||||
};
|
||||
|
||||
NTSTATUS CDECL __wine_init_unix_lib( HMODULE module, DWORD reason, const void *ptr_in, void *ptr_out )
|
||||
@@ -553,7 +553,7 @@ index a158ec1630a..a01e2ad02ed 100644
|
||||
|
||||
if (reason == DLL_PROCESS_ATTACH)
|
||||
{
|
||||
@@ -162,7 +170,9 @@ NTSTATUS CDECL __wine_init_unix_lib( HMODULE module, DWORD reason, const void *p
|
||||
@@ -177,7 +185,9 @@ NTSTATUS CDECL __wine_init_unix_lib( HMODULE module, DWORD reason, const void *p
|
||||
if (macos_funcs && macos_funcs->key_##name) \
|
||||
key_funcs.key_##name = macos_funcs->key_##name; \
|
||||
if (gnutls_funcs && gnutls_funcs->key_##name) \
|
||||
@@ -564,10 +564,10 @@ index a158ec1630a..a01e2ad02ed 100644
|
||||
|
||||
RESOLVE_FUNC(set_property)
|
||||
RESOLVE_FUNC(symmetric_init)
|
||||
@@ -182,6 +192,7 @@ NTSTATUS CDECL __wine_init_unix_lib( HMODULE module, DWORD reason, const void *p
|
||||
RESOLVE_FUNC(export_ecc)
|
||||
@@ -199,6 +209,7 @@ NTSTATUS CDECL __wine_init_unix_lib( HMODULE module, DWORD reason, const void *p
|
||||
RESOLVE_FUNC(import_dsa_capi)
|
||||
RESOLVE_FUNC(import_ecc)
|
||||
RESOLVE_FUNC(import_rsa)
|
||||
+ RESOLVE_FUNC(compute_secret_ecc)
|
||||
|
||||
#undef RESOLVE_FUNC
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 01530fae68970b0c0af8811c5f6c5ea85c14372c Mon Sep 17 00:00:00 2001
|
||||
From 305131e59c071ca84e4447ab053b04bf4023fee8 Mon Sep 17 00:00:00 2001
|
||||
From: Derek Lesho <dlesho@codeweavers.com>
|
||||
Date: Tue, 7 Jan 2020 14:22:49 -0600
|
||||
Subject: [PATCH] bcrypt: Implement BCRYPT_KDF_HASH.
|
||||
@@ -11,10 +11,10 @@ Signed-off-by: Derek Lesho <dlesho at codeweavers.com>
|
||||
2 files changed, 108 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/dlls/bcrypt/bcrypt_main.c b/dlls/bcrypt/bcrypt_main.c
|
||||
index 8dae41a2e2e..67be417aa61 100644
|
||||
index 0655c5dcfe81..70e914bd41f1 100644
|
||||
--- a/dlls/bcrypt/bcrypt_main.c
|
||||
+++ b/dlls/bcrypt/bcrypt_main.c
|
||||
@@ -1837,7 +1837,113 @@ NTSTATUS WINAPI BCryptDeriveKey(BCRYPT_SECRET_HANDLE handle, LPCWSTR kdf, BCrypt
|
||||
@@ -1993,7 +1993,113 @@ NTSTATUS WINAPI BCryptDeriveKey(BCRYPT_SECRET_HANDLE handle, LPCWSTR kdf, BCrypt
|
||||
if (!secret || secret->hdr.magic != MAGIC_SECRET) return STATUS_INVALID_HANDLE;
|
||||
if (!kdf) return STATUS_INVALID_PARAMETER;
|
||||
|
||||
@@ -130,10 +130,10 @@ index 8dae41a2e2e..67be417aa61 100644
|
||||
ULONG n;
|
||||
ULONG secret_length = secret->len;
|
||||
diff --git a/dlls/bcrypt/tests/bcrypt.c b/dlls/bcrypt/tests/bcrypt.c
|
||||
index 5701a0a30ce..d4ffb3fe69c 100644
|
||||
index 6be406dee21f..b13432523d15 100644
|
||||
--- a/dlls/bcrypt/tests/bcrypt.c
|
||||
+++ b/dlls/bcrypt/tests/bcrypt.c
|
||||
@@ -2132,7 +2132,7 @@ static void test_ECDH(void)
|
||||
@@ -2180,7 +2180,7 @@ static void test_ECDH(void)
|
||||
raw_secret_end:
|
||||
|
||||
status = pBCryptDeriveKey(secret, BCRYPT_KDF_HASH, &hash_params, NULL, 0, &size, 0);
|
||||
@@ -142,7 +142,7 @@ index 5701a0a30ce..d4ffb3fe69c 100644
|
||||
|
||||
if (status != STATUS_SUCCESS)
|
||||
{
|
||||
@@ -2666,7 +2666,6 @@ static void test_SecretAgreement(void)
|
||||
@@ -2716,7 +2716,6 @@ static void test_SecretAgreement(void)
|
||||
ok(status == STATUS_INVALID_PARAMETER, "got %08x\n", status);
|
||||
|
||||
status = pBCryptDeriveKey(secret, L"HASH", NULL, NULL, 0, &size, 0);
|
||||
@@ -151,5 +151,5 @@ index 5701a0a30ce..d4ffb3fe69c 100644
|
||||
|
||||
status = pBCryptDestroyHash(secret);
|
||||
--
|
||||
2.28.0
|
||||
2.29.2
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 39c92b48498d080c4d90e9b8d16c580dd72b1941 Mon Sep 17 00:00:00 2001
|
||||
From 50bd67fb1fd718eaaf9f5600fba7ab86e4b71a76 Mon Sep 17 00:00:00 2001
|
||||
From: Dmitry Timoshkov <dmitry@baikal.ru>
|
||||
Date: Fri, 5 Jul 2019 13:20:23 +0800
|
||||
Subject: [PATCH] cryptext: Implement CryptExtOpenCER.
|
||||
@@ -17,31 +17,31 @@ Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
|
||||
create mode 100644 dlls/cryptext/tests/cryptext.c
|
||||
|
||||
diff --git a/configure b/configure
|
||||
index f1de2c4052..ed79a35e0e 100755
|
||||
index 2b20133cd65..f3ef3aef3a9 100755
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -20063,6 +20063,7 @@ wine_fn_config_makefile dlls/crypt32/tests enable_tests
|
||||
@@ -20350,6 +20350,7 @@ wine_fn_config_makefile dlls/crypt32/tests enable_tests
|
||||
wine_fn_config_makefile dlls/cryptdlg enable_cryptdlg
|
||||
wine_fn_config_makefile dlls/cryptdll enable_cryptdll
|
||||
wine_fn_config_makefile dlls/cryptext enable_cryptext
|
||||
+wine_fn_config_makefile dlls/cryptext/tests enable_tests
|
||||
wine_fn_config_makefile dlls/cryptnet enable_cryptnet
|
||||
wine_fn_config_makefile dlls/cryptnet/tests enable_tests
|
||||
wine_fn_config_makefile dlls/cryptui enable_cryptui
|
||||
wine_fn_config_makefile dlls/cryptsp enable_cryptsp
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index a7c45ace73..e801c35c46 100644
|
||||
index 24f5c8847d6..f71fb6f401d 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -3049,6 +3049,7 @@ WINE_CONFIG_MAKEFILE(dlls/crypt32/tests)
|
||||
@@ -3083,6 +3083,7 @@ WINE_CONFIG_MAKEFILE(dlls/crypt32/tests)
|
||||
WINE_CONFIG_MAKEFILE(dlls/cryptdlg)
|
||||
WINE_CONFIG_MAKEFILE(dlls/cryptdll)
|
||||
WINE_CONFIG_MAKEFILE(dlls/cryptext)
|
||||
+WINE_CONFIG_MAKEFILE(dlls/cryptext/tests)
|
||||
WINE_CONFIG_MAKEFILE(dlls/cryptnet)
|
||||
WINE_CONFIG_MAKEFILE(dlls/cryptnet/tests)
|
||||
WINE_CONFIG_MAKEFILE(dlls/cryptui)
|
||||
WINE_CONFIG_MAKEFILE(dlls/cryptsp)
|
||||
diff --git a/dlls/cryptext/Makefile.in b/dlls/cryptext/Makefile.in
|
||||
index 9c9f84cee8..0e817ffda6 100644
|
||||
index 3acce60ae88..590074a806f 100644
|
||||
--- a/dlls/cryptext/Makefile.in
|
||||
+++ b/dlls/cryptext/Makefile.in
|
||||
@@ -1,4 +1,5 @@
|
||||
@@ -49,10 +49,10 @@ index 9c9f84cee8..0e817ffda6 100644
|
||||
+MODULE = cryptext.dll
|
||||
+IMPORTS = crypt32 cryptui user32
|
||||
|
||||
EXTRADLLFLAGS = -mno-cygwin
|
||||
EXTRADLLFLAGS = -mno-cygwin -Wb,--prefer-native
|
||||
|
||||
diff --git a/dlls/cryptext/cryptext.spec b/dlls/cryptext/cryptext.spec
|
||||
index 0dba38e393..911ab2f4ba 100644
|
||||
index 0dba38e3934..911ab2f4ba4 100644
|
||||
--- a/dlls/cryptext/cryptext.spec
|
||||
+++ b/dlls/cryptext/cryptext.spec
|
||||
@@ -12,8 +12,8 @@
|
||||
@@ -67,7 +67,7 @@ index 0dba38e393..911ab2f4ba 100644
|
||||
@ stub CryptExtOpenCRLW
|
||||
@ stub CryptExtOpenCTL
|
||||
diff --git a/dlls/cryptext/cryptext_main.c b/dlls/cryptext/cryptext_main.c
|
||||
index f7c7bd1f55..2a381782d6 100644
|
||||
index 537ba66cd3b..f9e34d1f8c5 100644
|
||||
--- a/dlls/cryptext/cryptext_main.c
|
||||
+++ b/dlls/cryptext/cryptext_main.c
|
||||
@@ -22,10 +22,29 @@
|
||||
@@ -97,10 +97,10 @@ index f7c7bd1f55..2a381782d6 100644
|
||||
+ return ret;
|
||||
+}
|
||||
+
|
||||
BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, LPVOID reserved)
|
||||
{
|
||||
TRACE("(%p, %u, %p)\n", instance, reason, reserved);
|
||||
@@ -59,3 +78,48 @@ HRESULT WINAPI CryptExtAddPFXW(LPCWSTR filename)
|
||||
/***********************************************************************
|
||||
* CryptExtAddPFX (CRYPTEXT.@)
|
||||
*/
|
||||
@@ -43,3 +62,48 @@ HRESULT WINAPI CryptExtAddPFXW(LPCWSTR filename)
|
||||
FIXME("stub: %s\n", debugstr_w(filename));
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
@@ -151,7 +151,7 @@ index f7c7bd1f55..2a381782d6 100644
|
||||
+}
|
||||
diff --git a/dlls/cryptext/tests/Makefile.in b/dlls/cryptext/tests/Makefile.in
|
||||
new file mode 100644
|
||||
index 0000000000..522fc60a4a
|
||||
index 00000000000..522fc60a4af
|
||||
--- /dev/null
|
||||
+++ b/dlls/cryptext/tests/Makefile.in
|
||||
@@ -0,0 +1,4 @@
|
||||
@@ -161,7 +161,7 @@ index 0000000000..522fc60a4a
|
||||
+ cryptext.c
|
||||
diff --git a/dlls/cryptext/tests/cryptext.c b/dlls/cryptext/tests/cryptext.c
|
||||
new file mode 100644
|
||||
index 0000000000..cc62a772b5
|
||||
index 00000000000..cc62a772b59
|
||||
--- /dev/null
|
||||
+++ b/dlls/cryptext/tests/cryptext.c
|
||||
@@ -0,0 +1,61 @@
|
||||
@@ -227,5 +227,5 @@ index 0000000000..cc62a772b5
|
||||
+ test_CryptExtOpenCER();
|
||||
+}
|
||||
--
|
||||
2.17.1
|
||||
2.20.1
|
||||
|
||||
|
@@ -1,20 +1,20 @@
|
||||
From 896b9be78dfd979ddea8f098ae66473956d4147c Mon Sep 17 00:00:00 2001
|
||||
From db0d249ec00a19f9ffbe26ee966eb222921fb36e Mon Sep 17 00:00:00 2001
|
||||
From: Kimmo Myllyvirta <kimmo.myllyvirta@gmail.com>
|
||||
Date: Sat, 24 Sep 2016 06:51:24 +0300
|
||||
Subject: [PATCH] d3d11: Add stub deferred rendering context.
|
||||
|
||||
---
|
||||
dlls/d3d11/device.c | 1268 +++++++++++++++++++++++++++++++++-----
|
||||
dlls/d3d11/device.c | 1270 +++++++++++++++++++++++++++++++++-----
|
||||
dlls/d3d11/tests/d3d11.c | 4 +-
|
||||
2 files changed, 1132 insertions(+), 140 deletions(-)
|
||||
2 files changed, 1133 insertions(+), 141 deletions(-)
|
||||
|
||||
diff --git a/dlls/d3d11/device.c b/dlls/d3d11/device.c
|
||||
index 31c7f35fc25..dca5a88caa0 100644
|
||||
index 066bf9880c4..454003128dc 100644
|
||||
--- a/dlls/d3d11/device.c
|
||||
+++ b/dlls/d3d11/device.c
|
||||
@@ -22,6 +22,16 @@
|
||||
|
||||
WINE_DEFAULT_DEBUG_CHANNEL(d3d11);
|
||||
@@ -48,6 +48,16 @@ static BOOL d3d_array_reserve(void **elements, SIZE_T *capacity, SIZE_T count, S
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
+/* ID3D11DeviceContext - deferred context */
|
||||
+struct d3d11_deferred_context
|
||||
@@ -29,7 +29,7 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
static void STDMETHODCALLTYPE d3d_null_wined3d_object_destroyed(void *parent) {}
|
||||
|
||||
static const struct wined3d_parent_ops d3d_null_wined3d_parent_ops =
|
||||
@@ -2883,218 +2893,1186 @@ static void d3d11_immediate_context_destroy(struct d3d11_immediate_context *cont
|
||||
@@ -3114,218 +3124,1186 @@ static void d3d11_immediate_context_destroy(struct d3d11_immediate_context *cont
|
||||
wined3d_private_store_cleanup(&context->private_store);
|
||||
}
|
||||
|
||||
@@ -130,11 +130,11 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
- HRESULT hr;
|
||||
-
|
||||
- TRACE("iface %p, desc %p, data %p, texture %p.\n", iface, desc, data, texture);
|
||||
+ struct d3d11_deferred_context *context = impl_from_deferred_ID3D11DeviceContext(iface);
|
||||
|
||||
-
|
||||
- if (FAILED(hr = d3d_texture2d_create(device, desc, data, &object)))
|
||||
- return hr;
|
||||
-
|
||||
+ struct d3d11_deferred_context *context = impl_from_deferred_ID3D11DeviceContext(iface);
|
||||
|
||||
- *texture = &object->ID3D11Texture2D_iface;
|
||||
+ TRACE("iface %p, device %p.\n", iface, device);
|
||||
|
||||
@@ -151,13 +151,13 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
- struct d3d_device *device = impl_from_ID3D11Device2(iface);
|
||||
- struct d3d_texture3d *object;
|
||||
- HRESULT hr;
|
||||
+ struct d3d11_deferred_context *context = impl_from_deferred_ID3D11DeviceContext(iface);
|
||||
|
||||
-
|
||||
- TRACE("iface %p, desc %p, data %p, texture %p.\n", iface, desc, data, texture);
|
||||
-
|
||||
- if (FAILED(hr = d3d_texture3d_create(device, desc, data, &object)))
|
||||
- return hr;
|
||||
-
|
||||
+ struct d3d11_deferred_context *context = impl_from_deferred_ID3D11DeviceContext(iface);
|
||||
|
||||
- *texture = &object->ID3D11Texture3D_iface;
|
||||
+ TRACE("iface %p, guid %s, data_size %p, data %p.\n", iface, debugstr_guid(guid), data_size, data);
|
||||
|
||||
@@ -205,11 +205,14 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
- struct d3d_device *device = impl_from_ID3D11Device2(iface);
|
||||
- struct d3d11_unordered_access_view *object;
|
||||
- HRESULT hr;
|
||||
-
|
||||
- TRACE("iface %p, resource %p, desc %p, view %p.\n", iface, resource, desc, view);
|
||||
+ FIXME("iface %p, start_slot %u, buffer_count %u, buffers %p stub!\n",
|
||||
+ iface, start_slot, buffer_count, buffers);
|
||||
+}
|
||||
|
||||
- TRACE("iface %p, resource %p, desc %p, view %p.\n", iface, resource, desc, view);
|
||||
- if (FAILED(hr = d3d11_unordered_access_view_create(device, resource, desc, &object)))
|
||||
- return hr;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_PSSetShaderResources(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT view_count, ID3D11ShaderResourceView *const *views)
|
||||
+{
|
||||
@@ -217,8 +220,7 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
+ iface, start_slot, view_count, views);
|
||||
+}
|
||||
|
||||
- if (FAILED(hr = d3d11_unordered_access_view_create(device, resource, desc, &object)))
|
||||
- return hr;
|
||||
- *view = &object->ID3D11UnorderedAccessView_iface;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_PSSetShader(ID3D11DeviceContext *iface,
|
||||
+ ID3D11PixelShader *shader, ID3D11ClassInstance *const *class_instances, UINT class_instance_count)
|
||||
+{
|
||||
@@ -226,35 +228,36 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
+ iface, shader, class_instances, class_instance_count);
|
||||
+}
|
||||
|
||||
- *view = &object->ID3D11UnorderedAccessView_iface;
|
||||
- return S_OK;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_PSSetSamplers(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT sampler_count, ID3D11SamplerState *const *samplers)
|
||||
+{
|
||||
+ FIXME("iface %p, start_slot %u, sampler_count %u, samplers %p stub!\n",
|
||||
+ iface, start_slot, sampler_count, samplers);
|
||||
+}
|
||||
|
||||
- return S_OK;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_VSSetShader(ID3D11DeviceContext *iface,
|
||||
+ ID3D11VertexShader *shader, ID3D11ClassInstance *const *class_instances, UINT class_instance_count)
|
||||
+{
|
||||
+ FIXME("iface %p, shader %p, class_instances %p, class_instance_count %u stub!\n",
|
||||
+ iface, shader, class_instances, class_instance_count);
|
||||
}
|
||||
|
||||
-static HRESULT STDMETHODCALLTYPE d3d11_device_CreateRenderTargetView(ID3D11Device2 *iface,
|
||||
- ID3D11Resource *resource, const D3D11_RENDER_TARGET_VIEW_DESC *desc, ID3D11RenderTargetView **view)
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_DrawIndexed(ID3D11DeviceContext *iface,
|
||||
+ UINT index_count, UINT start_index_location, INT base_vertex_location)
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_VSSetShader(ID3D11DeviceContext *iface,
|
||||
+ ID3D11VertexShader *shader, ID3D11ClassInstance *const *class_instances, UINT class_instance_count)
|
||||
{
|
||||
- struct d3d_device *device = impl_from_ID3D11Device2(iface);
|
||||
- struct d3d_rendertarget_view *object;
|
||||
- HRESULT hr;
|
||||
+ FIXME("iface %p, shader %p, class_instances %p, class_instance_count %u stub!\n",
|
||||
+ iface, shader, class_instances, class_instance_count);
|
||||
+}
|
||||
|
||||
- TRACE("iface %p, resource %p, desc %p, view %p.\n", iface, resource, desc, view);
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_DrawIndexed(ID3D11DeviceContext *iface,
|
||||
+ UINT index_count, UINT start_index_location, INT base_vertex_location)
|
||||
+{
|
||||
+ FIXME("iface %p, index_count %u, start_index_location %u, base_vertex_location %d stub!\n",
|
||||
+ iface, index_count, start_index_location, base_vertex_location);
|
||||
+}
|
||||
|
||||
- TRACE("iface %p, resource %p, desc %p, view %p.\n", iface, resource, desc, view);
|
||||
- if (!resource)
|
||||
- return E_INVALIDARG;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_Draw(ID3D11DeviceContext *iface,
|
||||
+ UINT vertex_count, UINT start_vertex_location)
|
||||
+{
|
||||
@@ -262,46 +265,46 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
+ iface, vertex_count, start_vertex_location);
|
||||
+}
|
||||
|
||||
- if (!resource)
|
||||
- return E_INVALIDARG;
|
||||
- if (FAILED(hr = d3d_rendertarget_view_create(device, resource, desc, &object)))
|
||||
- return hr;
|
||||
+static HRESULT STDMETHODCALLTYPE d3d11_deferred_context_Map(ID3D11DeviceContext *iface, ID3D11Resource *resource,
|
||||
+ UINT subresource_idx, D3D11_MAP map_type, UINT map_flags, D3D11_MAPPED_SUBRESOURCE *mapped_subresource)
|
||||
+{
|
||||
+ FIXME("iface %p, resource %p, subresource_idx %u, map_type %u, map_flags %#x, mapped_subresource %p stub!\n",
|
||||
+ iface, resource, subresource_idx, map_type, map_flags, mapped_subresource);
|
||||
|
||||
- if (FAILED(hr = d3d_rendertarget_view_create(device, resource, desc, &object)))
|
||||
- return hr;
|
||||
- *view = &object->ID3D11RenderTargetView_iface;
|
||||
+ return E_NOTIMPL;
|
||||
+}
|
||||
|
||||
- *view = &object->ID3D11RenderTargetView_iface;
|
||||
- return S_OK;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_Unmap(ID3D11DeviceContext *iface, ID3D11Resource *resource,
|
||||
+ UINT subresource_idx)
|
||||
+{
|
||||
+ FIXME("iface %p, resource %p, subresource_idx %u stub!\n", iface, resource, subresource_idx);
|
||||
+}
|
||||
|
||||
- return S_OK;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_PSSetConstantBuffers(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT buffer_count, ID3D11Buffer *const *buffers)
|
||||
+{
|
||||
+ FIXME("iface %p, start_slot %u, buffer_count %u, buffers %p stub!\n",
|
||||
+ iface, start_slot, buffer_count, buffers);
|
||||
}
|
||||
|
||||
-static HRESULT STDMETHODCALLTYPE d3d11_device_CreateDepthStencilView(ID3D11Device2 *iface,
|
||||
- ID3D11Resource *resource, const D3D11_DEPTH_STENCIL_VIEW_DESC *desc, ID3D11DepthStencilView **view)
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_IASetInputLayout(ID3D11DeviceContext *iface,
|
||||
+ ID3D11InputLayout *input_layout)
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_PSSetConstantBuffers(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT buffer_count, ID3D11Buffer *const *buffers)
|
||||
{
|
||||
- struct d3d_device *device = impl_from_ID3D11Device2(iface);
|
||||
- struct d3d_depthstencil_view *object;
|
||||
- HRESULT hr;
|
||||
+ FIXME("iface %p, input_layout %p stub!\n", iface, input_layout);
|
||||
+ FIXME("iface %p, start_slot %u, buffer_count %u, buffers %p stub!\n",
|
||||
+ iface, start_slot, buffer_count, buffers);
|
||||
+}
|
||||
|
||||
- TRACE("iface %p, resource %p, desc %p, view %p.\n", iface, resource, desc, view);
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_IASetInputLayout(ID3D11DeviceContext *iface,
|
||||
+ ID3D11InputLayout *input_layout)
|
||||
+{
|
||||
+ FIXME("iface %p, input_layout %p stub!\n", iface, input_layout);
|
||||
+}
|
||||
|
||||
- if (FAILED(hr = d3d_depthstencil_view_create(device, resource, desc, &object)))
|
||||
- return hr;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_IASetVertexBuffers(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT buffer_count, ID3D11Buffer *const *buffers, const UINT *strides, const UINT *offsets)
|
||||
+{
|
||||
@@ -309,8 +312,7 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
+ iface, start_slot, buffer_count, buffers, strides, offsets);
|
||||
+}
|
||||
|
||||
- if (FAILED(hr = d3d_depthstencil_view_create(device, resource, desc, &object)))
|
||||
- return hr;
|
||||
- *view = &object->ID3D11DepthStencilView_iface;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_IASetIndexBuffer(ID3D11DeviceContext *iface,
|
||||
+ ID3D11Buffer *buffer, DXGI_FORMAT format, UINT offset)
|
||||
+{
|
||||
@@ -318,7 +320,7 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
+ iface, buffer, debug_dxgi_format(format), offset);
|
||||
+}
|
||||
|
||||
- *view = &object->ID3D11DepthStencilView_iface;
|
||||
- return S_OK;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_DrawIndexedInstanced(ID3D11DeviceContext *iface,
|
||||
+ UINT instance_index_count, UINT instance_count, UINT start_index_location, INT base_vertex_location,
|
||||
+ UINT start_instance_location)
|
||||
@@ -327,34 +329,36 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
+ "base_vertex_location %d, start_instance_location %u stub!\n",
|
||||
+ iface, instance_index_count, instance_count, start_index_location,
|
||||
+ base_vertex_location, start_instance_location);
|
||||
+}
|
||||
|
||||
- return S_OK;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_DrawInstanced(ID3D11DeviceContext *iface,
|
||||
+ UINT instance_vertex_count, UINT instance_count, UINT start_vertex_location, UINT start_instance_location)
|
||||
+{
|
||||
+ FIXME("iface %p, instance_vertex_count %u, instance_count %u, start_vertex_location %u, "
|
||||
+ "start_instance_location %u stub!\n",
|
||||
+ iface, instance_vertex_count, instance_count, start_vertex_location,
|
||||
+ start_instance_location);
|
||||
}
|
||||
|
||||
-static HRESULT STDMETHODCALLTYPE d3d11_device_CreateInputLayout(ID3D11Device2 *iface,
|
||||
- const D3D11_INPUT_ELEMENT_DESC *element_descs, UINT element_count, const void *shader_byte_code,
|
||||
- SIZE_T shader_byte_code_length, ID3D11InputLayout **input_layout)
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_GSSetConstantBuffers(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT buffer_count, ID3D11Buffer *const *buffers)
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_DrawInstanced(ID3D11DeviceContext *iface,
|
||||
+ UINT instance_vertex_count, UINT instance_count, UINT start_vertex_location, UINT start_instance_location)
|
||||
{
|
||||
- struct d3d_device *device = impl_from_ID3D11Device2(iface);
|
||||
- struct d3d_input_layout *object;
|
||||
- HRESULT hr;
|
||||
+ FIXME("iface %p, start_slot %u, buffer_count %u, buffers %p stub!\n",
|
||||
+ iface, start_slot, buffer_count, buffers);
|
||||
+ FIXME("iface %p, instance_vertex_count %u, instance_count %u, start_vertex_location %u, "
|
||||
+ "start_instance_location %u stub!\n",
|
||||
+ iface, instance_vertex_count, instance_count, start_vertex_location,
|
||||
+ start_instance_location);
|
||||
+}
|
||||
|
||||
- TRACE("iface %p, element_descs %p, element_count %u, shader_byte_code %p, shader_byte_code_length %lu, "
|
||||
- "input_layout %p.\n", iface, element_descs, element_count, shader_byte_code,
|
||||
- shader_byte_code_length, input_layout);
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_GSSetConstantBuffers(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT buffer_count, ID3D11Buffer *const *buffers)
|
||||
+{
|
||||
+ FIXME("iface %p, start_slot %u, buffer_count %u, buffers %p stub!\n",
|
||||
+ iface, start_slot, buffer_count, buffers);
|
||||
+}
|
||||
|
||||
- if (FAILED(hr = d3d_input_layout_create(device, element_descs, element_count,
|
||||
- shader_byte_code, shader_byte_code_length, &object)))
|
||||
- return hr;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_GSSetShader(ID3D11DeviceContext *iface,
|
||||
+ ID3D11GeometryShader *shader, ID3D11ClassInstance *const *class_instances, UINT class_instance_count)
|
||||
+{
|
||||
@@ -362,44 +366,35 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
+ iface, shader, class_instances, class_instance_count);
|
||||
+}
|
||||
|
||||
- if (FAILED(hr = d3d_input_layout_create(device, element_descs, element_count,
|
||||
- shader_byte_code, shader_byte_code_length, &object)))
|
||||
- return hr;
|
||||
- *input_layout = &object->ID3D11InputLayout_iface;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_IASetPrimitiveTopology(ID3D11DeviceContext *iface,
|
||||
+ D3D11_PRIMITIVE_TOPOLOGY topology)
|
||||
+{
|
||||
+ FIXME("iface %p, topology %u stub!\n", iface, topology);
|
||||
+}
|
||||
|
||||
- *input_layout = &object->ID3D11InputLayout_iface;
|
||||
- return S_OK;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_VSSetShaderResources(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT view_count, ID3D11ShaderResourceView *const *views)
|
||||
+{
|
||||
+ FIXME("iface %p, start_slot %u, view_count %u, views %p stub!\n", iface, start_slot, view_count, views);
|
||||
+}
|
||||
|
||||
- return S_OK;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_VSSetSamplers(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT sampler_count, ID3D11SamplerState *const *samplers)
|
||||
+{
|
||||
+ FIXME("iface %p, start_slot %u, sampler_count %u, samplers %p stub!\n",
|
||||
+ iface, start_slot, sampler_count, samplers);
|
||||
}
|
||||
|
||||
-static HRESULT STDMETHODCALLTYPE d3d11_device_CreateVertexShader(ID3D11Device2 *iface, const void *byte_code,
|
||||
- SIZE_T byte_code_length, ID3D11ClassLinkage *class_linkage, ID3D11VertexShader **shader)
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_Begin(ID3D11DeviceContext *iface,
|
||||
+ ID3D11Asynchronous *asynchronous)
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_VSSetSamplers(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT sampler_count, ID3D11SamplerState *const *samplers)
|
||||
{
|
||||
- struct d3d_device *device = impl_from_ID3D11Device2(iface);
|
||||
- struct d3d_vertex_shader *object;
|
||||
- HRESULT hr;
|
||||
+ FIXME("iface %p, asynchronous %p stub!\n", iface, asynchronous);
|
||||
+ FIXME("iface %p, start_slot %u, sampler_count %u, samplers %p stub!\n",
|
||||
+ iface, start_slot, sampler_count, samplers);
|
||||
+}
|
||||
|
||||
- TRACE("iface %p, byte_code %p, byte_code_length %lu, class_linkage %p, shader %p.\n",
|
||||
- iface, byte_code, byte_code_length, class_linkage, shader);
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_End(ID3D11DeviceContext *iface,
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_Begin(ID3D11DeviceContext *iface,
|
||||
+ ID3D11Asynchronous *asynchronous)
|
||||
+{
|
||||
+ FIXME("iface %p, asynchronous %p stub!\n", iface, asynchronous);
|
||||
@@ -407,44 +402,50 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
|
||||
- if (class_linkage)
|
||||
- FIXME("Class linkage is not implemented yet.\n");
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_End(ID3D11DeviceContext *iface,
|
||||
+ ID3D11Asynchronous *asynchronous)
|
||||
+{
|
||||
+ FIXME("iface %p, asynchronous %p stub!\n", iface, asynchronous);
|
||||
+}
|
||||
|
||||
- if (FAILED(hr = d3d_vertex_shader_create(device, byte_code, byte_code_length, &object)))
|
||||
- return hr;
|
||||
+static HRESULT STDMETHODCALLTYPE d3d11_deferred_context_GetData(ID3D11DeviceContext *iface,
|
||||
+ ID3D11Asynchronous *asynchronous, void *data, UINT data_size, UINT data_flags)
|
||||
+{
|
||||
+ FIXME("iface %p, asynchronous %p, data %p, data_size %u, data_flags %#x stub!\n",
|
||||
+ iface, asynchronous, data, data_size, data_flags);
|
||||
|
||||
- if (FAILED(hr = d3d_vertex_shader_create(device, byte_code, byte_code_length, &object)))
|
||||
- return hr;
|
||||
- *shader = &object->ID3D11VertexShader_iface;
|
||||
+ return E_NOTIMPL;
|
||||
+}
|
||||
|
||||
- *shader = &object->ID3D11VertexShader_iface;
|
||||
- return S_OK;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_SetPredication(ID3D11DeviceContext *iface,
|
||||
+ ID3D11Predicate *predicate, BOOL value)
|
||||
+{
|
||||
+ FIXME("iface %p, predicate %p, value %#x stub!\n", iface, predicate, value);
|
||||
+}
|
||||
|
||||
- return S_OK;
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_GSSetShaderResources(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT view_count, ID3D11ShaderResourceView *const *views)
|
||||
+{
|
||||
+ FIXME("iface %p, start_slot %u, view_count %u, views %p stub!\n", iface, start_slot, view_count, views);
|
||||
}
|
||||
|
||||
-static HRESULT STDMETHODCALLTYPE d3d11_device_CreateGeometryShader(ID3D11Device2 *iface, const void *byte_code,
|
||||
- SIZE_T byte_code_length, ID3D11ClassLinkage *class_linkage, ID3D11GeometryShader **shader)
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_GSSetSamplers(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT sampler_count, ID3D11SamplerState *const *samplers)
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_GSSetShaderResources(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT view_count, ID3D11ShaderResourceView *const *views)
|
||||
{
|
||||
- struct d3d_device *device = impl_from_ID3D11Device2(iface);
|
||||
- struct d3d_geometry_shader *object;
|
||||
- HRESULT hr;
|
||||
+ FIXME("iface %p, start_slot %u, sampler_count %u, samplers %p stub!\n",
|
||||
+ iface, start_slot, sampler_count, samplers);
|
||||
+ FIXME("iface %p, start_slot %u, view_count %u, views %p stub!\n", iface, start_slot, view_count, views);
|
||||
+}
|
||||
|
||||
- TRACE("iface %p, byte_code %p, byte_code_length %lu, class_linkage %p, shader %p.\n",
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_GSSetSamplers(ID3D11DeviceContext *iface,
|
||||
+ UINT start_slot, UINT sampler_count, ID3D11SamplerState *const *samplers)
|
||||
+{
|
||||
+ FIXME("iface %p, start_slot %u, sampler_count %u, samplers %p stub!\n",
|
||||
+ iface, start_slot, sampler_count, samplers);
|
||||
+}
|
||||
+
|
||||
+static void STDMETHODCALLTYPE d3d11_deferred_context_OMSetRenderTargets(ID3D11DeviceContext *iface,
|
||||
+ UINT render_target_view_count, ID3D11RenderTargetView *const *render_target_views,
|
||||
+ ID3D11DepthStencilView *depth_stencil_view)
|
||||
@@ -1352,7 +1353,7 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
iface, byte_code, byte_code_length, class_linkage, shader);
|
||||
|
||||
if (class_linkage)
|
||||
@@ -3362,10 +4340,22 @@ static HRESULT STDMETHODCALLTYPE d3d11_device_CreateCounter(ID3D11Device2 *iface
|
||||
@@ -3593,10 +4571,22 @@ static HRESULT STDMETHODCALLTYPE d3d11_device_CreateCounter(ID3D11Device2 *iface
|
||||
static HRESULT STDMETHODCALLTYPE d3d11_device_CreateDeferredContext(ID3D11Device2 *iface, UINT flags,
|
||||
ID3D11DeviceContext **context)
|
||||
{
|
||||
@@ -1379,10 +1380,10 @@ index 31c7f35fc25..dca5a88caa0 100644
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE d3d11_device_OpenSharedResource(ID3D11Device2 *iface, HANDLE resource, REFIID iid,
|
||||
diff --git a/dlls/d3d11/tests/d3d11.c b/dlls/d3d11/tests/d3d11.c
|
||||
index da4627d7a85..dadeac27662 100644
|
||||
index 32a9dc2e530..362962a9099 100644
|
||||
--- a/dlls/d3d11/tests/d3d11.c
|
||||
+++ b/dlls/d3d11/tests/d3d11.c
|
||||
@@ -2231,6 +2231,8 @@ static void test_create_deferred_context(void)
|
||||
@@ -2266,6 +2266,8 @@ static void test_create_deferred_context(void)
|
||||
|
||||
hr = ID3D11Device_CreateDeferredContext(device, 0, &context);
|
||||
todo_wine ok(hr == DXGI_ERROR_INVALID_CALL, "Failed to create deferred context, hr %#x.\n", hr);
|
||||
@@ -1391,7 +1392,7 @@ index da4627d7a85..dadeac27662 100644
|
||||
|
||||
refcount = ID3D11Device_Release(device);
|
||||
ok(!refcount, "Device has %u references left.\n", refcount);
|
||||
@@ -2243,7 +2245,7 @@ static void test_create_deferred_context(void)
|
||||
@@ -2278,7 +2280,7 @@ static void test_create_deferred_context(void)
|
||||
|
||||
expected_refcount = get_refcount(device) + 1;
|
||||
hr = ID3D11Device_CreateDeferredContext(device, 0, &context);
|
||||
@@ -1401,5 +1402,5 @@ index da4627d7a85..dadeac27662 100644
|
||||
goto done;
|
||||
refcount = get_refcount(device);
|
||||
--
|
||||
2.23.0
|
||||
2.30.0
|
||||
|
||||
|
@@ -1,26 +1,27 @@
|
||||
From c093321833140c3aadacae32c43d160e83483d17 Mon Sep 17 00:00:00 2001
|
||||
From 504969929eb7932fe22880768461f2172080f0eb Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Thu, 19 Jan 2017 16:56:56 +0100
|
||||
Subject: [PATCH] d3d11: Initial implementation for deferred contexts.
|
||||
|
||||
---
|
||||
dlls/d3d11/device.c | 1073 +++++++++++++++++++++++++++++++++++++++++--
|
||||
1 file changed, 1042 insertions(+), 31 deletions(-)
|
||||
dlls/d3d11/device.c | 1072 +++++++++++++++++++++++++++++++++++++++++--
|
||||
1 file changed, 1041 insertions(+), 31 deletions(-)
|
||||
|
||||
diff --git a/dlls/d3d11/device.c b/dlls/d3d11/device.c
|
||||
index dca5a88caa..738f1d19d4 100644
|
||||
index 454003128dc..4beb7cea4fa 100644
|
||||
--- a/dlls/d3d11/device.c
|
||||
+++ b/dlls/d3d11/device.c
|
||||
@@ -17,11 +17,181 @@
|
||||
@@ -16,6 +16,7 @@
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*
|
||||
*/
|
||||
|
||||
+#include "wine/list.h"
|
||||
+
|
||||
|
||||
#define NONAMELESSUNION
|
||||
#include "d3d11_private.h"
|
||||
|
||||
WINE_DEFAULT_DEBUG_CHANNEL(d3d11);
|
||||
@@ -48,6 +49,174 @@ static BOOL d3d_array_reserve(void **elements, SIZE_T *capacity, SIZE_T count, S
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
+enum deferred_cmd
|
||||
+{
|
||||
@@ -193,7 +194,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
/* ID3D11DeviceContext - deferred context */
|
||||
struct d3d11_deferred_context
|
||||
{
|
||||
@@ -29,9 +199,532 @@ struct d3d11_deferred_context
|
||||
@@ -55,9 +224,532 @@ struct d3d11_deferred_context
|
||||
ID3D11Device *device;
|
||||
LONG refcount;
|
||||
|
||||
@@ -726,7 +727,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
static void STDMETHODCALLTYPE d3d_null_wined3d_object_destroyed(void *parent) {}
|
||||
|
||||
static const struct wined3d_parent_ops d3d_null_wined3d_parent_ops =
|
||||
@@ -1226,7 +1919,20 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_ResolveSubresource(ID3D11D
|
||||
@@ -1415,7 +2107,20 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_ResolveSubresource(ID3D11D
|
||||
static void STDMETHODCALLTYPE d3d11_immediate_context_ExecuteCommandList(ID3D11DeviceContext1 *iface,
|
||||
ID3D11CommandList *command_list, BOOL restore_state)
|
||||
{
|
||||
@@ -748,7 +749,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
}
|
||||
|
||||
static void STDMETHODCALLTYPE d3d11_immediate_context_HSSetShaderResources(ID3D11DeviceContext1 *iface,
|
||||
@@ -2938,6 +3644,7 @@ static ULONG STDMETHODCALLTYPE d3d11_deferred_context_Release(ID3D11DeviceContex
|
||||
@@ -3169,6 +3874,7 @@ static ULONG STDMETHODCALLTYPE d3d11_deferred_context_Release(ID3D11DeviceContex
|
||||
|
||||
if (!refcount)
|
||||
{
|
||||
@@ -756,7 +757,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
wined3d_private_store_cleanup(&context->private_store);
|
||||
ID3D11Device_Release(context->device);
|
||||
HeapFree(GetProcessHeap(), 0, context);
|
||||
@@ -2989,43 +3696,86 @@ static HRESULT STDMETHODCALLTYPE d3d11_deferred_context_SetPrivateDataInterface(
|
||||
@@ -3220,43 +3926,86 @@ static HRESULT STDMETHODCALLTYPE d3d11_deferred_context_SetPrivateDataInterface(
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_VSSetConstantBuffers(ID3D11DeviceContext *iface,
|
||||
UINT start_slot, UINT buffer_count, ID3D11Buffer *const *buffers)
|
||||
{
|
||||
@@ -849,7 +850,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
}
|
||||
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_Draw(ID3D11DeviceContext *iface,
|
||||
@@ -3038,53 +3788,169 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_Draw(ID3D11DeviceContext *i
|
||||
@@ -3269,53 +4018,169 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_Draw(ID3D11DeviceContext *i
|
||||
static HRESULT STDMETHODCALLTYPE d3d11_deferred_context_Map(ID3D11DeviceContext *iface, ID3D11Resource *resource,
|
||||
UINT subresource_idx, D3D11_MAP map_type, UINT map_flags, D3D11_MAPPED_SUBRESOURCE *mapped_subresource)
|
||||
{
|
||||
@@ -1028,7 +1029,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
}
|
||||
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_DrawInstanced(ID3D11DeviceContext *iface,
|
||||
@@ -3113,7 +3979,16 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_GSSetShader(ID3D11DeviceCon
|
||||
@@ -3344,7 +4209,16 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_GSSetShader(ID3D11DeviceCon
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_IASetPrimitiveTopology(ID3D11DeviceContext *iface,
|
||||
D3D11_PRIMITIVE_TOPOLOGY topology)
|
||||
{
|
||||
@@ -1046,7 +1047,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
}
|
||||
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_VSSetShaderResources(ID3D11DeviceContext *iface,
|
||||
@@ -3173,8 +4048,28 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_OMSetRenderTargets(ID3D11De
|
||||
@@ -3404,8 +4278,28 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_OMSetRenderTargets(ID3D11De
|
||||
UINT render_target_view_count, ID3D11RenderTargetView *const *render_target_views,
|
||||
ID3D11DepthStencilView *depth_stencil_view)
|
||||
{
|
||||
@@ -1076,7 +1077,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
}
|
||||
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_OMSetRenderTargetsAndUnorderedAccessViews(
|
||||
@@ -3194,15 +4089,44 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_OMSetRenderTargetsAndUnorde
|
||||
@@ -3425,15 +4319,44 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_OMSetRenderTargetsAndUnorde
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_OMSetBlendState(ID3D11DeviceContext *iface,
|
||||
ID3D11BlendState *blend_state, const float blend_factor[4], UINT sample_mask)
|
||||
{
|
||||
@@ -1123,7 +1124,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
}
|
||||
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_SOSetTargets(ID3D11DeviceContext *iface, UINT buffer_count,
|
||||
@@ -3244,13 +4168,34 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_DispatchIndirect(ID3D11Devi
|
||||
@@ -3475,13 +4398,34 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_DispatchIndirect(ID3D11Devi
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_RSSetState(ID3D11DeviceContext *iface,
|
||||
ID3D11RasterizerState *rasterizer_state)
|
||||
{
|
||||
@@ -1160,7 +1161,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
}
|
||||
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_RSSetScissorRects(ID3D11DeviceContext *iface,
|
||||
@@ -3365,8 +4310,18 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_HSSetShaderResources(ID3D11
|
||||
@@ -3596,8 +4540,18 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_HSSetShaderResources(ID3D11
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_HSSetShader(ID3D11DeviceContext *iface,
|
||||
ID3D11HullShader *shader, ID3D11ClassInstance *const *class_instances, UINT class_instance_count)
|
||||
{
|
||||
@@ -1180,7 +1181,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
}
|
||||
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_HSSetSamplers(ID3D11DeviceContext *iface,
|
||||
@@ -3379,36 +4334,62 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_HSSetSamplers(ID3D11DeviceC
|
||||
@@ -3610,36 +4564,62 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_HSSetSamplers(ID3D11DeviceC
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_HSSetConstantBuffers(ID3D11DeviceContext *iface,
|
||||
UINT start_slot, UINT buffer_count, ID3D11Buffer *const *buffers)
|
||||
{
|
||||
@@ -1248,7 +1249,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
}
|
||||
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_CSSetShaderResources(ID3D11DeviceContext *iface,
|
||||
@@ -3709,7 +4690,15 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_CSGetConstantBuffers(ID3D11
|
||||
@@ -3940,7 +4920,15 @@ static void STDMETHODCALLTYPE d3d11_deferred_context_CSGetConstantBuffers(ID3D11
|
||||
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_ClearState(ID3D11DeviceContext *iface)
|
||||
{
|
||||
@@ -1265,7 +1266,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
}
|
||||
|
||||
static void STDMETHODCALLTYPE d3d11_deferred_context_Flush(ID3D11DeviceContext *iface)
|
||||
@@ -3734,9 +4723,29 @@ static UINT STDMETHODCALLTYPE d3d11_deferred_context_GetContextFlags(ID3D11Devic
|
||||
@@ -3965,9 +4953,29 @@ static UINT STDMETHODCALLTYPE d3d11_deferred_context_GetContextFlags(ID3D11Devic
|
||||
static HRESULT STDMETHODCALLTYPE d3d11_deferred_context_FinishCommandList(ID3D11DeviceContext *iface,
|
||||
BOOL restore, ID3D11CommandList **command_list)
|
||||
{
|
||||
@@ -1297,7 +1298,7 @@ index dca5a88caa..738f1d19d4 100644
|
||||
}
|
||||
|
||||
static const struct ID3D11DeviceContextVtbl d3d11_deferred_context_vtbl =
|
||||
@@ -4351,6 +5360,8 @@ static HRESULT STDMETHODCALLTYPE d3d11_device_CreateDeferredContext(ID3D11Device
|
||||
@@ -4582,6 +5590,8 @@ static HRESULT STDMETHODCALLTYPE d3d11_device_CreateDeferredContext(ID3D11Device
|
||||
object->device = (ID3D11Device *)iface;
|
||||
object->refcount = 1;
|
||||
|
||||
@@ -1307,5 +1308,5 @@ index dca5a88caa..738f1d19d4 100644
|
||||
wined3d_private_store_init(&object->private_store);
|
||||
|
||||
--
|
||||
2.21.0
|
||||
2.30.0
|
||||
|
||||
|
@@ -0,0 +1,76 @@
|
||||
From 9ea60091ba885b5f63266374f49f0d63e2cf2767 Mon Sep 17 00:00:00 2001
|
||||
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
|
||||
Date: Wed, 16 Dec 2020 11:07:05 +1100
|
||||
Subject: [PATCH] d3drm: Support IDirect3D3 when creating device
|
||||
|
||||
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=39346
|
||||
---
|
||||
dlls/d3drm/device.c | 26 ++++++++++++++++++++++++--
|
||||
1 file changed, 24 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/dlls/d3drm/device.c b/dlls/d3drm/device.c
|
||||
index 2e1b5f2d24f..fff272197bf 100644
|
||||
--- a/dlls/d3drm/device.c
|
||||
+++ b/dlls/d3drm/device.c
|
||||
@@ -124,7 +124,9 @@ HRESULT d3drm_device_init(struct d3drm_device *device, UINT version, IDirectDraw
|
||||
IDirectDrawSurface *ds = NULL;
|
||||
IDirect3DDevice *device1 = NULL;
|
||||
IDirect3DDevice2 *device2 = NULL;
|
||||
+ IDirect3DDevice3 *device3 = NULL;
|
||||
IDirect3D2 *d3d2 = NULL;
|
||||
+ IDirect3D3 *d3d3 = NULL;
|
||||
DDSURFACEDESC desc, surface_desc;
|
||||
HRESULT hr;
|
||||
|
||||
@@ -171,19 +173,29 @@ HRESULT d3drm_device_init(struct d3drm_device *device, UINT version, IDirectDraw
|
||||
|
||||
if (version == 1)
|
||||
hr = IDirectDrawSurface_QueryInterface(surface, &IID_IDirect3DRGBDevice, (void **)&device1);
|
||||
- else
|
||||
+ else if (version == 2)
|
||||
{
|
||||
IDirectDraw_QueryInterface(ddraw, &IID_IDirect3D2, (void**)&d3d2);
|
||||
hr = IDirect3D2_CreateDevice(d3d2, &IID_IDirect3DRGBDevice, surface, &device2);
|
||||
IDirect3D2_Release(d3d2);
|
||||
}
|
||||
+ else
|
||||
+ {
|
||||
+ IDirectDrawSurface4 *surface4 = NULL;
|
||||
+
|
||||
+ IDirectDrawSurface_QueryInterface(surface, &IID_IDirectDrawSurface4, (void**)&surface4);
|
||||
+ IDirectDraw_QueryInterface(ddraw, &IID_IDirect3D3, (void**)&d3d3);
|
||||
+ hr = IDirect3D3_CreateDevice(d3d3, &IID_IDirect3DRGBDevice, surface4, &device3, NULL);
|
||||
+ IDirectDrawSurface4_Release(surface4);
|
||||
+ IDirect3D3_Release(d3d3);
|
||||
+ }
|
||||
if (FAILED(hr))
|
||||
{
|
||||
IDirectDrawSurface_DeleteAttachedSurface(surface, 0, ds);
|
||||
return hr;
|
||||
}
|
||||
|
||||
- if (version != 1)
|
||||
+ if (version == 2)
|
||||
{
|
||||
hr = IDirect3DDevice2_QueryInterface(device2, &IID_IDirect3DDevice, (void**)&device1);
|
||||
IDirect3DDevice2_Release(device2);
|
||||
@@ -193,6 +205,16 @@ HRESULT d3drm_device_init(struct d3drm_device *device, UINT version, IDirectDraw
|
||||
return hr;
|
||||
}
|
||||
}
|
||||
+ else if (version == 3)
|
||||
+ {
|
||||
+ hr = IDirect3DDevice3_QueryInterface(device3, &IID_IDirect3DDevice, (void**)&device1);
|
||||
+ IDirect3DDevice3_Release(device3);
|
||||
+ if (FAILED(hr))
|
||||
+ {
|
||||
+ IDirectDrawSurface_DeleteAttachedSurface(surface, 0, ds);
|
||||
+ return hr;
|
||||
+ }
|
||||
+ }
|
||||
device->device = device1;
|
||||
device->width = desc.dwWidth;
|
||||
device->height = desc.dwHeight;
|
||||
--
|
||||
2.29.2
|
||||
|
1
patches/d3drm-IDirect3D3-support/definition
Normal file
1
patches/d3drm-IDirect3D3-support/definition
Normal file
@@ -0,0 +1 @@
|
||||
Fixes: [39346] Support IDirect3D3 when creating device.
|
@@ -1,56 +0,0 @@
|
||||
From bbc93f065045b7854f4446d9199c2c22c6251d3d Mon Sep 17 00:00:00 2001
|
||||
From: Christian Costa <titan.costa@gmail.com>
|
||||
Date: Sun, 30 Jul 2017 23:50:18 +0200
|
||||
Subject: [PATCH] d3dx9: Return D3DFMT_A8R8G8B8 in
|
||||
D3DXGetImageInfoFromFileInMemory for 32 bpp BMP with alpha.
|
||||
|
||||
---
|
||||
dlls/d3dx9_36/surface.c | 18 ++++++++++++++++++
|
||||
dlls/d3dx9_36/tests/surface.c | 2 +-
|
||||
2 files changed, 19 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/dlls/d3dx9_36/surface.c b/dlls/d3dx9_36/surface.c
|
||||
index a2eca9cbdb..b670657125 100644
|
||||
--- a/dlls/d3dx9_36/surface.c
|
||||
+++ b/dlls/d3dx9_36/surface.c
|
||||
@@ -980,6 +980,24 @@ HRESULT WINAPI D3DXGetImageInfoFromFileInMemory(const void *data, UINT datasize,
|
||||
}
|
||||
}
|
||||
|
||||
+ /* For 32 bpp BMP, windowscodecs.dll never returns a format with alpha while
|
||||
+ * d3dx9_xx.dll returns one if at least 1 pixel has a non zero alpha component */
|
||||
+ if (SUCCEEDED(hr) && (info->Format == D3DFMT_X8R8G8B8) && (info->ImageFileFormat == D3DXIFF_BMP)) {
|
||||
+ DWORD size = sizeof(DWORD) * info->Width * info->Height;
|
||||
+ BYTE *buffer = HeapAlloc(GetProcessHeap(), 0, size);
|
||||
+ hr = IWICBitmapFrameDecode_CopyPixels(frame, NULL, sizeof(DWORD) * info->Width, size, buffer);
|
||||
+ if (SUCCEEDED(hr)) {
|
||||
+ DWORD i;
|
||||
+ for (i = 0; i < info->Width * info->Height; i++) {
|
||||
+ if (buffer[i*4+3]) {
|
||||
+ info->Format = D3DFMT_A8R8G8B8;
|
||||
+ break;
|
||||
+ }
|
||||
+ }
|
||||
+ }
|
||||
+ HeapFree(GetProcessHeap(), 0, buffer);
|
||||
+ }
|
||||
+
|
||||
if (frame)
|
||||
IWICBitmapFrameDecode_Release(frame);
|
||||
|
||||
diff --git a/dlls/d3dx9_36/tests/surface.c b/dlls/d3dx9_36/tests/surface.c
|
||||
index 04ce57fa4f..db0c9c7291 100644
|
||||
--- a/dlls/d3dx9_36/tests/surface.c
|
||||
+++ b/dlls/d3dx9_36/tests/surface.c
|
||||
@@ -616,7 +616,7 @@ static void test_D3DXGetImageInfo(void)
|
||||
ok(info.Format == D3DFMT_X8R8G8B8, "Got unexpected format %u.\n", info.Format);
|
||||
hr = D3DXGetImageInfoFromFileInMemory(bmp_32bpp_argb, sizeof(bmp_32bpp_argb), &info);
|
||||
ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr);
|
||||
- todo_wine ok(info.Format == D3DFMT_A8R8G8B8, "Got unexpected format %u.\n", info.Format);
|
||||
+ ok(info.Format == D3DFMT_A8R8G8B8, "Got unexpected format %u.\n", info.Format);
|
||||
|
||||
/* Grayscale PNG */
|
||||
hr = D3DXGetImageInfoFromFileInMemory(png_grayscale, sizeof(png_grayscale), &info);
|
||||
--
|
||||
2.21.0
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user