Documentation
¶
Index ¶
- func ContainsString(slice []string, str string) bool
- func GenerateNewKeyPair() (*secp256k1.PrivateKey, *secp256k1.PublicKey)
- func Get2wayTLSClient(cfg *config.Config) (client *http.Client, err error)
- func IsValidHex(s string) bool
- type ISlip39
- type MnemonicsResponse
- type SendTokensRequest
- type SendTokensResponse
- type ShamirCoordinatorService
- func (s *ShamirCoordinatorService) CollectMnemonics() (mnemonics []string, err error)
- func (s *ShamirCoordinatorService) CollectShares(c *gin.Context)
- func (s *ShamirCoordinatorService) CreateMnemonics(hexSecret string) (mnemonics []string, err error)
- func (s *ShamirCoordinatorService) DeployShares(c *gin.Context)
- func (s *ShamirCoordinatorService) GetRoutes() gin.RoutesInfo
- func (s *ShamirCoordinatorService) IsWalletLoaded(rpcURL string, walletname string) (loaded bool, err error)
- func (s *ShamirCoordinatorService) PrepareWallet(passphrase string) (err error)
- func (s *ShamirCoordinatorService) RecoverSeed(mnemonics []string) (seed string, err error)
- func (s *ShamirCoordinatorService) Run() (err error)
- func (s *ShamirCoordinatorService) SendAsset(address string, amount string) (txID string, err error)
- func (s *ShamirCoordinatorService) SendTokens(c *gin.Context)
- type Slip39Interface
- func (s *Slip39Interface) Combine(mnemonics [][]uint16, passphrase string) (secret []byte, err error)
- func (s *Slip39Interface) Generate(groupThreshold uint8, groups []slip39.GroupDescriptor, secret []byte, ...) (result, wordsInEachShare int, sharesBuffer []uint16, err error)
- func (s *Slip39Interface) Random() (random *[0]byte)
- func (s *Slip39Interface) StringsForWords(words []uint16, wordsInEachShare int) (result string, err error)
- func (s *Slip39Interface) WordsForStrings(strings string, wordsInEachShare int) (words []uint16, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ContainsString ¶ added in v0.0.5
func GenerateNewKeyPair ¶
func GenerateNewKeyPair() (*secp256k1.PrivateKey, *secp256k1.PublicKey)
func Get2wayTLSClient ¶ added in v0.0.5
func IsValidHex ¶
Types ¶
type ISlip39 ¶ added in v0.0.5
type ISlip39 interface { Generate(groupThreshold uint8, groups []slip39.GroupDescriptor, secret []byte, password string, iterationExponent uint8, randomGenerator *[0]byte) (result, wordsInEachShare int, sharesBuffer []uint16, err error) Random() (random *[0]byte) StringsForWords(words []uint16, wordsInEachShare int) (result string, err error) Combine(mnemonics [][]uint16, passphrase string) (secret []byte, err error) WordsForStrings(strings string, wordsInEachShare int) (words []uint16, err error) }
type MnemonicsResponse ¶ added in v0.0.5
type SendTokensRequest ¶ added in v0.0.5
type SendTokensResponse ¶ added in v0.0.5
type SendTokensResponse struct {
TxID string `binding:"required" json:"tx-id"`
}
type ShamirCoordinatorService ¶
type ShamirCoordinatorService struct { Router *gin.Engine // contains filtered or unexported fields }
func NewShamirCoordinatorService ¶
func NewShamirCoordinatorService(cfg *config.Config, sscs map[string]client.IShamirShareholderClient, slip39Interface ISlip39, logger log.AppLogger) *ShamirCoordinatorService
func (*ShamirCoordinatorService) CollectMnemonics ¶
func (s *ShamirCoordinatorService) CollectMnemonics() (mnemonics []string, err error)
func (*ShamirCoordinatorService) CollectShares ¶ added in v0.0.5
func (s *ShamirCoordinatorService) CollectShares(c *gin.Context)
func (*ShamirCoordinatorService) CreateMnemonics ¶
func (s *ShamirCoordinatorService) CreateMnemonics(hexSecret string) (mnemonics []string, err error)
func (*ShamirCoordinatorService) DeployShares ¶ added in v0.0.5
func (s *ShamirCoordinatorService) DeployShares(c *gin.Context)
func (*ShamirCoordinatorService) GetRoutes ¶
func (s *ShamirCoordinatorService) GetRoutes() gin.RoutesInfo
func (*ShamirCoordinatorService) IsWalletLoaded ¶ added in v0.0.5
func (s *ShamirCoordinatorService) IsWalletLoaded(rpcURL string, walletname string) (loaded bool, err error)
func (*ShamirCoordinatorService) PrepareWallet ¶ added in v0.0.5
func (s *ShamirCoordinatorService) PrepareWallet(passphrase string) (err error)
func (*ShamirCoordinatorService) RecoverSeed ¶
func (s *ShamirCoordinatorService) RecoverSeed(mnemonics []string) (seed string, err error)
func (*ShamirCoordinatorService) Run ¶
func (s *ShamirCoordinatorService) Run() (err error)
func (*ShamirCoordinatorService) SendAsset ¶
func (s *ShamirCoordinatorService) SendAsset(address string, amount string) (txID string, err error)
func (*ShamirCoordinatorService) SendTokens ¶ added in v0.0.5
func (s *ShamirCoordinatorService) SendTokens(c *gin.Context)
type Slip39Interface ¶ added in v0.0.5
type Slip39Interface struct { }
func (*Slip39Interface) Combine ¶ added in v0.0.5
func (s *Slip39Interface) Combine(mnemonics [][]uint16, passphrase string) (secret []byte, err error)
func (*Slip39Interface) Random ¶ added in v0.0.5
func (s *Slip39Interface) Random() (random *[0]byte)
func (*Slip39Interface) StringsForWords ¶ added in v0.0.5
func (s *Slip39Interface) StringsForWords(words []uint16, wordsInEachShare int) (result string, err error)
func (*Slip39Interface) WordsForStrings ¶ added in v0.0.5
func (s *Slip39Interface) WordsForStrings(strings string, wordsInEachShare int) (words []uint16, err error)
Click to show internal directories.
Click to hide internal directories.