Documentation ¶
Index ¶
- func FetchAuthPrv(authStr string) string
- func FetchAuthPub(authStr string) string
- func FetchAuthPubs(authpubsJson string) string
- func FetchCurve(curveStr string) string
- func FetchOrg(orgStr string) string
- func FetchUserAttrs(user string) string
- func FetchUserkey(user string, attr string) string
- func FetchUserkeys(userattrsJson string) string
- func InitAbeService(config Config, abeStorage Storage)
- func NewRandomSecret(orgStr string) string
- func SetupAuth(authStr string, orgStr string) string
- func SetupOrg(orgStr string, lib string, curveStr string, seed string) string
- func SetupUserkey(user string, attr string) string
- func StoreAuthPrv(authStr string, authprvJson string)
- func StoreAuthPub(authStr string, authpub_json string)
- func StoreCurve(curveStr string, curveJson string)
- func StoreOrg(orgStr string, orgJson string)
- func StoreUserkey(user string, attr string, userkey_json string)
- type ActiveConf
- type ArithmeticConf
- type Config
- type Ext
- type LeveldbConf
- type RedisConf
- type Storage
- type StorageConf
- type StorageLeveldb
- type StorageRedis
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FetchAuthPrv ¶
fetch AuthPrv json object from key prv:auth:<authStr>
func FetchAuthPub ¶
fetch AuthPub json object from key pub:auth:<authStr>
func FetchCurve ¶
fetch Curve json object from key pub:curve:<curveStr>
func FetchUserAttrs ¶
fetch UserAttrs json object scanning for keys of the form prv:userkey:<user>:*
func FetchUserkey ¶
fetch Userkey json object from key prv:userkey:<user>:<attr>
func FetchUserkeys ¶
fetch Userkeys json object from keys of the form prv:userkey:<user>:<attr>
func InitAbeService ¶
func NewRandomSecret ¶
generate new random secret for an organization
func SetupUserkey ¶
generate new user key and stores it
func StoreAuthPrv ¶
store AuthPrv json object in key prv:auth:<authStr>
func StoreAuthPub ¶
store AuthPub json object in key pub:auth:<authStr>
func StoreCurve ¶
store Curve json object in key pub:curve:<curveStr>
func StoreUserkey ¶
store Userkey json object in key prv:userkey:<user>:<attr>
Types ¶
type ActiveConf ¶
type ArithmeticConf ¶
type Config ¶
type Config struct { Arithmetic ArithmeticConf `yaml:"arithmetic"` Storage StorageConf `yaml:"storage"` Active ActiveConf `yaml:"active"` }
type LeveldbConf ¶
type LeveldbConf struct {
Name string `yaml:"name"`
}
type StorageConf ¶
type StorageConf struct { Redis map[string]RedisConf `yaml:"redis"` Leveldb map[string]LeveldbConf `yaml:"leveldb"` }
type StorageLeveldb ¶
type StorageLeveldb struct{}
type StorageRedis ¶
type StorageRedis struct{}