quic.go 774 B

1234567891011121314151617181920212223242526
  1. //go:build with_quic
  2. package include
  3. import (
  4. "github.com/sagernet/sing-box/adapter/inbound"
  5. "github.com/sagernet/sing-box/adapter/outbound"
  6. "github.com/sagernet/sing-box/protocol/hysteria"
  7. "github.com/sagernet/sing-box/protocol/hysteria2"
  8. _ "github.com/sagernet/sing-box/protocol/naive/quic"
  9. "github.com/sagernet/sing-box/protocol/tuic"
  10. _ "github.com/sagernet/sing-box/transport/v2rayquic"
  11. _ "github.com/sagernet/sing-dns/quic"
  12. )
  13. func registerQUICInbounds(registry *inbound.Registry) {
  14. hysteria.RegisterInbound(registry)
  15. tuic.RegisterInbound(registry)
  16. hysteria2.RegisterInbound(registry)
  17. }
  18. func registerQUICOutbounds(registry *outbound.Registry) {
  19. hysteria.RegisterOutbound(registry)
  20. tuic.RegisterOutbound(registry)
  21. hysteria2.RegisterOutbound(registry)
  22. }