using System; using System.IO; using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1; using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Cms; using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509; using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto; using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Parameters; using BestHTTP.SecureProtocol.Org.BouncyCastle.Security; using Cpp2IlInjected; namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Cms { // Token: 0x02001E43 RID: 7747 [Token(Token = "0x2001E43")] public class PasswordRecipientInformation : RecipientInformation { // Token: 0x0600C252 RID: 49746 RVA: 0x002BF150 File Offset: 0x002BD350 [Token(Token = "0x600C252")] [Address(RVA = "0x29339C0", Offset = "0x29329C0", VA = "0x1829339C0")] internal PasswordRecipientInformation(PasswordRecipientInfo info, CmsSecureReadable secureReadable) { AlgorithmIdentifier keyEncryptionAlgorithm = info.keyEncryptionAlgorithm; base..ctor(keyEncryptionAlgorithm, secureReadable); this.info = info; RecipientID recipientID = new RecipientID(); this.rid = recipientID; } // Token: 0x17001E1C RID: 7708 // (get) Token: 0x0600C253 RID: 49747 RVA: 0x002BF188 File Offset: 0x002BD388 [Token(Token = "0x17001E1C")] public virtual AlgorithmIdentifier KeyDerivationAlgorithm { [Token(Token = "0x600C253")] [Address(RVA = "0xADAD30", Offset = "0xAD9D30", VA = "0x180ADAD30", Slot = "5")] get { return this.info.keyDerivationAlgorithm; } } // Token: 0x0600C254 RID: 49748 RVA: 0x002BF1A8 File Offset: 0x002BD3A8 [Token(Token = "0x600C254")] [Address(RVA = "0x2933590", Offset = "0x2932590", VA = "0x182933590", Slot = "4")] public override CmsTypedStream GetContentStream(ICipherParameters key) { DerObjectIdentifier objectID = AlgorithmIdentifier.GetInstance(this.info.keyEncryptionAlgorithm).ObjectID; Stream octetStream = this.info.encryptedKey.GetOctetStream(); if (objectID == 0) { throw new NullReferenceException(); } DerObjectIdentifier derObjectIdentifier; string identifier = derObjectIdentifier.identifier; CmsEnvelopedHelper instance = CmsEnvelopedHelper.Instance; IWrapper wrapper = WrapperUtilities.GetWrapper(instance.GetRfc3211WrapperName(identifier)); Asn1OctetString asn1OctetString; Stream octetStream2 = asn1OctetString.GetOctetStream(); if (key != 0 && key != 0) { string contentAlgorithmName = base.GetContentAlgorithmName(); AlgorithmIdentifier keyEncAlg = this.keyEncAlg; KeyParameter keyParameter; return base.GetContentFromSessionKey(keyParameter); } throw new NullReferenceException(); } // Token: 0x04007AE9 RID: 31465 [FieldOffset(Offset = "0x30")] [Token(Token = "0x4007AE9")] private readonly PasswordRecipientInfo info; } }