-
Notifications
You must be signed in to change notification settings - Fork 114
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Buffer overrun in httpclient.c - _CreateHttpHeader #437
Comments
yakman2020
pushed a commit
that referenced
this issue
Nov 13, 2017
yakman2020
pushed a commit
that referenced
this issue
Nov 13, 2017
yakman2020
pushed a commit
that referenced
this issue
Nov 13, 2017
jeffaco
pushed a commit
that referenced
this issue
Nov 14, 2017
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The logic that calculates the buffer size does not take into account the trailing \r\n. In cases where 10 digit value consumes 9 or 10 characters, the buffer is overrun.
The fix is to add an extra call to SizeTAdd; something like the following
SizeTAdd(pageSize, 2, &pageSize) != S_OK
This is blocking the release of the PSRP package and repros consistently in PowerShell 6 when creating a new session to office 365.
See issue PowerShell/PowerShell#5130
The text was updated successfully, but these errors were encountered: