Exploit database

GH-86eeaf4efa344024f10caaad61672e6a

neex/hui2ochko

GitHubNot listedPoC
Download repository ZIP

Sources for CVE-2021-43848

1 source

Preferred order: Exploit-DB, Metasploit, then GitHub repositories by stars.

Repository files57
neex/hui2ochkoRevision 8c5ba6085431
Next files →

Files from this repository share one source choice. Supporting files may cover other vulnerabilities.

patched-quic-go/internal_/wire/pool.go

Go · 581 bytes
package wire

import (
	"sync"

	"github.com/neex/hui2ochko/patched-quic-go/internal_/protocol"
)

var pool sync.Pool

func init() {
	pool.New = func() interface{} {
		return &StreamFrame{
			Data:     make([]byte, 0, protocol.MaxPacketBufferSize),
			fromPool: true,
		}
	}
}

func GetStreamFrame() *StreamFrame {
	f := pool.Get().(*StreamFrame)
	return f
}

func putStreamFrame(f *StreamFrame) {
	if !f.fromPool {
		return
	}
	if protocol.ByteCount(cap(f.Data)) != protocol.MaxPacketBufferSize {
		panic("wire.PutStreamFrame called with packet of wrong size!")
	}
	pool.Put(f)
}