MINOR: quic: Wrong value for version negotiation packet 'Unused' field
The seven less significant bits of the first byte must be arbitrary. Without this fix, QUIC tracker "version_negotiation" test could not pass.
This commit is contained in:
parent
f366cb7bf6
commit
ea78ee1adb
@ -3551,8 +3551,10 @@ static int qc_send_version_negotiation(int fd, struct sockaddr_storage *addr,
|
|||||||
* header form
|
* header form
|
||||||
* long header, fixed bit to 0 for Version Negotiation
|
* long header, fixed bit to 0 for Version Negotiation
|
||||||
*/
|
*/
|
||||||
buf[i++] = '\x80';
|
if (RAND_bytes((unsigned char *)buf, 1) != 1)
|
||||||
|
return 1;
|
||||||
|
|
||||||
|
buf[i++] |= '\x80';
|
||||||
/* null version for Version Negotiation */
|
/* null version for Version Negotiation */
|
||||||
buf[i++] = '\x00';
|
buf[i++] = '\x00';
|
||||||
buf[i++] = '\x00';
|
buf[i++] = '\x00';
|
||||||
|
Loading…
x
Reference in New Issue
Block a user