Documentation ¶
Index ¶
- func OpenAccount(path string, pwd string, ontSdk *osdk.OntologySdk) (*osdk.Account, error)
- type AlgorithmField
- type DataField
- type DidPubkey
- type OntResolver
- func (o *OntResolver) CreateCredential(did string, idx int, content interface{}, commit bool) (string, string, error)
- func (o *OntResolver) EncrypteDataWithDID(data []byte, did string) ([]byte, error)
- func (o *OntResolver) GetDidPubkeys(did string, idx int) (*DidPubkey, error)
- func (o *OntResolver) RevokeCredential(did string, idx int, credstr string) (string, error)
- func (o *OntResolver) SignData(data []byte) ([]byte, error)
- func (o *OntResolver) ValidateSig(did string, idx int, msg string, sig string) (bool, error)
- type OrangeCredential
- type Resolver
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func OpenAccount ¶
Types ¶
type AlgorithmField ¶
type OntResolver ¶
type OntResolver struct {
// contains filtered or unexported fields
}
func NewOntResolver ¶
func NewOntResolver(config *config.DidConf) (*OntResolver, error)
func (*OntResolver) CreateCredential ¶
func (*OntResolver) EncrypteDataWithDID ¶
func (o *OntResolver) EncrypteDataWithDID(data []byte, did string) ([]byte, error)
func (*OntResolver) GetDidPubkeys ¶
func (o *OntResolver) GetDidPubkeys(did string, idx int) (*DidPubkey, error)
func (*OntResolver) RevokeCredential ¶
func (*OntResolver) ValidateSig ¶
type OrangeCredential ¶
type OrangeCredential struct { Data *DataField `json:"data"` Algorithm *AlgorithmField `json:"algorithm"` }
type Resolver ¶
type Resolver interface { ValidateSig(did string, idx int, msg string, sig string) (bool, error) CreateCredential(did string, idx int, content interface{}, commit bool) (string, string, error) RevokeCredential(did string, idx int, cred string) (string, error) SignData(data []byte) ([]byte, error) EncrypteDataWithDID(data []byte, did string) ([]byte, error) }
Click to show internal directories.
Click to hide internal directories.