scripts
This commit is contained in:
+76
@@ -0,0 +1,76 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Runtime.InteropServices;
|
||||
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: 0x02001786 RID: 6022
|
||||
[Token(Token = "0x2001786")]
|
||||
[StructLayout(3)]
|
||||
public class PasswordRecipientInformation : RecipientInformation
|
||||
{
|
||||
// Token: 0x0600A2AA RID: 41642 RVA: 0x0025E450 File Offset: 0x0025C650
|
||||
[Token(Token = "0x600A2AA")]
|
||||
[Address(RVA = "0x6623C0", Offset = "0x660DC0", VA = "0x1806623C0")]
|
||||
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: 0x1700197E RID: 6526
|
||||
// (get) Token: 0x0600A2AB RID: 41643 RVA: 0x0025E488 File Offset: 0x0025C688
|
||||
[Token(Token = "0x1700197E")]
|
||||
public virtual AlgorithmIdentifier KeyDerivationAlgorithm
|
||||
{
|
||||
[Token(Token = "0x600A2AB")]
|
||||
[Address(RVA = "0x610F90", Offset = "0x60F990", VA = "0x180610F90", Slot = "5")]
|
||||
get
|
||||
{
|
||||
return this.info.keyDerivationAlgorithm;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x0600A2AC RID: 41644 RVA: 0x0025E4A8 File Offset: 0x0025C6A8
|
||||
[Token(Token = "0x600A2AC")]
|
||||
[Address(RVA = "0x661F90", Offset = "0x660990", VA = "0x180661F90", 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: 0x04006AED RID: 27373
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x30")]
|
||||
[Token(Token = "0x4006AED")]
|
||||
private readonly PasswordRecipientInfo info;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user