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
842e0a53
Commit
842e0a53
authored
Mar 13, 2011
by
Ken Thomases
Committed by
Alexandre Julliard
Mar 14, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
secur32: Use schan_imp_get_connection_info to get MAC size.
parent
f7e598cf
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
14 deletions
+19
-14
schannel.c
dlls/secur32/schannel.c
+19
-14
No files found.
dlls/secur32/schannel.c
View file @
842e0a53
...
...
@@ -1041,20 +1041,25 @@ static SECURITY_STATUS SEC_ENTRY schan_QueryContextAttributesW(
{
case
SECPKG_ATTR_STREAM_SIZES
:
{
SecPkgContext_StreamSizes
*
stream_sizes
=
buffer
;
gnutls_mac_algorithm_t
mac
=
pgnutls_mac_get
(
ctx
->
session
);
size_t
mac_size
=
pgnutls_mac_get_key_size
(
mac
);
unsigned
int
block_size
=
schan_imp_get_session_cipher_block_size
(
ctx
->
session
);
TRACE
(
"Using %zu mac bytes, block size %u
\n
"
,
mac_size
,
block_size
);
/* These are defined by the TLS RFC */
stream_sizes
->
cbHeader
=
5
;
stream_sizes
->
cbTrailer
=
mac_size
+
256
;
/* Max 255 bytes padding + 1 for padding size */
stream_sizes
->
cbMaximumMessage
=
1
<<
14
;
stream_sizes
->
cbBuffers
=
4
;
stream_sizes
->
cbBlockSize
=
block_size
;
return
SEC_E_OK
;
SecPkgContext_ConnectionInfo
info
;
SECURITY_STATUS
status
=
schan_imp_get_connection_info
(
ctx
->
session
,
&
info
);
if
(
status
==
SEC_E_OK
)
{
SecPkgContext_StreamSizes
*
stream_sizes
=
buffer
;
size_t
mac_size
=
info
.
dwHashStrength
;
unsigned
int
block_size
=
schan_imp_get_session_cipher_block_size
(
ctx
->
session
);
TRACE
(
"Using %zu mac bytes, block size %u
\n
"
,
mac_size
,
block_size
);
/* These are defined by the TLS RFC */
stream_sizes
->
cbHeader
=
5
;
stream_sizes
->
cbTrailer
=
mac_size
+
256
;
/* Max 255 bytes padding + 1 for padding size */
stream_sizes
->
cbMaximumMessage
=
1
<<
14
;
stream_sizes
->
cbBuffers
=
4
;
stream_sizes
->
cbBlockSize
=
block_size
;
}
return
status
;
}
case
SECPKG_ATTR_REMOTE_CERT_CONTEXT
:
{
...
...
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