quic.go 596 B

12345678910111213141516171819202122232425
  1. package quic
  2. import (
  3. "github.com/v2fly/v2ray-core/v4/common"
  4. "github.com/v2fly/v2ray-core/v4/transport/internet"
  5. )
  6. //go:generate go run github.com/v2fly/v2ray-core/v4/common/errors/errorgen
  7. // Here is some modification needs to be done before update quic vendor.
  8. // * use bytespool in buffer_pool.go
  9. // * set MaxReceivePacketSize to 1452 - 32 (16 bytes auth, 16 bytes head)
  10. //
  11. //
  12. const (
  13. protocolName = "quic"
  14. internalDomain = "quic.internal.v2fly.org"
  15. )
  16. func init() {
  17. common.Must(internet.RegisterProtocolConfigCreator(protocolName, func() interface{} {
  18. return new(Config)
  19. }))
  20. }