Exemple #1
0
        public static bool VerifyXml(string xml, string keyName = null)
        {
            XmlDocument doc = new XmlDocument();

            doc.LoadXml(xml);
            return(RsaVerify(doc, KeyStorage.GetPublicKey(keyName)));
        }
Exemple #2
0
 public static string Decrypt(string data, string keyName)
 {
     return(string.IsNullOrEmpty(data) ? data : RsaDecrypt(data, KeyStorage.GetPublicKey(keyName)));
 }