channels

package
v0.0.0-...-82a5cbe Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 24, 2017 License: GPL-3.0 Imports: 27 Imported by: 0

Documentation

Overview

* Copyleft 2017, Simone Margaritelli <evilsocket at protonmail dot com> * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * Neither the name of ARM Inject nor the names of its contributors may be used * to endorse or promote products derived from this software without * specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE.

* Copyleft 2017, Simone Margaritelli <evilsocket at protonmail dot com> * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * Neither the name of ARM Inject nor the names of its contributors may be used * to endorse or promote products derived from this software without * specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE.

* Copyleft 2017, Simone Margaritelli <evilsocket at protonmail dot com> * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * Neither the name of ARM Inject nor the names of its contributors may be used * to endorse or promote products derived from this software without * specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE.

* Copyleft 2017, Simone Margaritelli <evilsocket at protonmail dot com> * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * Neither the name of ARM Inject nor the names of its contributors may be used * to endorse or promote products derived from this software without * specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE.

* Copyleft 2017, Simone Margaritelli <evilsocket at protonmail dot com> * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * Neither the name of ARM Inject nor the names of its contributors may be used * to endorse or promote products derived from this software without * specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE.

* Copyleft 2017, Simone Margaritelli <evilsocket at protonmail dot com> * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * Neither the name of ARM Inject nor the names of its contributors may be used * to endorse or promote products derived from this software without * specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE.

* Copyleft 2017, Simone Margaritelli <evilsocket at protonmail dot com> * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * Neither the name of ARM Inject nor the names of its contributors may be used * to endorse or promote products derived from this software without * specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE.

* Copyleft 2017, Simone Margaritelli <evilsocket at protonmail dot com> * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * Neither the name of ARM Inject nor the names of its contributors may be used * to endorse or promote products derived from this software without * specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE.

* Copyleft 2017, Simone Margaritelli <evilsocket at protonmail dot com> * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * Neither the name of ARM Inject nor the names of its contributors may be used * to endorse or promote products derived from this software without * specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE.

* Copyleft 2017, Simone Margaritelli <evilsocket at protonmail dot com> * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * Neither the name of ARM Inject nor the names of its contributors may be used * to endorse or promote products derived from this software without * specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE.

Index

Constants

View Source
const (
	ProtocolICMP   = 1 /* from iana.ProtocolICMP which being internal I can't use -.- */
	ICMPChunkSize  = 128
	ICMPBufferSize = 512
)
View Source
const (
	Never       = "N"
	TenMinutues = "10M"
	Hour        = "1H"
	Day         = "1D"
	Week        = "1W"
	TwoWeeks    = "2W"
	Month       = "1M"

	Public   = "0"
	Unlisted = "1"
	Private  = "2"
)
View Source
const (
	UDPChunkSize  = 128
	UDPBufferSize = 512
)
View Source
const (
	DefaultStreamName = "PBSTREAM"
)

Variables

View Source
var (
	DNSChunkSize         = 16
	DNSHostAddressParser = regexp.MustCompile("^([^@]+)@([^:]+):([\\d]+)$")
	DNSAddressParser     = regexp.MustCompile("^([^:]+):([\\d]+)$")
	DNSQuestionParser    = regexp.MustCompile("^([a-fA-F0-9]+)\\.(.+)\\.$")
)

Functions

func Register

func Register(channel Channel) error

func Registered

func Registered() map[string]Channel

Types

type Channel

type Channel interface {
	Copy() interface{}
	Name() string
	Description() string
	Register() error
	Setup(direction Direction, args string) error
	Start() error

	HasReader() bool
	Read(b []byte) (n int, err error)

	HasWriter() bool
	Write(b []byte) (n int, err error)

	Stats() Stats
}

func Factory

func Factory(channel_name string, direction Direction) (channel Channel, err error)

type Console

type Console struct {
	// contains filtered or unexported fields
}

func NewConsoleChannel

func NewConsoleChannel() *Console

func (*Console) Copy

func (c *Console) Copy() interface{}

func (*Console) Description

func (c *Console) Description() string

func (*Console) HasReader

func (c *Console) HasReader() bool

func (*Console) HasWriter

func (c *Console) HasWriter() bool

func (*Console) Name

func (c *Console) Name() string

func (*Console) Read

func (c *Console) Read(b []byte) (n int, err error)

func (*Console) Register

func (c *Console) Register() error

func (*Console) Setup

func (c *Console) Setup(direction Direction, args string) error

func (*Console) Start

func (c *Console) Start() error

func (*Console) Stats

func (c *Console) Stats() Stats

func (*Console) Write

func (c *Console) Write(b []byte) (n int, err error)

type DNSChannel

type DNSChannel struct {
	// contains filtered or unexported fields
}

func NewDNSChannel

func NewDNSChannel() *DNSChannel

func (*DNSChannel) Copy

func (c *DNSChannel) Copy() interface{}

func (*DNSChannel) Description

func (c *DNSChannel) Description() string

func (*DNSChannel) HasReader

func (c *DNSChannel) HasReader() bool

func (*DNSChannel) HasWriter

func (c *DNSChannel) HasWriter() bool

func (*DNSChannel) Lookup

func (c *DNSChannel) Lookup(fqdn string) error

func (*DNSChannel) Name

func (c *DNSChannel) Name() string

func (*DNSChannel) Read

func (c *DNSChannel) Read(b []byte) (n int, err error)

func (*DNSChannel) Register

func (c *DNSChannel) Register() error

func (*DNSChannel) Setup

func (c *DNSChannel) Setup(direction Direction, args string) (err error)

func (*DNSChannel) Start

func (c *DNSChannel) Start() error

func (*DNSChannel) Stats

func (c *DNSChannel) Stats() Stats

func (*DNSChannel) Write

func (c *DNSChannel) Write(b []byte) (n int, err error)

type Direction

type Direction int
const (
	INPUT_CHANNEL Direction = iota
	OUTPUT_CHANNEL
)

type ICMPChannel

type ICMPChannel struct {
	// contains filtered or unexported fields
}

func NewICMPChannel

func NewICMPChannel() *ICMPChannel

func (*ICMPChannel) Copy

func (c *ICMPChannel) Copy() interface{}

func (*ICMPChannel) Description

func (c *ICMPChannel) Description() string

func (*ICMPChannel) HasReader

func (c *ICMPChannel) HasReader() bool

func (*ICMPChannel) HasWriter

func (c *ICMPChannel) HasWriter() bool

func (*ICMPChannel) Name

func (c *ICMPChannel) Name() string

func (*ICMPChannel) Read

func (c *ICMPChannel) Read(b []byte) (n int, err error)

func (*ICMPChannel) Register

func (c *ICMPChannel) Register() error

func (*ICMPChannel) Setup

func (c *ICMPChannel) Setup(direction Direction, args string) (err error)

func (*ICMPChannel) Start

func (c *ICMPChannel) Start() (err error)

func (*ICMPChannel) Stats

func (c *ICMPChannel) Stats() Stats

func (*ICMPChannel) Write

func (c *ICMPChannel) Write(b []byte) (n int, err error)

type Paste

type Paste struct {
	Text       string
	Name       string
	Privacy    string
	ExpireDate string
}

type Pastebin

type Pastebin struct {
	// contains filtered or unexported fields
}

func NewPastebinChannel

func NewPastebinChannel() *Pastebin

func (*Pastebin) Copy

func (c *Pastebin) Copy() interface{}

func (*Pastebin) Description

func (c *Pastebin) Description() string

func (*Pastebin) HasReader

func (c *Pastebin) HasReader() bool

func (*Pastebin) HasWriter

func (c *Pastebin) HasWriter() bool

func (*Pastebin) Name

func (c *Pastebin) Name() string

func (*Pastebin) Read

func (c *Pastebin) Read(b []byte) (n int, err error)

func (*Pastebin) Register

func (c *Pastebin) Register() error

func (*Pastebin) Setup

func (c *Pastebin) Setup(direction Direction, args string) error

func (*Pastebin) Start

func (c *Pastebin) Start() error

func (*Pastebin) Stats

func (c *Pastebin) Stats() Stats

func (*Pastebin) Write

func (c *Pastebin) Write(b []byte) (n int, err error)

type PastebinAPI

type PastebinAPI struct {
	ApiKey  string
	UserKey string
}

func NewPastebinAPI

func NewPastebinAPI(ApiKey, UserKey string) *PastebinAPI

func (*PastebinAPI) CreatePaste

func (api *PastebinAPI) CreatePaste(paste Paste) (resp string, err error)

func (*PastebinAPI) DeletePaste

func (api *PastebinAPI) DeletePaste(paste XmlPaste) (resp string, err error)

func (*PastebinAPI) GetPaste

func (api *PastebinAPI) GetPaste(key string) (body string, err error)

func (*PastebinAPI) GetPastes

func (api *PastebinAPI) GetPastes() (pastes []XmlPaste, err error)

func (*PastebinAPI) Request

func (api *PastebinAPI) Request(page string, values url.Values) (body string, err error)

type Stats

type Stats struct {
	TotalRead  int
	TotalWrote int
}

type TCPChannel

type TCPChannel struct {
	// contains filtered or unexported fields
}

func NewTCPChannel

func NewTCPChannel() *TCPChannel

func (*TCPChannel) Copy

func (c *TCPChannel) Copy() interface{}

func (*TCPChannel) Description

func (c *TCPChannel) Description() string

func (*TCPChannel) GetClient

func (c *TCPChannel) GetClient() net.Conn

func (*TCPChannel) HasReader

func (c *TCPChannel) HasReader() bool

func (*TCPChannel) HasWriter

func (c *TCPChannel) HasWriter() bool

func (*TCPChannel) Name

func (c *TCPChannel) Name() string

func (*TCPChannel) Read

func (c *TCPChannel) Read(b []byte) (n int, err error)

func (*TCPChannel) Register

func (c *TCPChannel) Register() error

func (*TCPChannel) SetClient

func (c *TCPChannel) SetClient(con net.Conn)

func (*TCPChannel) Setup

func (c *TCPChannel) Setup(direction Direction, args string) (err error)

func (*TCPChannel) Start

func (c *TCPChannel) Start() (err error)

func (*TCPChannel) Stats

func (c *TCPChannel) Stats() Stats

func (*TCPChannel) WaitForClient

func (c *TCPChannel) WaitForClient()

func (*TCPChannel) Write

func (c *TCPChannel) Write(b []byte) (n int, err error)

type TLSChannel

type TLSChannel struct {
	// contains filtered or unexported fields
}

func NewTLSChannel

func NewTLSChannel() *TLSChannel

func (*TLSChannel) Copy

func (c *TLSChannel) Copy() interface{}

func (*TLSChannel) Description

func (c *TLSChannel) Description() string

func (*TLSChannel) GetClient

func (c *TLSChannel) GetClient() net.Conn

func (*TLSChannel) HasReader

func (c *TLSChannel) HasReader() bool

func (*TLSChannel) HasWriter

func (c *TLSChannel) HasWriter() bool

func (*TLSChannel) Name

func (c *TLSChannel) Name() string

func (*TLSChannel) Read

func (c *TLSChannel) Read(b []byte) (n int, err error)

func (*TLSChannel) Register

func (c *TLSChannel) Register() error

func (*TLSChannel) SetClient

func (c *TLSChannel) SetClient(con net.Conn)

func (*TLSChannel) Setup

func (c *TLSChannel) Setup(direction Direction, args string) (err error)

func (*TLSChannel) Start

func (c *TLSChannel) Start() (err error)

func (*TLSChannel) Stats

func (c *TLSChannel) Stats() Stats

func (*TLSChannel) WaitForClient

func (c *TLSChannel) WaitForClient()

func (*TLSChannel) Write

func (c *TLSChannel) Write(b []byte) (n int, err error)

type UDPChannel

type UDPChannel struct {
	// contains filtered or unexported fields
}

func NewUDPChannel

func NewUDPChannel() *UDPChannel

func (*UDPChannel) Copy

func (c *UDPChannel) Copy() interface{}

func (*UDPChannel) Description

func (c *UDPChannel) Description() string

func (*UDPChannel) HasReader

func (c *UDPChannel) HasReader() bool

func (*UDPChannel) HasWriter

func (c *UDPChannel) HasWriter() bool

func (*UDPChannel) Name

func (c *UDPChannel) Name() string

func (*UDPChannel) Read

func (c *UDPChannel) Read(b []byte) (n int, err error)

func (*UDPChannel) Register

func (c *UDPChannel) Register() error

func (*UDPChannel) Setup

func (c *UDPChannel) Setup(direction Direction, args string) (err error)

func (*UDPChannel) Start

func (c *UDPChannel) Start() (err error)

func (*UDPChannel) Stats

func (c *UDPChannel) Stats() Stats

func (*UDPChannel) Write

func (c *UDPChannel) Write(b []byte) (n int, err error)

type XmlPaste

type XmlPaste struct {
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL