Documentation ¶
Index ¶
- Constants
- Variables
- func GenBindPayload(key []byte, newRmiAddr string) ([]byte, error)
- func GenBind_any(keyAddress []byte, data []byte) []byte
- func GenCallRemoteFunPayload(key []byte, funName string) ([]byte, error)
- func GenHeader(l int) []byte
- func GenRebindPayload(key []byte, newRmiAddr string) ([]byte, error)
- func GenRebind_any(keyAddress []byte, data []byte) []byte
- func GenRemoteConstructorPayload(key []byte, backDoor string, id int) ([]byte, error)
- func GenRequest(header []byte, REQUESTID []byte, keyAddress []byte, data []byte, op []byte, ...) []byte
- func GenResolve_any2(keyAddress []byte, data []byte) []byte
- func GenResolve_any3(keyAddress []byte, data []byte) []byte
- func GetKeyAddress(conn net.Conn) ([]byte, error)
- func GetKeyAddressTest() ([]byte, error)
- func GetKeyFromBytes(locateReply []byte) ([]byte, error)
- func GetRequestPayloadTest() ([]byte, error)
- func SendPayload(addr string, sendPayload PayloadGeneraterFun) error
- type BytesUtils
- func (b *BytesUtils) NewChildBytesUtils(n int) (*BytesUtils, error)
- func (b *BytesUtils) Next(n int)
- func (b *BytesUtils) Read2BytesToInt() (int, error)
- func (b *BytesUtils) Read2BytesToIntUnsafe() int
- func (b *BytesUtils) Read4BytesToInt() (int, error)
- func (b *BytesUtils) Read4BytesToIntUnsafe() int
- func (b *BytesUtils) ReadByte() (byte, error)
- func (b *BytesUtils) ReadByteToUint16() (uint16, error)
- func (b *BytesUtils) ReadByteToUint16Unsafe() uint16
- func (b *BytesUtils) ReadByteUnsafe() byte
- func (b *BytesUtils) ReadBytes(n int) ([]byte, error)
- func (b *BytesUtils) ReadBytesUnsafe(n int) []byte
- func (b *BytesUtils) ReadOthers() ([]byte, error)
- type MessageHeader
- type MessageIOR
- type MessageRequest
- func GetBindMsgTmp() *MessageRequest
- func GetCallRemoteFunMsgTmp() *MessageRequest
- func GetInstallBackDoorMsg(backDoor string) *MessageRequest
- func GetLocateRequestMsgTmp() *MessageRequest
- func GetRebindBackdoorMsgTmp() *MessageRequest
- func GetRebindMsgTmp() *MessageRequest
- func GetReslove_anyMsgTmp() *MessageRequest
- func NewMessageRequest() *MessageRequest
- func ParseMessageRequest(data []byte) (*MessageRequest, error)
- type MessageResponse
- type PayloadGeneraterFun
- type ServiceContext
Constants ¶
View Source
const ( LocateRequest byte = 0x03 LocateReply byte = 0x04 Request byte = 0x00 Reply byte = 0x01 )
View Source
const ( ObjectForward = 2 LocationForward = 3 NoException = 0 UserException = 1 SystemException = 2 )
View Source
const ( CallRemoteFunS = "" /* 620-byte string literal not displayed */ LocateRequestS = "47494f50010200030000001700000002000000000000000b4e616d6553657276696365" RebindS = "" /* 2928-byte string literal not displayed */ BindS = "" /* 2928-byte string literal not displayed */ Reslove_anyS = "" /* 1154-byte string literal not displayed */ RebindBackdoorS = "" /* 8288-byte string literal not displayed */ )
Variables ¶
View Source
var ( REQUESTID2 = []byte("\x00\x00\x00\x02") REQUESTID3 = []byte("\x00\x00\x00\x03") REQUESTFLAG = []byte("\x03") RESERVED = []byte("\x00\x00\x00") TARGET = []byte("\x00\x00\x00\x00") KEYLENGTH = []byte("\x00\x00\x00\x78") OP_bind_any = []byte("bind_any\x00") OP_rebind_any = []byte("rebind_any\x00") OP_resolve_any = []byte("resolve_any\x00") OP_getServerLocation = []byte("getServerLocation\x00") )
View Source
var Exports = map[string]interface{}{ "SendPayload": SendPayload, "BindPayload": GenBindOption, "RebindPayload": GenRebindOption, "InvokePayload": GenRemoteConstructorPayloadOption, }
Functions ¶
func GenBind_any ¶
func GenCallRemoteFunPayload ¶
func GenRebind_any ¶
func GenRequest ¶
func GenResolve_any2 ¶
func GenResolve_any3 ¶
func GetKeyAddressTest ¶
func GetKeyFromBytes ¶
func GetRequestPayloadTest ¶
func SendPayload ¶
func SendPayload(addr string, sendPayload PayloadGeneraterFun) error
Types ¶
type BytesUtils ¶
type BytesUtils struct {
// contains filtered or unexported fields
}
func NewBytesUtils ¶
func NewBytesUtils(data []byte) *BytesUtils
func (*BytesUtils) NewChildBytesUtils ¶
func (b *BytesUtils) NewChildBytesUtils(n int) (*BytesUtils, error)
func (*BytesUtils) Next ¶
func (b *BytesUtils) Next(n int)
func (*BytesUtils) Read2BytesToInt ¶
func (b *BytesUtils) Read2BytesToInt() (int, error)
func (*BytesUtils) Read2BytesToIntUnsafe ¶
func (b *BytesUtils) Read2BytesToIntUnsafe() int
func (*BytesUtils) Read4BytesToInt ¶
func (b *BytesUtils) Read4BytesToInt() (int, error)
func (*BytesUtils) Read4BytesToIntUnsafe ¶
func (b *BytesUtils) Read4BytesToIntUnsafe() int
func (*BytesUtils) ReadByte ¶
func (b *BytesUtils) ReadByte() (byte, error)
func (*BytesUtils) ReadByteToUint16 ¶
func (b *BytesUtils) ReadByteToUint16() (uint16, error)
func (*BytesUtils) ReadByteToUint16Unsafe ¶
func (b *BytesUtils) ReadByteToUint16Unsafe() uint16
func (*BytesUtils) ReadByteUnsafe ¶
func (b *BytesUtils) ReadByteUnsafe() byte
func (*BytesUtils) ReadBytesUnsafe ¶
func (b *BytesUtils) ReadBytesUnsafe(n int) []byte
func (*BytesUtils) ReadOthers ¶
func (b *BytesUtils) ReadOthers() ([]byte, error)
type MessageHeader ¶
func NewMessageHeader ¶
func NewMessageHeader() *MessageHeader
func ParseHeader ¶
func ParseHeader(data []byte) (*MessageHeader, error)
func Bytes2Int(data []byte) int { return int(binary.BigEndian.Uint32(data)) }
type MessageIOR ¶
type MessageRequest ¶
type MessageRequest struct { Header *MessageHeader RequestId int TargetAddr int ResponseFalg byte Reserved []byte TargetAddress int KeyAddress []byte Operation []byte ServiceContextList []*ServiceContext StubData []byte }
func GetBindMsgTmp ¶
func GetBindMsgTmp() *MessageRequest
func GetCallRemoteFunMsgTmp ¶
func GetCallRemoteFunMsgTmp() *MessageRequest
func GetInstallBackDoorMsg ¶
func GetInstallBackDoorMsg(backDoor string) *MessageRequest
func GetLocateRequestMsgTmp ¶
func GetLocateRequestMsgTmp() *MessageRequest
func GetRebindBackdoorMsgTmp ¶
func GetRebindBackdoorMsgTmp() *MessageRequest
func GetRebindMsgTmp ¶
func GetRebindMsgTmp() *MessageRequest
func GetReslove_anyMsgTmp ¶
func GetReslove_anyMsgTmp() *MessageRequest
func NewMessageRequest ¶
func NewMessageRequest() *MessageRequest
func ParseMessageRequest ¶
func ParseMessageRequest(data []byte) (*MessageRequest, error)
func (*MessageRequest) Bytes ¶
func (m *MessageRequest) Bytes() []byte
type MessageResponse ¶
type MessageResponse struct { Header *MessageHeader RequestId int ReplyStatus int IOR *MessageIOR ServiceContextList []*ServiceContext ExceptionId []byte StubData []byte }
func ParseMessageResponse ¶
func ParseMessageResponse(data []byte) (*MessageResponse, error)
type PayloadGeneraterFun ¶
func GenBindOption ¶
func GenBindOption(rmi string) PayloadGeneraterFun
func GenRebindOption ¶
func GenRebindOption(rmi string) PayloadGeneraterFun
func GenRemoteConstructorPayloadOption ¶
func GenRemoteConstructorPayloadOption(backDoor string, cmd string) PayloadGeneraterFun
Click to show internal directories.
Click to hide internal directories.