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
718e9dce
Commit
718e9dce
authored
Jun 20, 2018
by
Michael Müller
Committed by
Alexandre Julliard
Jun 20, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
crypt32: Implement decoding of X509_ECC_SIGNATURE.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
d791d36a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
0 deletions
+32
-0
decode.c
dlls/crypt32/decode.c
+32
-0
No files found.
dlls/crypt32/decode.c
View file @
718e9dce
...
@@ -6013,6 +6013,35 @@ static BOOL WINAPI CRYPT_AsnDecodeObjectIdentifier(DWORD dwCertEncodingType,
...
@@ -6013,6 +6013,35 @@ static BOOL WINAPI CRYPT_AsnDecodeObjectIdentifier(DWORD dwCertEncodingType,
return
ret
;
return
ret
;
}
}
static
BOOL
WINAPI
CRYPT_AsnDecodeEccSignature
(
DWORD
dwCertEncodingType
,
LPCSTR
lpszStructType
,
const
BYTE
*
pbEncoded
,
DWORD
cbEncoded
,
DWORD
dwFlags
,
CRYPT_DECODE_PARA
*
pDecodePara
,
void
*
pvStructInfo
,
DWORD
*
pcbStructInfo
)
{
BOOL
ret
;
struct
AsnDecodeSequenceItem
items
[]
=
{
{
ASN_INTEGER
,
offsetof
(
CERT_ECC_SIGNATURE
,
r
),
CRYPT_AsnDecodeUnsignedIntegerInternal
,
sizeof
(
CRYPT_UINT_BLOB
),
FALSE
,
TRUE
,
offsetof
(
CERT_ECC_SIGNATURE
,
r
.
pbData
),
0
},
{
ASN_INTEGER
,
offsetof
(
CERT_ECC_SIGNATURE
,
s
),
CRYPT_AsnDecodeUnsignedIntegerInternal
,
sizeof
(
CRYPT_UINT_BLOB
),
FALSE
,
TRUE
,
offsetof
(
CERT_ECC_SIGNATURE
,
s
.
pbData
),
0
},
};
__TRY
{
ret
=
CRYPT_AsnDecodeSequence
(
items
,
ARRAY_SIZE
(
items
),
pbEncoded
,
cbEncoded
,
dwFlags
,
pDecodePara
,
pvStructInfo
,
pcbStructInfo
,
NULL
,
NULL
);
}
__EXCEPT_PAGE_FAULT
{
SetLastError
(
STATUS_ACCESS_VIOLATION
);
ret
=
FALSE
;
}
__ENDTRY
return
ret
;
}
static
CryptDecodeObjectExFunc
CRYPT_GetBuiltinDecoder
(
DWORD
dwCertEncodingType
,
static
CryptDecodeObjectExFunc
CRYPT_GetBuiltinDecoder
(
DWORD
dwCertEncodingType
,
LPCSTR
lpszStructType
)
LPCSTR
lpszStructType
)
{
{
...
@@ -6155,6 +6184,9 @@ static CryptDecodeObjectExFunc CRYPT_GetBuiltinDecoder(DWORD dwCertEncodingType,
...
@@ -6155,6 +6184,9 @@ static CryptDecodeObjectExFunc CRYPT_GetBuiltinDecoder(DWORD dwCertEncodingType,
case
LOWORD
(
X509_OBJECT_IDENTIFIER
):
case
LOWORD
(
X509_OBJECT_IDENTIFIER
):
decodeFunc
=
CRYPT_AsnDecodeObjectIdentifier
;
decodeFunc
=
CRYPT_AsnDecodeObjectIdentifier
;
break
;
break
;
case
LOWORD
(
X509_ECC_SIGNATURE
):
decodeFunc
=
CRYPT_AsnDecodeEccSignature
;
break
;
}
}
}
}
else
if
(
!
strcmp
(
lpszStructType
,
szOID_CERT_EXTENSIONS
))
else
if
(
!
strcmp
(
lpszStructType
,
szOID_CERT_EXTENSIONS
))
...
...
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