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
0b7dba8c
Commit
0b7dba8c
authored
Nov 02, 2021
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dnsapi: Fix the DNS_KEY_DATA and DNS_SIG_DATA structure definitions.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
da89825f
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
10 deletions
+14
-10
libresolv.c
dlls/dnsapi/libresolv.c
+2
-0
record.c
dlls/dnsapi/record.c
+6
-6
windns.h
include/windns.h
+6
-4
No files found.
dlls/dnsapi/libresolv.c
View file @
0b7dba8c
...
...
@@ -581,6 +581,7 @@ static DNS_STATUS copy_rdata( ns_msg msg, const ns_rr *rr, DNS_RECORDA *r, WORD
r
->
Data
.
KEY
.
chAlgorithm
=
*
pos
++
;
size
=
rr
->
rdata
+
rr
->
rdlength
-
pos
;
r
->
Data
.
KEY
.
wKeyLength
=
size
;
for
(
i
=
0
;
i
<
size
;
i
++
)
r
->
Data
.
KEY
.
Key
[
i
]
=
*
pos
++
;
...
...
@@ -668,6 +669,7 @@ static DNS_STATUS copy_rdata( ns_msg msg, const ns_rr *rr, DNS_RECORDA *r, WORD
r
->
Data
.
SIG
.
wKeyTag
=
*
(
const
WORD
*
)
pos
;
size
=
rr
->
rdata
+
rr
->
rdlength
-
pos
;
r
->
Data
.
SIG
.
wSignatureLength
=
size
;
for
(
i
=
0
;
i
<
size
;
i
++
)
r
->
Data
.
SIG
.
Signature
[
i
]
=
*
pos
++
;
...
...
dlls/dnsapi/record.c
View file @
0b7dba8c
...
...
@@ -221,10 +221,10 @@ BOOL WINAPI DnsRecordCompare( PDNS_RECORD r1, PDNS_RECORD r2 )
{
if
(
r1
->
Data
.
KEY
.
wFlags
!=
r2
->
Data
.
KEY
.
wFlags
||
r1
->
Data
.
KEY
.
chProtocol
!=
r2
->
Data
.
KEY
.
chProtocol
||
r1
->
Data
.
KEY
.
chAlgorithm
!=
r2
->
Data
.
KEY
.
chAlgorithm
)
r1
->
Data
.
KEY
.
chAlgorithm
!=
r2
->
Data
.
KEY
.
chAlgorithm
||
r1
->
Data
.
KEY
.
wKeyLength
!=
r2
->
Data
.
KEY
.
wKeyLength
)
return
FALSE
;
if
(
memcmp
(
r1
->
Data
.
KEY
.
Key
,
r2
->
Data
.
KEY
.
Key
,
r1
->
wDataLength
-
sizeof
(
DNS_KEY_DATA
)
+
1
))
if
(
memcmp
(
r1
->
Data
.
KEY
.
Key
,
r2
->
Data
.
KEY
.
Key
,
r1
->
Data
.
KEY
.
wKeyLength
))
return
FALSE
;
break
;
}
...
...
@@ -238,10 +238,10 @@ BOOL WINAPI DnsRecordCompare( PDNS_RECORD r1, PDNS_RECORD r2 )
r1
->
Data
.
SIG
.
dwOriginalTtl
!=
r2
->
Data
.
SIG
.
dwOriginalTtl
||
r1
->
Data
.
SIG
.
dwExpiration
!=
r2
->
Data
.
SIG
.
dwExpiration
||
r1
->
Data
.
SIG
.
dwTimeSigned
!=
r2
->
Data
.
SIG
.
dwTimeSigned
||
r1
->
Data
.
SIG
.
wKeyTag
!=
r2
->
Data
.
SIG
.
wKeyTag
)
r1
->
Data
.
SIG
.
wKeyTag
!=
r2
->
Data
.
SIG
.
wKeyTag
||
r1
->
Data
.
SIG
.
wSignatureLength
!=
r2
->
Data
.
SIG
.
wSignatureLength
)
return
FALSE
;
if
(
memcmp
(
r1
->
Data
.
SIG
.
Signature
,
r2
->
Data
.
SIG
.
Signature
,
r1
->
wDataLength
-
sizeof
(
DNS_SIG_DATAA
)
+
1
))
if
(
memcmp
(
r1
->
Data
.
SIG
.
Signature
,
r2
->
Data
.
SIG
.
Signature
,
r1
->
Data
.
SIG
.
wSignatureLength
))
return
FALSE
;
break
;
}
...
...
include/windns.h
View file @
0b7dba8c
...
...
@@ -339,6 +339,8 @@ typedef struct
WORD
wFlags
;
BYTE
chProtocol
;
BYTE
chAlgorithm
;
WORD
wKeyLength
;
WORD
wPad
;
BYTE
Key
[
1
];
}
DNS_KEY_DATA
,
*
PDNS_KEY_DATA
;
...
...
@@ -355,7 +357,6 @@ typedef struct
typedef
struct
{
PSTR
pNameSigner
;
WORD
wTypeCovered
;
BYTE
chAlgorithm
;
BYTE
chLabelCount
;
...
...
@@ -363,13 +364,13 @@ typedef struct
DWORD
dwExpiration
;
DWORD
dwTimeSigned
;
WORD
wKeyTag
;
WORD
Pad
;
WORD
wSignatureLength
;
PSTR
pNameSigner
;
BYTE
Signature
[
1
];
}
DNS_SIG_DATAA
,
*
PDNS_SIG_DATAA
;
typedef
struct
{
PWSTR
pNameSigner
;
WORD
wTypeCovered
;
BYTE
chAlgorithm
;
BYTE
chLabelCount
;
...
...
@@ -377,7 +378,8 @@ typedef struct
DWORD
dwExpiration
;
DWORD
dwTimeSigned
;
WORD
wKeyTag
;
WORD
Pad
;
WORD
wSignatureLength
;
PWSTR
pNameSigner
;
BYTE
Signature
[
1
];
}
DNS_SIG_DATAW
,
*
PDNS_SIG_DATAW
;
...
...
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