VisuUserMgmt (FB) ¶ FUNCTION_BLOCK VisuUserMgmt IMPLEMENTS IVisuUserMgmt4 , IVisuUserManagement4, IExternalUserDatabaseProvider2, VisuElems.IRuntimeBasedUserMgt Properties: LastResult State CheckUserWithTempLockout CurrentUserLockoutTime Methods: ChangeLanguage ChangeUser ChangeUserPassword CheckLoginIntern CheckLoginWithGroupIDIntern FB_Init FillLanguageGroupNames FindUserByType GetCurrentUser GetGroupCount GetGroupFromID GetGroupIDFromIndex GetGroupIndexFromID GetGroupNameFromID GetLastError GetTextIdFromGroupID GetUserCount GetUserDBAsCopy GetUsers Initialize SetLastError SetNewUserDB ChangePassword ChangeUser3 ChangeUser4 ChangeUserPassword3 CheckAdminRights CheckGroups CheckLogin CheckLoginWithGroupID CheckTemporaryLockedUser EditUser GetUserCount3 GetUsers3 GetUsers4 Login LoginRts LoginToUserGroup LoginToUserGroups Logout LogoutRts LogoutUser NewSession RegisterExternalUserDatabaseProvider SetProvider UserCount Users prvCheckUser prvFreeResources prvGetFileName prvGetHashAsWString prvGetHashFromWString prvModifyUser prvReadLine prvReadToken prvReadUser prvReadUserGroup prvReadUsers prvReadUsers2 prvWriteFileChecksum prvWriteUser prvWriteValue Structure: ChangeLanguage (Method) ChangeUser (Method) ChangeUserPassword (Method) CheckLoginIntern (Method) CheckLoginWithGroupIDIntern (Method) FB_Init (Method) FillLanguageGroupNames (Method) FindUserByType (Method) GetCurrentUser (Method) GetGroupCount (Method) GetGroupFromID (Method) GetGroupIDFromIndex (Method) GetGroupIndexFromID (Method) GetGroupNameFromID (Method) GetLastError (Method) GetTextIdFromGroupID (Method) GetUserCount (Method) GetUserDBAsCopy (Method) GetUsers (Method) IRuntimeBasedUserMgt LogoutUser (Method) NewSession (Method) IVisuUserManagement CheckLogin (Method) CheckLoginWithGroupID (Method) RegisterExternalUserDatabaseProvider (Method) IVisuUserManagement2 LoginToUserGroup (Method) LoginToUserGroups (Method) IVisuUserManagement3 ChangePassword (Method) Login (Method) Logout (Method) UserCount (Method) Users (Method) IVisuUserManagement4 EditUser (Method) IVisuUserMgmt-methods SetProvider (Method) IVisuUserMgmt2 CheckTemporaryLockedUser (Method) CheckUserWithTempLockout (Property) CurrentUserLockoutTime (Property) IVisuUserMgmt3 ChangeUser3 (Method) ChangeUserPassword3 (Method) CheckAdminRights (Method) CheckGroups (Method) GetUserCount3 (Method) GetUsers3 (Method) LoginRts (Method) IVisuUserMgmt4 ChangeUser4 (Method) GetUsers4 (Method) LogoutRts (Method) Initialize (Method) LastResult (Property) SetLastError (Method) SetNewUserDB (Method) State (Property) private prvCheckUser (Method) prvFreeResources (Method) prvGetFileName (Method) prvGetHashAsWString (Method) prvGetHashFromWString (Method) prvModifyUser (Method) prvReadLine (Method) prvReadToken (Method) prvReadUser (Method) prvReadUserGroup (Method) prvReadUsers (Method) prvReadUsers2 (Method) prvWriteFileChecksum (Method) prvWriteUser (Method) prvWriteValue (Method)
VisuUserMgmt.ChangeLanguage (METH) ¶ METHOD ChangeLanguage : BOOL InOut: Scope Name Type Return ChangeLanguage BOOL
FilterErrorCode (FUN) ¶ FUNCTION FilterErrorCode : UDINT It filters some error codes This is necessary to avoid giving out some useful information to hackers. e.g. ‘incorrect password’ which also means ‘user is ok’. InOut: Scope Name Type Return FilterErrorCode UDINT Input error UDINT
SwapByteArrayByWords (FUN) ¶ FUNCTION SwapByteArrayByWords : BOOL InOut: Scope Name Type Return SwapByteArrayByWords BOOL Input pData POINTER TO ARRAY [0..20] OF BYTE dwSize DWORD
UtilFillLanguageGroupNames (FUN) ¶ FUNCTION UtilFillLanguageGroupNames : BOOL InOut: Scope Name Type Return UtilFillLanguageGroupNames BOOL Input parrUserGroupTextIds POINTER TO ARRAY [0..0] OF DWORD dwArraySize DWORD
VisuAssignRtsBasedUserMgt (FB) ¶ FUNCTION_BLOCK VisuAssignRtsBasedUserMgt FB used to inform the RTS about the type of visu user management set in the IEC application: visu or runtime based This information is passed to the RTS in FB_Init and FB_Exit Methods: FB_Exit FB_Init Structure: FB_Exit (Method) FB_Init (Method)
VisuAssignRtsBasedUserMgt.FB_Exit (METH) ¶ METHOD FB_Exit : BOOL FB_Exit must be implemented explicitly. If there is an implementation, then the method is called before the controller removes the code of the function block instance (implicit call). The return value is not evaluated. InOut: Scope Name Type Comment Return FB_Exit BOOL Input bInCopyCode BOOL TRUE: the exit method is called in order to leave the instance which will be copied afterwards (online change).
VisuAssignRtsBasedUserMgt.FB_Init (METH) ¶ METHOD FB_Init : BOOL FB_Init is always available implicitly and it is used primarily for initialization. The return value is not evaluated. For a specific influence, you can also declare the methods explicitly and provide additional code there with the standard initialization code. You can evaluate the return value. InOut: Scope Name Type Comment Return FB_Init BOOL Input bInitRetains BOOL TRUE: the retain variables are initialized (reset warm / reset cold) bInCopyCode BOOL TRUE: the instance will be copied to the copy code afterward (online change)
VisuCreateUserMgmtObjects (FUN) ¶ FUNCTION VisuCreateUserMgmtObjects : RTS_IEC_RESULT It’s an helper used to create objects in RTS, these are used in visu user management runtime based It returns the first error found InOut: Scope Name Type Comment Return VisuCreateUserMgmtObjects RTS_IEC_RESULT Input pUserGroups POINTER TO ARRAY [0..0] OF VUM_UserGroup Where get the object name, it’s the group name iArraySize INT How many structures are present in the above array psAppName POINTER TO WSTRING Application name
VisuUserMgmtHasUserRightToChangeUsers (FUN) ¶ FUNCTION VisuUserMgmtHasUserRightToChangeUsers : BOOL InOut: Scope Name Type Return VisuUserMgmtHasUserRightToChangeUsers BOOL Input pvumUser POINTER TO VUM_User itfVisuUserMgmt IVisuUserMgmt