Documentation ¶
Index ¶
Constants ¶
View Source
const ( MsgErrInvalidParam = "invalidParameter" MsgErrMissingParam = "missingParameter" MsgErrWrongTypeRequest = "wrongTypeRequest" MsgErrInvalidJSONRequest = "invalidJSONRequest" MsgErrInvalidBase64Object = "invalidBase64Object" MsgErrInvalidLength = "invalidLength" MsgErrCannotObtain = "cannotObtain" MsgErrCannotMarshal = "cannotMarshal" MsgErrCannotSaveConfigInDB = "cannotSaveConfigInDB" MsgErrCannotUpdate = "cannotUpdate" MsgErrUnknown = "unknowError" MsgErrNotConfigured = "notConfigured" MsgErrUnverified = "unverifiedFlag" BodyContent = "bodyContent" RealmConfiguration = "realmConfiguration" RealmAdminConfiguration = "realmAdminConfiguration" Authorization = "authorization" CurrentPassword = "currentPassword" NewPassword = "newPassword" ConfirmPassword = "confirmPassword" Password = "password" Type = "type" ID = "id" Label = "label" UserID = "userId" Username = "username" User = "user" UserLabel = "userLabel" Email = "email" Firstname = "firstname" Lastname = "lastname" PhoneNumber = "phoneNumber" Gender = "gender" Birthdate = "birthdate" GroupID = "groupId" GroupName = "groupName" Name = "name" GroupIDs = "groupIds" RoleID = "roleId" CredentialID = "credentialID" Locale = "locale" Description = "description" ContainerID = "containerId" DefaultClientID = "defaultClientId" DefaultRedirectURI = "defaultRedirectURI" RedirectCancelledRegistrationURL = "redirectCancelledRegistrationURL" RedirectSuccessfulRegistrationURL = "redirectSuccessfulRegistrationURL" BarcodeType = "barcodeType" RequiredAction = "requiredAction" DurationLabel = "durationLabel" Body = "body" Flatbuffer = "flatbuffer" Realm = "realm" KeycloakRealms = "keycloakRealms" Config = "config" Response = "response" ListOfRealms = "listOfRealms" Groups = "groups" ClientID = "clientId" RedirectURI = "redirectURI" Exclude = "exclude" Unit = "unit" Max = "max" Timeshift = "timeshift" IdentityProvider = "identityProvider" TrustIDGroupName = "trustIDGroupName" )
Normalized error messages
View Source
const ( AttrbAccreditations = kc.AttributeKey("accreditations") AttrbBirthDate = kc.AttributeKey("ENC_birthDate") AttrbGender = kc.AttributeKey("ENC_gender") AttrbLabel = kc.AttributeKey("label") AttrbLocale = kc.AttributeKey("locale") AttrbPhoneNumber = kc.AttributeKey("phoneNumber") AttrbPhoneNumberVerified = kc.AttributeKey("phoneNumberVerified") AttrbSmsSent = kc.AttributeKey("smsSent") AttrbSmsAttempts = kc.AttributeKey("smsAttempts") AttrbTrustIDAuthToken = kc.AttributeKey("trustIDAuthToken") AttrbTrustIDGroups = kc.AttributeKey("trustIDGroups") )
Attribute keys definition
View Source
const ( RegExpID = `^[a-z0-9]{8}-[a-z0-9]{4}-[a-z0-9]{4}-[a-z0-9]{4}-[a-z0-9]{12}$` RegExpName = `^[a-zA-Z0-9-_]{1,128}$` RegExpDescription = regExpLen255 // Client RegExpClientID = `^[a-zA-Z0-9-_.]{1,255}$` // User RegExpUsername = `^[a-zA-Z0-9-_.]{1,128}$` RegExpEmail = `^.+\@.+\..+$` RegExpNameSpecialChars = `^([\wàáâäçèéêëìíîïñòóôöùúûüß][\wàáâäçèéêëìíîïñòóôöùúûüß \.'-]{0,49})$` RegExpFirstName = regExpLen128 RegExpLastName = regExpLen128 RegExpPhoneNumber = `^\+[1-9]\d{1,14}$` RegExpLabel = regExpLen255 RegExpGender = `^[MFU]$` RegExpBirthDate = `^(\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\d|3[01]))$` RegExpLocale = `^[a-z]{2}$` RegExpIDDocumentNumber = `^([\w\d]+([\. -][\w\d]+)*){1,50}$` // Password RegExpPassword = regExpLen255 // RealmCustomConfiguration RegExpRedirectURI = `^\w+:(\/?\/?)[^\s]+$` // RequiredAction RegExpRequiredAction = `^[a-zA-Z0-9-_]{1,255}$` // Others RegExpRealmName = `^[a-zA-Z0-9_-]{1,36}$` RegExpSearch = regExpLen128 RegExpLifespan = `^[0-9]{1,10}$` RegExpGroupIds = `` /* 133-byte string literal not displayed */ RegExpNumber = `^\d+$` )
Regular expressions for parameters validation
Variables ¶
View Source
var (
SupportedDateLayouts = []string{"02.01.2006", "2006-01-02"}
)
Date layout management: first date layout is the one used to format dates in Keycloak. Following one are other supported format when parsing
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.