Documentation ¶
Index ¶
- Constants
- func CanRegisterAttribute(requestedAttr *api.Attribute, allRequestedAttrs []api.Attribute, ...) error
- func CanRegisterRequestedAttributes(reqAttrs []api.Attribute, user, registrar AttributeControl) error
- func ConvertAttrs(inAttrs map[string]string) ([]api.Attribute, error)
- func Exists(attrs []api.Attribute, name string) bool
- func GetAttrValue(attrs []api.Attribute, name string) string
- type AttributeControl
Constants ¶
View Source
const ( // BOOLEAN indicates that the attribute is of type boolean BOOLEAN attributeType = 1 + iota // LIST indicates that the attribute is of type list LIST // FIXED indicates that the attribute value is fixed and can't be modified FIXED // CUSTOM indicates that the attribute is a custom attribute CUSTOM )
View Source
const ( Roles = "hf.Registrar.Roles" DelegateRoles = "hf.Registrar.DelegateRoles" Revoker = "hf.Revoker" IntermediateCA = "hf.IntermediateCA" GenCRL = "hf.GenCRL" RegistrarAttr = "hf.Registrar.Attributes" AffiliationMgr = "hf.AffiliationMgr" EnrollmentID = "hf.EnrollmentID" Type = "hf.Type" Affiliation = "hf.Affiliation" )
Attribute names
Variables ¶
This section is empty.
Functions ¶
func CanRegisterAttribute ¶
func CanRegisterAttribute(requestedAttr *api.Attribute, allRequestedAttrs []api.Attribute, user, registrar AttributeControl) error
CanRegisterAttribute will iterate through the values of registrar's 'hf.Registrar.Attributes' attribute to check if registrar can register the requested attributes
func CanRegisterRequestedAttributes ¶
func CanRegisterRequestedAttributes(reqAttrs []api.Attribute, user, registrar AttributeControl) error
CanRegisterRequestedAttributes validates that the registrar can register the requested attributes
func ConvertAttrs ¶
ConvertAttrs converts attribute string into an Attribute object array
Types ¶
Click to show internal directories.
Click to hide internal directories.