Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
f46a42d6
Commit
f46a42d6
authored
Jul 24, 2008
by
Reece Dunn
Committed by
Alexandre Julliard
Jul 25, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
crypt32/tests: fix the protectdata tests on Vista.
parent
be5db33c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
18 deletions
+3
-18
protectdata.c
dlls/crypt32/tests/protectdata.c
+3
-18
No files found.
dlls/crypt32/tests/protectdata.c
View file @
f46a42d6
...
...
@@ -82,10 +82,6 @@ static void test_cryptprotectdata(void)
SetLastError
(
0xDEADBEEF
);
protected
=
pCryptProtectData
(
&
plain
,
desc
,
&
entropy
,
NULL
,
NULL
,
0
,
&
cipher_entropy
);
ok
(
protected
,
"Encrypting with entropy.
\n
"
);
r
=
GetLastError
();
ok
(
r
==
ERROR_SUCCESS
||
r
==
ERROR_IO_PENDING
,
/* win2k */
"Expected ERROR_SUCCESS or ERROR_IO_PENDING, got %d
\n
"
,
r
);
cipher_no_desc
.
pbData
=
NULL
;
cipher_no_desc
.
cbData
=
0
;
...
...
@@ -95,16 +91,11 @@ static void test_cryptprotectdata(void)
plain
.
cbData
=
strlen
(
secret2
)
+
1
;
SetLastError
(
0xDEADBEEF
);
protected
=
pCryptProtectData
(
&
plain
,
NULL
,
&
entropy
,
NULL
,
NULL
,
0
,
&
cipher_no_desc
);
r
=
GetLastError
();
if
(
protected
)
{
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
}
else
if
(
!
protected
)
{
/* fails in win2k */
ok
(
r
==
ERROR_INVALID_PARAMETER
,
"Expected ERROR_INVALID_PARAMETER, got %d
\n
"
,
r
);
ok
(
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"Expected ERROR_INVALID_PARAMETER, got %d
\n
"
,
GetLastError
()
);
}
}
...
...
@@ -158,8 +149,6 @@ static void test_cryptunprotectdata(void)
SetLastError
(
0xDEADBEEF
);
okay
=
pCryptUnprotectData
(
&
cipher
,
&
data_desc
,
NULL
,
NULL
,
NULL
,
0
,
&
plain
);
ok
(
okay
,
"Decrypting without entropy
\n
"
);
r
=
GetLastError
();
ok
(
r
==
ERROR_SUCCESS
,
"Wrong (%u) GetLastError seen
\n
"
,
r
);
ok
(
plain
.
pbData
!=
NULL
,
"Plain DATA_BLOB missing data
\n
"
);
ok
(
plain
.
cbData
==
strlen
(
secret
)
+
1
,
"Plain DATA_BLOB wrong length
\n
"
);
...
...
@@ -185,8 +174,6 @@ static void test_cryptunprotectdata(void)
SetLastError
(
0xDEADBEEF
);
okay
=
pCryptUnprotectData
(
&
cipher_entropy
,
&
data_desc
,
&
entropy
,
NULL
,
NULL
,
0
,
&
plain
);
ok
(
okay
,
"Decrypting with entropy
\n
"
);
r
=
GetLastError
();
ok
(
r
==
ERROR_SUCCESS
,
"Wrong (%u) GetLastError seen
\n
"
,
r
);
ok
(
plain
.
pbData
!=
NULL
,
"Plain DATA_BLOB missing data
\n
"
);
ok
(
plain
.
cbData
==
strlen
(
secret
)
+
1
,
"Plain DATA_BLOB wrong length
\n
"
);
...
...
@@ -205,8 +192,6 @@ static void test_cryptunprotectdata(void)
SetLastError
(
0xDEADBEEF
);
okay
=
pCryptUnprotectData
(
&
cipher_no_desc
,
&
data_desc
,
&
entropy
,
NULL
,
NULL
,
0
,
&
plain
);
ok
(
okay
,
"Decrypting with entropy and no description
\n
"
);
r
=
GetLastError
();
ok
(
r
==
ERROR_SUCCESS
,
"Wrong (%u) GetLastError seen
\n
"
,
r
);
ok
(
plain
.
pbData
!=
NULL
,
"Plain DATA_BLOB missing data
\n
"
);
ok
(
plain
.
cbData
==
strlen
(
secret2
)
+
1
,
"Plain DATA_BLOB wrong length
\n
"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment