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

Potential Memory Leak #3

Open
ii64 opened this issue Nov 6, 2020 · 0 comments
Open

Potential Memory Leak #3

ii64 opened this issue Nov 6, 2020 · 0 comments

Comments

@ii64
Copy link

ii64 commented Nov 6, 2020

enet/host.go

Line 131 in e3453d3

payload := make([]byte, int(pkhdr.Size)-binary.Size(pkhdr))

It is reserve much memory, it also based on the request data which can be remoted and easily crash server.

host bind 127.0.0.1:11771
running...
skipped packet: 136
runtime: VirtualAlloc of 3747053568 bytes failed with errno=1455
fatal error: out of memory

runtime stack:
runtime.throw(0x51b5b4, 0xd)
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

No branches or pull requests

1 participant