Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
604e39dd
Commit
604e39dd
authored
Sep 02, 2010
by
Juan Lang
Committed by
Alexandre Julliard
Sep 24, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
crypt32: Add parameter checking to CryptSIPCreateIndirectData.
parent
ea715da1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
13 deletions
+5
-13
sip.c
dlls/crypt32/sip.c
+5
-0
softpub.c
dlls/wintrust/tests/softpub.c
+0
-13
No files found.
dlls/crypt32/sip.c
View file @
604e39dd
...
...
@@ -715,6 +715,11 @@ BOOL WINAPI CryptSIPCreateIndirectData(SIP_SUBJECTINFO* pSubjectInfo, DWORD* pcb
TRACE
(
"(%p %p %p)
\n
"
,
pSubjectInfo
,
pcbIndirectData
,
pIndirectData
);
if
(
!
pSubjectInfo
||
!
pSubjectInfo
->
pgSubjectType
||
!
pcbIndirectData
)
{
SetLastError
(
ERROR_INVALID_PARAMETER
);
return
FALSE
;
}
if
((
sip
=
CRYPT_GetCachedSIP
(
pSubjectInfo
->
pgSubjectType
)))
ret
=
sip
->
info
.
pfCreate
(
pSubjectInfo
,
pcbIndirectData
,
pIndirectData
);
TRACE
(
"returning %d
\n
"
,
ret
);
...
...
dlls/wintrust/tests/softpub.c
View file @
604e39dd
...
...
@@ -619,28 +619,17 @@ static void test_sip_create_indirect_data(void)
skip
(
"Missing CryptSIPCreateIndirectData
\n
"
);
return
;
}
if
(
0
)
{
/* FIXME: crashes Wine */
SetLastError
(
0xdeadbeef
);
ret
=
CryptSIPCreateIndirectData_p
(
NULL
,
NULL
,
NULL
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"expected ERROR_INVALID_PARAMETER, got %d
\n
"
,
GetLastError
());
}
/* FIXME: this assignment is only to avoid a crash in Wine, it isn't
* needed by native.
*/
subjinfo
.
pgSubjectType
=
&
unknown
;
SetLastError
(
0xdeadbeef
);
ret
=
CryptSIPCreateIndirectData_p
(
&
subjinfo
,
NULL
,
NULL
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"expected ERROR_INVALID_PARAMETER, got %d
\n
"
,
GetLastError
());
subjinfo
.
cbSize
=
sizeof
(
subjinfo
);
SetLastError
(
0xdeadbeef
);
ret
=
CryptSIPCreateIndirectData_p
(
&
subjinfo
,
NULL
,
NULL
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"expected ERROR_INVALID_PARAMETER, got %d
\n
"
,
GetLastError
());
file
=
create_temp_file
(
temp_file
);
...
...
@@ -655,13 +644,11 @@ if (0)
subjinfo
.
hFile
=
file
;
SetLastError
(
0xdeadbeef
);
ret
=
CryptSIPCreateIndirectData_p
(
&
subjinfo
,
NULL
,
NULL
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"expected ERROR_INVALID_PARAMETER, got %d
\n
"
,
GetLastError
());
subjinfo
.
pgSubjectType
=
&
unknown
;
SetLastError
(
0xdeadbeef
);
ret
=
CryptSIPCreateIndirectData_p
(
&
subjinfo
,
NULL
,
NULL
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"expected ERROR_INVALID_PARAMETER, got %d
\n
"
,
GetLastError
());
count
=
0xdeadbeef
;
...
...
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