ech_stub.go 587 B

12345678910111213141516171819
  1. //go:build !with_ech
  2. package tls
  3. import (
  4. "context"
  5. "github.com/sagernet/sing-box/log"
  6. "github.com/sagernet/sing-box/option"
  7. E "github.com/sagernet/sing/common/exceptions"
  8. )
  9. func NewECHServer(ctx context.Context, logger log.Logger, options option.InboundTLSOptions) (ServerConfig, error) {
  10. return nil, E.New(`ECH is not included in this build, rebuild with -tags with_ech`)
  11. }
  12. func NewECHClient(ctx context.Context, serverAddress string, options option.OutboundTLSOptions) (Config, error) {
  13. return nil, E.New(`ECH is not included in this build, rebuild with -tags with_ech`)
  14. }