terraria-cpp2il-methodrecon v1.4.4.9
Terraria mobile dump, with reconstructed method body. Dump with CallAnalysis: https://infinitynichto.github.io/terraria-cpp2il
Loading...
Searching...
No Matches
AuthenticodeBase.cs
Go to the documentation of this file.
1using System;
2using System.IO;
4
6{
7 // Token: 0x0200005F RID: 95
8 public class AuthenticodeBase
9 {
10 // Token: 0x06000296 RID: 662 RVA: 0x0000A734 File Offset: 0x00008934
12 {
13 }
14
15 // Token: 0x170000BC RID: 188
16 // (get) Token: 0x06000297 RID: 663 RVA: 0x0000A748 File Offset: 0x00008948
17 internal int PEOffset
18 {
19 get
20 {
21 int num = this.blockNo;
22 this.ReadFirstBlock();
23 return this.peOffset;
24 }
25 }
26
27 // Token: 0x06000298 RID: 664 RVA: 0x0000A768 File Offset: 0x00008968
28 internal void Open(string filename)
29 {
30 if (this.fs != null)
31 {
32 }
33 }
34
35 // Token: 0x06000299 RID: 665 RVA: 0x0000A780 File Offset: 0x00008980
36 internal void Open(byte[] rawdata)
37 {
38 }
39
40 // Token: 0x0600029A RID: 666 RVA: 0x0000A790 File Offset: 0x00008990
41 internal void Close()
42 {
43 if (this.fs != null)
44 {
45 }
46 }
47
48 // Token: 0x0600029B RID: 667 RVA: 0x0000A7A8 File Offset: 0x000089A8
49 internal void ReadFirstBlock()
50 {
51 if (this.ProcessFirstBlock() == 0)
52 {
53 return;
54 }
56 }
57
58 // Token: 0x0600029C RID: 668 RVA: 0x0000A7C4 File Offset: 0x000089C4
59 internal int ProcessFirstBlock()
60 {
61 Stream stream;
62 int num;
63 do
64 {
65 stream = this.fs;
66 num = 1;
67 }
68 while (stream == null);
69 byte[] array = this.fileblock;
70 Stream stream2 = this.fs;
71 this.blockNo = num;
73 byte[] array2 = this.fileblock;
74 long num2 = 0L;
75 ushort num3 = BitConverterLE.ToUInt16(array2, (int)num2);
76 byte[] array3 = this.fileblock;
77 int num4 = 60;
79 byte[] array4 = this.fileblock;
81 Stream stream3 = this.fs;
82 return 3;
83 }
84
85 // Token: 0x0600029D RID: 669 RVA: 0x0000A8F8 File Offset: 0x00008AF8
86 internal byte[] GetSecurityEntry()
87 {
88 /*
89An exception occurred when decompiling this method (0600029D)
90
91ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Byte[] Mono.Security.Authenticode.AuthenticodeBase::GetSecurityEntry()
92
93 ---> System.Exception: Basic block has to end with unconditional control flow.
94{
95 Block_0:
96 stloc:int32(var_0_06, ldfld:int32(AuthenticodeBase::blockNo, ldloc:AuthenticodeBase(this)))
97 call:void(AuthenticodeBase::ReadFirstBlock, ldloc:AuthenticodeBase(this))
98 stloc:int32(var_1_13, ldfld:int32(AuthenticodeBase::dirSecuritySize, ldloc:AuthenticodeBase(this)))
99 stloc:Stream(var_2_1A, ldfld:Stream(AuthenticodeBase::fs, ldloc:AuthenticodeBase(this)))
100 stloc:int32(var_3_21, ldfld:int32(AuthenticodeBase::dirSecurityOffset, ldloc:AuthenticodeBase(this)))
101 stloc:Stream(var_4_28, ldfld:Stream(AuthenticodeBase::fs, ldloc:AuthenticodeBase(this)))
102}
103
104 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
105 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
106 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
107 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
108 --- End of inner exception stack trace ---
109 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
110 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 1683
111*/;
112 }
113
114 // Token: 0x0600029E RID: 670 RVA: 0x0000A934 File Offset: 0x00008B34
115 internal byte[] GetHash(HashAlgorithm hash)
116 {
117 /*
118An exception occurred when decompiling this method (0600029E)
119
120ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Byte[] Mono.Security.Authenticode.AuthenticodeBase::GetHash(System.Security.Cryptography.HashAlgorithm)
121
122 ---> System.Exception: Basic block has to end with unconditional control flow.
123{
124 Block_0:
125 stloc:uint8[](var_43_17D, ldfld:uint8[](AuthenticodeBase::fileblock, ldloc:AuthenticodeBase(this)))
126 stloc:Stream(var_44_185, ldfld:Stream(AuthenticodeBase::fs, ldloc:AuthenticodeBase(this)))
127 stloc:uint8[](var_45_18D, ldfld:uint8[](AuthenticodeBase::fileblock, ldloc:AuthenticodeBase(this)))
128 stloc:uint8[](var_47_195, ldfld:uint8[](AuthenticodeBase::fileblock, ldloc:AuthenticodeBase(this)))
129 stloc:Stream(var_48_19D, ldfld:Stream(AuthenticodeBase::fs, ldloc:AuthenticodeBase(this)))
130 stloc:uint8[](var_49_1A5, ldfld:uint8[](AuthenticodeBase::fileblock, ldloc:AuthenticodeBase(this)))
131 stloc:int64(var_50_1A8, ldc.i4:int64(0))
132 stloc:int64(var_51_1AB, ldc.i4:int64(0))
133 stloc:int32(var_52_1BD, call:int32(HashAlgorithm::TransformBlock, ldloc:HashAlgorithm(hash), ldloc:uint8[](var_49_1A5), ldloc:int64[exp:int32](var_50_1A8), ldloc:int64[exp:int32](var_31_126), ldloc:uint8[](var_49_1A5), ldloc:int64[exp:int32](var_51_1AB)))
134}
135
136 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
137 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
138 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
139 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
140 --- End of inner exception stack trace ---
141 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
142 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 1683
143*/;
144 }
145
146 // Token: 0x0400027A RID: 634
147 private byte[] fileblock;
148
149 // Token: 0x0400027B RID: 635
150 private Stream fs;
151
152 // Token: 0x0400027C RID: 636
153 private int blockNo;
154
155 // Token: 0x0400027D RID: 637
156 private int blockLength;
157
158 // Token: 0x0400027E RID: 638
159 private int peOffset;
160
161 // Token: 0x0400027F RID: 639
162 private int dirSecurityOffset;
163
164 // Token: 0x04000280 RID: 640
165 private int dirSecuritySize;
166
167 // Token: 0x04000281 RID: 641
169
170 // Token: 0x04000282 RID: 642
171 private bool pe64;
172 }
173}
class f__AnonymousType0<< Count > j__TPar
static int ToInt32(byte[] value, int startIndex)
static ushort ToUInt16(byte[] value, int startIndex)