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
6d01d014
Commit
6d01d014
authored
Nov 23, 2022
by
Hans Leidekker
Committed by
Alexandre Julliard
Dec 06, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ncrypt: Implement NCryptSignHash().
Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=53968
parent
07f9952a
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
1 deletion
+16
-1
main.c
dlls/ncrypt/main.c
+14
-0
ncrypt.spec
dlls/ncrypt/ncrypt.spec
+1
-1
ncrypt.h
include/ncrypt.h
+1
-0
No files found.
dlls/ncrypt/main.c
View file @
6d01d014
...
...
@@ -525,6 +525,20 @@ SECURITY_STATUS WINAPI NCryptSetProperty(NCRYPT_HANDLE handle, const WCHAR *name
return
set_object_property
(
object
,
name
,
input
,
insize
);
}
SECURITY_STATUS
WINAPI
NCryptSignHash
(
NCRYPT_KEY_HANDLE
handle
,
void
*
padding
,
BYTE
*
value
,
DWORD
value_len
,
BYTE
*
sig
,
DWORD
sig_len
,
DWORD
*
ret_len
,
DWORD
flags
)
{
struct
object
*
object
=
(
struct
object
*
)
handle
;
TRACE
(
"(%#Ix, %p, %p, %lu, %p, %lu, %#lx)
\n
"
,
handle
,
padding
,
value
,
value_len
,
sig
,
sig_len
,
flags
);
if
(
flags
&
NCRYPT_SILENT_FLAG
)
FIXME
(
"Silent flag not implemented
\n
"
);
if
(
!
object
||
object
->
type
!=
KEY
)
return
NTE_INVALID_HANDLE
;
return
map_ntstatus
(
BCryptSignHash
(
object
->
key
.
bcrypt_key
,
padding
,
value
,
value_len
,
sig
,
sig_len
,
ret_len
,
flags
&
~
NCRYPT_SILENT_FLAG
));
}
SECURITY_STATUS
WINAPI
NCryptVerifySignature
(
NCRYPT_KEY_HANDLE
handle
,
void
*
padding
,
BYTE
*
hash
,
DWORD
hash_size
,
BYTE
*
signature
,
DWORD
signature_size
,
DWORD
flags
)
{
...
...
dlls/ncrypt/ncrypt.spec
View file @
6d01d014
...
...
@@ -91,7 +91,7 @@
@ stub NCryptSecretAgreement
@ stub NCryptSetAuditingInterface
@ stdcall NCryptSetProperty(ptr wstr ptr long long)
@ st
ub NCryptSignHash
@ st
dcall NCryptSignHash(long ptr ptr long ptr long ptr long)
@ stub NCryptStreamClose
@ stub NCryptStreamOpenToProtect
@ stub NCryptStreamOpenToUnprotect
...
...
include/ncrypt.h
View file @
6d01d014
...
...
@@ -125,6 +125,7 @@ SECURITY_STATUS WINAPI NCryptIsAlgSupported(NCRYPT_PROV_HANDLE, const WCHAR *, D
SECURITY_STATUS
WINAPI
NCryptOpenKey
(
NCRYPT_PROV_HANDLE
,
NCRYPT_KEY_HANDLE
*
,
const
WCHAR
*
,
DWORD
,
DWORD
);
SECURITY_STATUS
WINAPI
NCryptOpenStorageProvider
(
NCRYPT_PROV_HANDLE
*
,
const
WCHAR
*
,
DWORD
);
SECURITY_STATUS
WINAPI
NCryptSetProperty
(
NCRYPT_HANDLE
,
const
WCHAR
*
,
BYTE
*
,
DWORD
,
DWORD
);
SECURITY_STATUS
WINAPI
NCryptSignHash
(
NCRYPT_KEY_HANDLE
,
void
*
,
BYTE
*
,
DWORD
,
BYTE
*
,
DWORD
,
DWORD
*
,
DWORD
);
SECURITY_STATUS
WINAPI
NCryptVerifySignature
(
NCRYPT_KEY_HANDLE
,
void
*
,
BYTE
*
,
DWORD
,
BYTE
*
,
DWORD
,
DWORD
);
#ifdef __cplusplus
...
...
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