private bool HasCryptoModeChanged(RMSTrustedPublishingDomain oldDefaultTPD, string newSlcCertChainCompressed)
        {
            XrmlCertificateChain xrmlCertificateChain  = RMUtil.DecompressSLCCertificate(oldDefaultTPD.SLCCertChain);
            XrmlCertificateChain xrmlCertificateChain2 = RMUtil.DecompressSLCCertificate(newSlcCertChainCompressed);

            return(xrmlCertificateChain.GetCryptoMode() != xrmlCertificateChain2.GetCryptoMode());
        }
Exemplo n.º 2
0
        private static int CryptoModeFromTpd(TrustedDocDomain tpd)
        {
            string compressedCerts = RMUtil.CompressSLCCertificateChain(tpd.m_strLicensorCertChain);
            XrmlCertificateChain xrmlCertificateChain = RMUtil.DecompressSLCCertificate(compressedCerts);

            return(xrmlCertificateChain.GetCryptoMode());
        }
Exemplo n.º 3
0
        private static object CryptoModeGetter(IPropertyBag propertyBag)
        {
            string text = (string)propertyBag[RMSTrustedPublishingDomainSchema.SLCCertChain];

            if (!string.IsNullOrEmpty(text))
            {
                XrmlCertificateChain xrmlCertificateChain = RMUtil.DecompressSLCCertificate(text);
                return(xrmlCertificateChain.GetCryptoMode());
            }
            return(RMSTrustedPublishingDomainSchema.CryptoMode.DefaultValue);
        }
        private static int CryptoModeFromCompressedSLC(string compressedSLCCertChain)
        {
            XrmlCertificateChain xrmlCertificateChain = RMUtil.DecompressSLCCertificate(compressedSLCCertChain);

            return(xrmlCertificateChain.GetCryptoMode());
        }