relays

package
v0.0.0-...-48c56db Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2021 License: BSD-3-Clause Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DecryptB64

func DecryptB64(mctx libkb.MetaContext, teamID keybase1.TeamID, boxB64 string) (res stellar1.RelayContents, err error)

`boxB64` should be a stellar1.EncryptedRelaySecret

func GetKey

func GetKey(mctx libkb.MetaContext, recipient stellarcommon.Recipient) (key keybase1.TeamApplicationKey, teamID keybase1.TeamID, err error)

Get the key used to encrypt the stellar key for a relay transfer A key from the implicit team betwen the logged-in user and `to`. If `generation` is nil, gets the latest key.

Types

type Input

type Input struct {
	From       stellar1.SecretKey
	AmountXLM  string
	Note       string
	PublicMemo *stellarnet.Memo
	// Implicit-team key to encrypt for
	EncryptFor    keybase1.TeamApplicationKey
	SeqnoProvider build.SequenceProvider
	Timebounds    *build.Timebounds
	BaseFee       uint64
}

type Output

type Output struct {
	// Account ID of the shared account.
	RelayAccountID stellar1.AccountID
	// Encrypted box containing the secret key to the account.
	EncryptedB64 string
	FundTx       stellarnet.SignResult
}

func Create

func Create(in Input) (res Output, err error)

Create generates a stellar account, encrypts its key, and signs a transaction funding it.

Jump to

Keyboard shortcuts

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