예제 #1
0
        internal int Update1FA(Login_DTO_Create1FA dto, string NewToken)
        {
            List <ADO_inputParams> inputParamList = new List <ADO_inputParams>()
            {
                new ADO_inputParams()
                {
                    name = "@LgnToken1FA", value = dto.LgnToken1Fa
                },
                new ADO_inputParams()
                {
                    name = "@Lgn1FA", value = Utility.GetSHA256(dto.Lgn1Fa)
                },
                new ADO_inputParams()
                {
                    name = "@LgnNewToken", value = NewToken
                },
                new ADO_inputParams()
                {
                    name = "@CcnEmail", value = dto.CcnEmail
                }
            };


            // A return parameter is required for the operation
            ADO_returnParam retParam = new ADO_returnParam();

            retParam.name  = "return";
            retParam.value = 0;

            //Attempting to create the new entity
            ado.ExecuteNonQueryProcedure("Security_Login_Update1FA", inputParamList, ref retParam);

            //Assign the returned value for checking and output
            return(retParam.value);
        }
예제 #2
0
        internal bool Update1FA(Login_DTO_Create1FA dto, string NewToken)
        {
            Login_ADO lAdo = new Login_ADO(ado);

            return(lAdo.Update1FA(dto, NewToken) > 0);
        }