Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrCalculatedIdenStateDoesntMatch = fmt.Errorf("Calculated IdenState doesn't match the one in PublicDataBlobs")
)
Functions ¶
This section is empty.
Types ¶
type IdenPubOffChainReader ¶
type IdenPubOffChainReader interface {
GetPublicData(idenPubUrl string, id *core.ID, idenState *merkletree.Hash) (*PublicData, error)
}
IdenPubOffChainReader is a interface to read the off chain public state of an identity.
type IdenPubOffChainWriter ¶
type IdenPubOffChainWriter interface { Publish(id *core.ID, publicData *PublicData) error Url() string }
IdenPubOffChainWriter is a interface to write the off chain public state of an identity.
type PublicData ¶
type PublicData struct { IdenState *merkletree.Hash ClaimsTreeRoot *merkletree.Hash RevocationsTreeRoot *merkletree.Hash RevocationsTree *merkletree.MerkleTree RootsTreeRoot *merkletree.Hash RootsTree *merkletree.MerkleTree }
PublicData contains the IdenState, ClaimsRoot, RootsTree and RevocationsTree
func NewPublicDataFromBlobs ¶
func NewPublicDataFromBlobs(publicDataBlobs *PublicDataBlobs) (*PublicData, error)
NewPublicDataFromBlobs builds the revocation tree and the roots tree in memory storage. It also checks the validity of the tree roots against the identity state.
type PublicDataBlobs ¶
type PublicDataBlobs struct { IdenState merkletree.Hash ClaimsTreeRoot merkletree.Hash RevocationsTreeRoot merkletree.Hash RevocationsTree []byte RootsTreeRoot merkletree.Hash RootsTree []byte }
PublicDataBlobs contains the RootsTree (blob) + Root, and the RevocationTree (blob) + Root
Click to show internal directories.
Click to hide internal directories.