Documentation ¶
Overview ¶
Package blackhole is an outbound handler that blocks all connections.
Index ¶
- type Config
- func (*Config) Descriptor() ([]byte, []int)
- func (c *Config) GetInternalResponse() (ResponseConfig, error)
- func (m *Config) GetResponse() *serial.TypedMessage
- func (*Config) ProtoMessage()
- func (m *Config) Reset()
- func (m *Config) String() string
- func (m *Config) XXX_DiscardUnknown()
- func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Config) XXX_Merge(src proto.Message)
- func (m *Config) XXX_Size() int
- func (m *Config) XXX_Unmarshal(b []byte) error
- type HTTPResponse
- func (*HTTPResponse) Descriptor() ([]byte, []int)
- func (*HTTPResponse) ProtoMessage()
- func (m *HTTPResponse) Reset()
- func (m *HTTPResponse) String() string
- func (*HTTPResponse) WriteTo(writer buf.Writer) int32
- func (m *HTTPResponse) XXX_DiscardUnknown()
- func (m *HTTPResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *HTTPResponse) XXX_Merge(src proto.Message)
- func (m *HTTPResponse) XXX_Size() int
- func (m *HTTPResponse) XXX_Unmarshal(b []byte) error
- type Handler
- type NoneResponse
- func (*NoneResponse) Descriptor() ([]byte, []int)
- func (*NoneResponse) ProtoMessage()
- func (m *NoneResponse) Reset()
- func (m *NoneResponse) String() string
- func (*NoneResponse) WriteTo(buf.Writer) int32
- func (m *NoneResponse) XXX_DiscardUnknown()
- func (m *NoneResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *NoneResponse) XXX_Merge(src proto.Message)
- func (m *NoneResponse) XXX_Size() int
- func (m *NoneResponse) XXX_Unmarshal(b []byte) error
- type ResponseConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Response *serial.TypedMessage `protobuf:"bytes,1,opt,name=response,proto3" json:"response,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*Config) Descriptor ¶
func (*Config) GetInternalResponse ¶
func (c *Config) GetInternalResponse() (ResponseConfig, error)
GetInternalResponse converts response settings from proto to internal data structure.
func (*Config) GetResponse ¶
func (m *Config) GetResponse() *serial.TypedMessage
func (*Config) ProtoMessage ¶
func (*Config) ProtoMessage()
func (*Config) XXX_DiscardUnknown ¶
func (m *Config) XXX_DiscardUnknown()
func (*Config) XXX_Marshal ¶
func (*Config) XXX_Unmarshal ¶
type HTTPResponse ¶
type HTTPResponse struct { XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*HTTPResponse) Descriptor ¶
func (*HTTPResponse) Descriptor() ([]byte, []int)
func (*HTTPResponse) ProtoMessage ¶
func (*HTTPResponse) ProtoMessage()
func (*HTTPResponse) Reset ¶
func (m *HTTPResponse) Reset()
func (*HTTPResponse) String ¶
func (m *HTTPResponse) String() string
func (*HTTPResponse) WriteTo ¶
func (*HTTPResponse) WriteTo(writer buf.Writer) int32
WriteTo implements ResponseConfig.WriteTo().
func (*HTTPResponse) XXX_DiscardUnknown ¶
func (m *HTTPResponse) XXX_DiscardUnknown()
func (*HTTPResponse) XXX_Marshal ¶
func (m *HTTPResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*HTTPResponse) XXX_Merge ¶
func (m *HTTPResponse) XXX_Merge(src proto.Message)
func (*HTTPResponse) XXX_Size ¶
func (m *HTTPResponse) XXX_Size() int
func (*HTTPResponse) XXX_Unmarshal ¶
func (m *HTTPResponse) XXX_Unmarshal(b []byte) error
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
Handler is an outbound connection that silently swallow the entire payload.
type NoneResponse ¶
type NoneResponse struct { XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*NoneResponse) Descriptor ¶
func (*NoneResponse) Descriptor() ([]byte, []int)
func (*NoneResponse) ProtoMessage ¶
func (*NoneResponse) ProtoMessage()
func (*NoneResponse) Reset ¶
func (m *NoneResponse) Reset()
func (*NoneResponse) String ¶
func (m *NoneResponse) String() string
func (*NoneResponse) WriteTo ¶
func (*NoneResponse) WriteTo(buf.Writer) int32
WriteTo implements ResponseConfig.WriteTo().
func (*NoneResponse) XXX_DiscardUnknown ¶
func (m *NoneResponse) XXX_DiscardUnknown()
func (*NoneResponse) XXX_Marshal ¶
func (m *NoneResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*NoneResponse) XXX_Merge ¶
func (m *NoneResponse) XXX_Merge(src proto.Message)
func (*NoneResponse) XXX_Size ¶
func (m *NoneResponse) XXX_Size() int
func (*NoneResponse) XXX_Unmarshal ¶
func (m *NoneResponse) XXX_Unmarshal(b []byte) error
type ResponseConfig ¶
type ResponseConfig interface { // WriteTo writes predefined response to the give buffer. WriteTo(buf.Writer) int32 }
ResponseConfig is the configuration for blackhole responses.
Click to show internal directories.
Click to hide internal directories.