Documentation ¶
Index ¶
- type Pipe
- func (p Pipe) Decrypt(src []byte) (dst []byte)
- func (p Pipe) DecryptGiveKey(src []byte) (dst []byte, vk string)
- func (p Pipe) EA() (ae service.Addr, err error)
- func (p Pipe) Encrypt(src []byte) (dst []byte)
- func (p Pipe) IsNull() bool
- func (p Pipe) Pack(src []byte) (dst []byte, vk string, err error)
- func (p Pipe) Sign(src []byte) (dst []byte, vk string)
- func (p Pipe) SignAndStamp(src []byte) (data, dst []byte, vk string)
- func (p Pipe) Unpack(src []byte) (dst []byte, vk string, err error)
- func (p Pipe) Verify(msg, signature []byte) (yes bool, vk string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Pipe ¶
Pipe is secure way to transport data between DID connection. All agent to agent communication uses it. For its internal structure we must define the direction of the pipe.
func NewPipeByVerkey ¶
NewPipeByVerkey creates a new secure pipe by our DID and other end's public key.
func (Pipe) DecryptGiveKey ¶
DecryptGiveKey decrypts scr bytes and returns the verkey as well. Note! It throws an err2 exception. So, there should be at least one error handler in the call stack.
func (Pipe) Encrypt ¶
Encrypt encrypts the byte slice. Note! It throws err2 type of an error and needs an error handler in the call stack.
func (Pipe) Sign ¶
Sign sings the message and returns the verification key. Note! It throws err2 type of an error and needs an error handler in the call stack.
func (Pipe) SignAndStamp ¶
SignAndStamp sings and stamps a message and returns the verification key. Note! It throws err2 type of an error and needs an error handler in the call stack.