1 type derived from EncryptedXml
Microsoft.AspNetCore.DataProtection (1)
XmlEncryption\EncryptedXmlDecryptor.cs (1)
89private sealed class EncryptedXmlWithCertificateKeys : EncryptedXml
4 instantiations of EncryptedXml
Microsoft.AspNetCore.DataProtection (1)
XmlEncryption\CertificateXmlEncryptor.cs (1)
93var encryptedXml = new EncryptedXml(xmlDocument);
Microsoft.Extensions.Configuration.Xml (1)
XmlDocumentDecryptor.cs (1)
111EncryptedXml encryptedXml = _encryptedXmlFactory?.Invoke(document) ?? new EncryptedXml(document);
System.Security.Cryptography.Xml (2)
System\Security\Cryptography\Xml\SignedXml.cs (1)
177get => field ??= new EncryptedXml(_containingDocument!); // default processing rules
System\Security\Cryptography\Xml\XmlDecryptionTransform.cs (1)
61_exml = new EncryptedXml(_containingDocument!); // default processing rules
89 references to EncryptedXml
Microsoft.AspNetCore.DataProtection (7)
XmlEncryption\CertificateXmlEncryptor.cs (3)
93var encryptedXml = new EncryptedXml(xmlDocument); 95EncryptedXml.ReplaceElement(elementToEncrypt, encryptedData, content: false); 123EncryptedData IInternalCertificateXmlEncryptor.PerformEncryption(EncryptedXml encryptedXml, XmlElement elementToEncrypt)
XmlEncryption\EncryptedXmlDecryptor.cs (2)
18/// An <see cref="IXmlDecryptor"/> that decrypts XML elements by using the <see cref="EncryptedXml"/> class. 81void IInternalEncryptedXmlDecryptor.PerformPreDecryptionSetup(EncryptedXml encryptedXml)
XmlEncryption\IInternalCertificateXmlEncryptor.cs (1)
14EncryptedData PerformEncryption(EncryptedXml encryptedXml, XmlElement elementToEncrypt);
XmlEncryption\IInternalEncryptedXmlDecryptor.cs (1)
13void PerformPreDecryptionSetup(EncryptedXml encryptedXml);
Microsoft.AspNetCore.DataProtection.Tests (4)
XmlEncryption\CertificateXmlEncryptionTests.cs (4)
26mockInternalEncryptor.Setup(o => o.PerformEncryption(It.IsAny<EncryptedXml>(), It.IsAny<XmlElement>())) 27.Returns<EncryptedXml, XmlElement>((encryptedXml, element) => 34mockInternalDecryptor.Setup(o => o.PerformPreDecryptionSetup(It.IsAny<EncryptedXml>())) 35.Callback<EncryptedXml>(encryptedXml =>
Microsoft.Extensions.Configuration.Xml (3)
XmlDocumentDecryptor.cs (3)
26private readonly Func<XmlDocument, EncryptedXml>? _encryptedXmlFactory; 38internal XmlDocumentDecryptor(Func<XmlDocument, EncryptedXml> encryptedXmlFactory) 111EncryptedXml encryptedXml = _encryptedXmlFactory?.Invoke(document) ?? new EncryptedXml(document);
System.Security (1)
System.Security.cs (1)
48[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Security.Cryptography.Xml.EncryptedXml))]
System.Security.Cryptography.Xml (68)
System\Security\Cryptography\Xml\CipherData.cs (3)
80XmlElement cipherDataElement = (XmlElement)document.CreateElement("CipherData", EncryptedXml.XmlEncNamespaceUrl); 83XmlElement cipherValueElement = document.CreateElement("CipherValue", EncryptedXml.XmlEncNamespaceUrl); 104nsm.AddNamespace("enc", EncryptedXml.XmlEncNamespaceUrl);
System\Security\Cryptography\Xml\CipherReference.cs (4)
58XmlElement referenceElement = document.CreateElement(ReferenceType, EncryptedXml.XmlEncNamespaceUrl); 64referenceElement.AppendChild(TransformChain.GetXml(document, EncryptedXml.XmlEncNamespaceUrl)); 76string? uri = Utils.GetAttribute(value, "URI", EncryptedXml.XmlEncNamespaceUrl); 81nsm.AddNamespace("enc", EncryptedXml.XmlEncNamespaceUrl);
System\Security\Cryptography\Xml\EncryptedData.cs (7)
21nsm.AddNamespace("enc", EncryptedXml.XmlEncNamespaceUrl); 24Id = Utils.GetAttribute(value, "Id", EncryptedXml.XmlEncNamespaceUrl); 25Type = Utils.GetAttribute(value, "Type", EncryptedXml.XmlEncNamespaceUrl); 26MimeType = Utils.GetAttribute(value, "MimeType", EncryptedXml.XmlEncNamespaceUrl); 27Encoding = Utils.GetAttribute(value, "Encoding", EncryptedXml.XmlEncNamespaceUrl); 88XmlElement encryptedDataElement = (XmlElement)document.CreateElement("EncryptedData", EncryptedXml.XmlEncNamespaceUrl); 116XmlElement encryptionPropertiesElement = document.CreateElement("EncryptionProperties", EncryptedXml.XmlEncNamespaceUrl);
System\Security\Cryptography\Xml\EncryptedKey.cs (10)
56nsm.AddNamespace("enc", EncryptedXml.XmlEncNamespaceUrl); 59Id = Utils.GetAttribute(value, "Id", EncryptedXml.XmlEncNamespaceUrl); 60Type = Utils.GetAttribute(value, "Type", EncryptedXml.XmlEncNamespaceUrl); 61MimeType = Utils.GetAttribute(value, "MimeType", EncryptedXml.XmlEncNamespaceUrl); 62Encoding = Utils.GetAttribute(value, "Encoding", EncryptedXml.XmlEncNamespaceUrl); 63Recipient = Utils.GetAttribute(value, "Recipient", EncryptedXml.XmlEncNamespaceUrl); 159XmlElement encryptedKeyElement = (XmlElement)document.CreateElement("EncryptedKey", EncryptedXml.XmlEncNamespaceUrl); 189XmlElement encryptionPropertiesElement = document.CreateElement("EncryptionProperties", EncryptedXml.XmlEncNamespaceUrl); 201XmlElement referenceListElement = document.CreateElement("ReferenceList", EncryptedXml.XmlEncNamespaceUrl); 212XmlElement carriedKeyNameElement = (XmlElement)document.CreateElement("CarriedKeyName", EncryptedXml.XmlEncNamespaceUrl);
System\Security\Cryptography\Xml\EncryptedReference.cs (2)
93XmlElement referenceElement = document.CreateElement(ReferenceType, EncryptedXml.XmlEncNamespaceUrl); 112string? uri = Utils.GetAttribute(value, "URI", EncryptedXml.XmlEncNamespaceUrl);
System\Security\Cryptography\Xml\EncryptedXml.cs (26)
306case EncryptedXml.XmlEncDESUrl: 307case EncryptedXml.XmlEncTripleDESUrl: 310case EncryptedXml.XmlEncAES128Url: 311case EncryptedXml.XmlEncAES192Url: 312case EncryptedXml.XmlEncAES256Url: 352nsm.AddNamespace("enc", EncryptedXml.XmlEncNamespaceUrl); 446return EncryptedXml.DecryptKey(encryptedKey.CipherData.CipherValue, (SymmetricAlgorithm)kek); 449fOAEP = (encryptedKey.EncryptionMethod != null && encryptedKey.EncryptionMethod.KeyAlgorithm == EncryptedXml.XmlEncRSAOAEPUrl); 450return EncryptedXml.DecryptKey(encryptedKey.CipherData.CipherValue, (RSA)kek, fOAEP); 468fOAEP = (encryptedKey.EncryptionMethod != null && encryptedKey.EncryptionMethod.KeyAlgorithm == EncryptedXml.XmlEncRSAOAEPUrl); 469return EncryptedXml.DecryptKey(encryptedKey.CipherData.CipherValue, privateKey, fOAEP); 521return EncryptedXml.DecryptKey(encryptedKey.CipherData.CipherValue, symAlg); 565ed.Type = EncryptedXml.XmlEncElementUrl; 566ed.EncryptionMethod = new EncryptionMethod(EncryptedXml.XmlEncAES256Url); 570ek.EncryptionMethod = new EncryptionMethod(EncryptedXml.XmlEncRSA15Url); 576ek.CipherData.CipherValue = EncryptedXml.EncryptKey(aes.Key, rsaPublicKey, false); 611ed.Type = EncryptedXml.XmlEncElementUrl; 612ed.EncryptionMethod = new EncryptionMethod(EncryptedXml.XmlEncAES256Url); 618encryptionMethod = EncryptedXml.XmlEncRSA15Url; 623encryptionMethod = EncryptedXml.XmlEncTripleDESKeyWrapUrl; 633encryptionMethod = EncryptedXml.XmlEncAES128KeyWrapUrl; 636encryptionMethod = EncryptedXml.XmlEncAES192KeyWrapUrl; 639encryptionMethod = EncryptedXml.XmlEncAES256KeyWrapUrl; 655ek.CipherData.CipherValue = (symKey == null ? EncryptedXml.EncryptKey(aes.Key, rsa, false) : EncryptedXml.EncryptKey(aes.Key, symKey)); 675nsm.AddNamespace("enc", EncryptedXml.XmlEncNamespaceUrl);
System\Security\Cryptography\Xml\EncryptionMethod.cs (4)
69XmlElement encryptionMethodElement = (XmlElement)document.CreateElement("EncryptionMethod", EncryptedXml.XmlEncNamespaceUrl); 75XmlElement keySizeElement = document.CreateElement("KeySize", EncryptedXml.XmlEncNamespaceUrl); 87nsm.AddNamespace("enc", EncryptedXml.XmlEncNamespaceUrl); 90_algorithm = Utils.GetAttribute(encryptionMethodElement, "Algorithm", EncryptedXml.XmlEncNamespaceUrl);
System\Security\Cryptography\Xml\EncryptionProperty.cs (5)
23if (elementProperty.LocalName != "EncryptionProperty" || elementProperty.NamespaceURI != EncryptedXml.XmlEncNamespaceUrl) 48if (value.LocalName != "EncryptionProperty" || value.NamespaceURI != EncryptedXml.XmlEncNamespaceUrl) 83if (value.LocalName != "EncryptionProperty" || value.NamespaceURI != EncryptedXml.XmlEncNamespaceUrl) 88_id = Utils.GetAttribute(value, "Id", EncryptedXml.XmlEncNamespaceUrl); 89_target = Utils.GetAttribute(value, "Target", EncryptedXml.XmlEncNamespaceUrl);
System\Security\Cryptography\Xml\SignedXml.cs (1)
173public EncryptedXml EncryptedXml
System\Security\Cryptography\Xml\XmlDecryptionTransform.cs (5)
23private EncryptedXml? _exml; // defines the XML encryption processing rules 51public EncryptedXml EncryptedXml 156_nsm.AddNamespace("enc", EncryptedXml.XmlEncNamespaceUrl); 167_nsm.AddNamespace("enc", EncryptedXml.XmlEncNamespaceUrl); 233encryptedDataElement.NamespaceURI == EncryptedXml.XmlEncNamespaceUrl)
System\Security\Cryptography\Xml\XmlLicenseTransform.cs (1)
139_namespaceManager.AddNamespace("enc", EncryptedXml.XmlEncNamespaceUrl);
System.ServiceModel.Primitives (6)
System\IdentityModel\Tokens\X509AsymmetricSecurityKey.cs (6)
144case EncryptedXml.XmlEncRSA15Url: 145case EncryptedXml.XmlEncRSAOAEPUrl: 174case EncryptedXml.XmlEncRSA15Url: 175case EncryptedXml.XmlEncRSAOAEPUrl: 435case EncryptedXml.XmlEncRSA15Url: 436case EncryptedXml.XmlEncRSAOAEPUrl: