164 lines
6.5 KiB
C#
164 lines
6.5 KiB
C#
using System;
|
|
using System.IO;
|
|
using BestHTTP.SecureProtocol.Org.BouncyCastle.Math;
|
|
using Cpp2IlInjected;
|
|
|
|
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs
|
|
{
|
|
// Token: 0x02001F78 RID: 8056
|
|
[Token(Token = "0x2001F78")]
|
|
public class RC2CbcParameter : Asn1Encodable
|
|
{
|
|
// Token: 0x0600C9B8 RID: 51640 RVA: 0x002DBBB0 File Offset: 0x002D9DB0
|
|
[Token(Token = "0x600C9B8")]
|
|
[Address(RVA = "0x2F8B2B0", Offset = "0x2F8A2B0", VA = "0x182F8B2B0")]
|
|
public static RC2CbcParameter GetInstance(object obj)
|
|
{
|
|
/*
|
|
An exception occurred when decompiling this method (0600C9B8)
|
|
|
|
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs.RC2CbcParameter BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs.RC2CbcParameter::GetInstance(System.Object)
|
|
|
|
---> System.Exception: Basic block has to end with unconditional control flow.
|
|
{
|
|
IL_12:
|
|
stloc:string(var_3_18, call:string(Platform::GetTypeName, ldloc:object(obj)))
|
|
stloc:ArgumentException(var_4_2E, newobj:ArgumentException(ArgumentException::.ctor, call:string(string::Concat, ldstr:string("Unknown object in factory: "), ldloc:string(var_3_18)), ldstr:string("obj")))
|
|
}
|
|
|
|
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
|
|
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
|
|
at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
|
|
at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
|
|
--- End of inner exception stack trace ---
|
|
at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
|
|
at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1663
|
|
*/;
|
|
}
|
|
|
|
// Token: 0x0600C9B9 RID: 51641 RVA: 0x002DBBEC File Offset: 0x002D9DEC
|
|
[Token(Token = "0x600C9B9")]
|
|
[Address(RVA = "0x2F8B810", Offset = "0x2F8A810", VA = "0x182F8B810")]
|
|
public RC2CbcParameter(byte[] iv)
|
|
{
|
|
DerOctetString derOctetString = new DerOctetString(iv);
|
|
this.iv = derOctetString;
|
|
}
|
|
|
|
// Token: 0x0600C9BA RID: 51642 RVA: 0x002DBC10 File Offset: 0x002D9E10
|
|
[Token(Token = "0x600C9BA")]
|
|
[Address(RVA = "0x2F8B770", Offset = "0x2F8A770", VA = "0x182F8B770")]
|
|
public RC2CbcParameter(int parameterVersion, byte[] iv)
|
|
{
|
|
DerInteger derInteger = new DerInteger(parameterVersion);
|
|
this.version = derInteger;
|
|
DerOctetString derOctetString = new DerOctetString(iv);
|
|
this.iv = derOctetString;
|
|
}
|
|
|
|
// Token: 0x0600C9BB RID: 51643 RVA: 0x002DBC40 File Offset: 0x002D9E40
|
|
[Token(Token = "0x600C9BB")]
|
|
[Address(RVA = "0x2F8B5C0", Offset = "0x2F8A5C0", VA = "0x182F8B5C0")]
|
|
private RC2CbcParameter(Asn1Sequence seq)
|
|
{
|
|
Asn1SequenceParser parser3;
|
|
do
|
|
{
|
|
base..ctor();
|
|
Asn1Encodable asn1Encodable;
|
|
if (asn1Encodable != (ulong)1L)
|
|
{
|
|
Asn1SequenceParser parser = seq.Parser;
|
|
if (parser == 0)
|
|
{
|
|
}
|
|
if (parser == 0)
|
|
{
|
|
continue;
|
|
}
|
|
this.version = parser;
|
|
Asn1SequenceParser parser2 = seq.Parser;
|
|
if (parser2 == 0)
|
|
{
|
|
break;
|
|
}
|
|
if (parser2 == 0)
|
|
{
|
|
continue;
|
|
}
|
|
}
|
|
parser3 = seq.Parser;
|
|
if (parser3 == 0)
|
|
{
|
|
}
|
|
}
|
|
while (parser3 == 0);
|
|
this.iv = parser3;
|
|
}
|
|
|
|
// Token: 0x17001F59 RID: 8025
|
|
// (get) Token: 0x0600C9BC RID: 51644 RVA: 0x002DBCA8 File Offset: 0x002D9EA8
|
|
[Token(Token = "0x17001F59")]
|
|
public BigInteger RC2ParameterVersion
|
|
{
|
|
[Token(Token = "0x600C9BC")]
|
|
[Address(RVA = "0x2F8B880", Offset = "0x2F8A880", VA = "0x182F8B880")]
|
|
get
|
|
{
|
|
DerInteger derInteger = this.version;
|
|
if (derInteger == 0)
|
|
{
|
|
}
|
|
return derInteger.Value;
|
|
}
|
|
}
|
|
|
|
// Token: 0x0600C9BD RID: 51645 RVA: 0x002DBCC8 File Offset: 0x002D9EC8
|
|
[Token(Token = "0x600C9BD")]
|
|
[Address(RVA = "0x2F8B230", Offset = "0x2F8A230", VA = "0x182F8B230")]
|
|
public byte[] GetIV()
|
|
{
|
|
Stream octetStream = this.iv.GetOctetStream();
|
|
byte[] array;
|
|
return array;
|
|
}
|
|
|
|
// Token: 0x0600C9BE RID: 51646 RVA: 0x002DBCE8 File Offset: 0x002D9EE8
|
|
[Token(Token = "0x600C9BE")]
|
|
[Address(RVA = "0x2F8B420", Offset = "0x2F8A420", VA = "0x182F8B420", Slot = "5")]
|
|
public override Asn1Object ToAsn1Object()
|
|
{
|
|
Asn1EncodableVector asn1EncodableVector;
|
|
if (this.version != (ulong)0L)
|
|
{
|
|
Asn1Encodable[] array = new Asn1Encodable[1];
|
|
DerInteger derInteger = this.version;
|
|
if (derInteger != 0)
|
|
{
|
|
}
|
|
array[0] = derInteger;
|
|
asn1EncodableVector.Add(array);
|
|
}
|
|
Asn1Encodable[] array2 = new Asn1Encodable[1];
|
|
Asn1OctetString asn1OctetString = this.iv;
|
|
if (asn1OctetString != 0)
|
|
{
|
|
}
|
|
array2[0] = asn1OctetString;
|
|
asn1EncodableVector.Add(array2);
|
|
DerSequence derSequence = new DerSequence(asn1EncodableVector);
|
|
throw new NullReferenceException();
|
|
}
|
|
|
|
// Token: 0x04007F6C RID: 32620
|
|
[FieldOffset(Offset = "0x10")]
|
|
[Token(Token = "0x4007F6C")]
|
|
internal DerInteger version;
|
|
|
|
// Token: 0x04007F6D RID: 32621
|
|
[FieldOffset(Offset = "0x18")]
|
|
[Token(Token = "0x4007F6D")]
|
|
internal Asn1OctetString iv;
|
|
}
|
|
}
|