Class LoginServices


  • public class LoginServices
    extends java.lang.Object
    Title: Login Services
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String module  
      static java.lang.String resource  
    • Constructor Summary

      Constructors 
      Constructor Description
      LoginServices()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void checkNewPassword​(GenericValue userLogin, java.lang.String currentPassword, java.lang.String newPassword, java.lang.String newPasswordVerify, java.lang.String passwordHint, java.util.List<java.lang.String> errorMessageList, boolean ignoreCurrentPassword, java.util.Locale locale)  
      static boolean checkPassword​(java.lang.String oldPassword, boolean useEncryption, java.lang.String currentPassword)  
      static java.util.Map<java.lang.String,​java.lang.Object> createUserLogin​(DispatchContext ctx, java.util.Map<java.lang.String,​?> context)
      Creates a UserLogin
      static void createUserLoginPasswordHistory​(GenericValue userLogin)  
      static java.lang.String getHashType()  
      static java.util.Map<java.lang.String,​java.lang.Object> updatePassword​(DispatchContext ctx, java.util.Map<java.lang.String,​?> context)
      Updates UserLogin Password info
      static java.util.Map<java.lang.String,​java.lang.Object> updateUserLoginId​(DispatchContext ctx, java.util.Map<java.lang.String,​?> context)
      Updates the UserLoginId for a party, replicating password, etc from current login and expiring the old login.
      static java.util.Map<java.lang.String,​java.lang.Object> updateUserLoginSecurity​(DispatchContext ctx, java.util.Map<java.lang.String,​?> context)
      Updates UserLogin Security info
      static java.util.Map<java.lang.String,​java.lang.Object> userImpersonate​(DispatchContext ctx, java.util.Map<java.lang.String,​?> context)
      Login service to authenticate a username without password, storing history
      static java.util.Map<java.lang.String,​java.lang.Object> userLogin​(DispatchContext ctx, java.util.Map<java.lang.String,​?> context)
      Login service to authenticate username and password
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • module

        public static final java.lang.String module
    • Constructor Detail

      • LoginServices

        public LoginServices()
    • Method Detail

      • userLogin

        public static java.util.Map<java.lang.String,​java.lang.Object> userLogin​(DispatchContext ctx,
                                                                                       java.util.Map<java.lang.String,​?> context)
        Login service to authenticate username and password
        Returns:
        Map of results including (userLogin) GenericValue object
      • userImpersonate

        public static java.util.Map<java.lang.String,​java.lang.Object> userImpersonate​(DispatchContext ctx,
                                                                                             java.util.Map<java.lang.String,​?> context)
        Login service to authenticate a username without password, storing history
        Returns:
        Map of results including (userLogin) GenericValue object
      • createUserLogin

        public static java.util.Map<java.lang.String,​java.lang.Object> createUserLogin​(DispatchContext ctx,
                                                                                             java.util.Map<java.lang.String,​?> context)
        Creates a UserLogin
        Parameters:
        ctx - The DispatchContext that this service is operating in
        context - Map containing the input parameters
        Returns:
        Map with the result of the service, the output parameters
      • updatePassword

        public static java.util.Map<java.lang.String,​java.lang.Object> updatePassword​(DispatchContext ctx,
                                                                                            java.util.Map<java.lang.String,​?> context)
        Updates UserLogin Password info
        Parameters:
        ctx - The DispatchContext that this service is operating in
        context - Map containing the input parameters
        Returns:
        Map with the result of the service, the output parameters
      • updateUserLoginId

        public static java.util.Map<java.lang.String,​java.lang.Object> updateUserLoginId​(DispatchContext ctx,
                                                                                               java.util.Map<java.lang.String,​?> context)
        Updates the UserLoginId for a party, replicating password, etc from current login and expiring the old login.
        Parameters:
        ctx - The DispatchContext that this service is operating in
        context - Map containing the input parameters
        Returns:
        Map with the result of the service, the output parameters
      • updateUserLoginSecurity

        public static java.util.Map<java.lang.String,​java.lang.Object> updateUserLoginSecurity​(DispatchContext ctx,
                                                                                                     java.util.Map<java.lang.String,​?> context)
        Updates UserLogin Security info
        Parameters:
        ctx - The DispatchContext that this service is operating in
        context - Map containing the input parameters
        Returns:
        Map with the result of the service, the output parameters
      • checkNewPassword

        public static void checkNewPassword​(GenericValue userLogin,
                                            java.lang.String currentPassword,
                                            java.lang.String newPassword,
                                            java.lang.String newPasswordVerify,
                                            java.lang.String passwordHint,
                                            java.util.List<java.lang.String> errorMessageList,
                                            boolean ignoreCurrentPassword,
                                            java.util.Locale locale)
      • getHashType

        public static java.lang.String getHashType()
      • checkPassword

        public static boolean checkPassword​(java.lang.String oldPassword,
                                            boolean useEncryption,
                                            java.lang.String currentPassword)