Skip to content
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

Verify ref_pkt's are long enough #4696

Merged
merged 1 commit into from
Jun 25, 2018
Merged

Conversation

nelhage
Copy link
Contributor

@nelhage nelhage commented Jun 24, 2018

If the remote sends a too-short packet, we'll allow len to go
negative and eventually issue a malloc for <= 0 bytes on

pkt->head.name = git__malloc(alloclen);

This was found by an oss-fuzz integration I'm working on.

If the remote sends a too-short packet, we'll allow `len` to go
negative and eventually issue a malloc for <= 0 bytes on

```
pkt->head.name = git__malloc(alloclen);
```
@pks-t pks-t merged commit 983f72c into libgit2:master Jun 25, 2018
@pks-t
Copy link
Member

pks-t commented Jun 25, 2018

Thanks for the fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants