Пример #1
0
        public static bool LisenceContoll(string key)
        {
            LisansTaleb taleb = new LisansTaleb();

            taleb.Key   = key;
            taleb.HDD   = "";
            taleb.Tarix = DateTime.Now;
            var data = Client.LisansDogrulama(taleb);

            return(data.DogurlulamaKodu == 1);
        }
Пример #2
0
        public LisansCavab LisansDogrulama(LisansTaleb taleb)
        {
            string ip = HttpContext.Current.Request.UserHostAddress;
            string hs = Hash(taleb.Key + taleb.HDD, Text);

            if (hs != taleb.Hash)
            {
                return(new LisansCavab {
                    Key = taleb.Key, HDD = taleb.HDD, Tarix = DateTime.Now, CheckedCode = 0
                });
            }
            LisansCavab cavab = new LisansCavab();

            cavab.Key         = taleb.Key;
            cavab.HDD         = taleb.HDD;
            cavab.CheckedCode = 1;

            return(cavab);
        }