private bool IsValidLicense(string license)
        {
            try
            {
                logger.LogDebug("Start IsValidLicense");
                XDocument licenseDoc = XDocument.Load(new StringReader(license));
                string    grantlist  = licenseDoc.Descendants("grantlist").FirstOrDefault().ToString(SaveOptions.DisableFormatting);
                string    productKey = licenseDoc.Descendants("productkey").FirstOrDefault().Value;

                logger.LogDebug("productKey = " + productKey);
                byte[] contentToVerified = UTF8Encoding.UTF8.GetBytes(grantlist);
                string publicKey         = configuration["SiteSettings:Security:PublicKey"];
                logger.LogDebug("publicKey = " + publicKey);
                bool isValid = cryptoGraphysvc.VerifySignedHash(contentToVerified,
                                                                Convert.FromBase64String(productKey),
                                                                publicKey);

                logger.LogWarning(string.Format("Product Key is Valid ? {0}", isValid));

                logger.LogDebug("End IsValidLicense");
                return(isValid);
            }
            catch (Exception ex)
            {
                logger.LogError(ex, "Critical Error in IsValidLicense");
            }

            return(false);
        }