Files
2026-04-08 23:40:05 +02:00

129 lines
2.9 KiB
C#

using System;
using System.IO;
using System.Runtime.InteropServices;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.IO;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1
{
// Token: 0x020017BA RID: 6074
[Token(Token = "0x20017BA")]
[StructLayout(3)]
internal class ConstructedOctetStream : BaseInputStream
{
// Token: 0x0600A3CF RID: 41935 RVA: 0x00261E8C File Offset: 0x0026008C
[Token(Token = "0x600A3CF")]
[Address(RVA = "0x1ECCF80", Offset = "0x1ECB980", VA = "0x181ECCF80")]
internal ConstructedOctetStream(Asn1StreamParser parser)
{
this._parser = parser;
}
// Token: 0x0600A3D0 RID: 41936 RVA: 0x00261EB0 File Offset: 0x002600B0
[Token(Token = "0x600A3D0")]
[Address(RVA = "0x1ECCD50", Offset = "0x1ECB750", VA = "0x181ECCD50", Slot = "27")]
public override int Read(byte[] buffer, int offset, int count)
{
string text2;
do
{
if (this._currentStream == (ulong)0L)
{
if (!this._first)
{
return 0;
}
string text = this._parser.ToString();
if (text == 0)
{
return 0;
}
if (text == 0)
{
continue;
}
this._first = false;
this._currentStream = text;
}
Stream currentStream = this._currentStream;
text2 = this._parser.ToString();
if (text2 == 0)
{
goto IL_79;
}
}
while (text2 == 0);
int num = 0;
if (num < 0)
{
num += num;
num++;
}
this._currentStream = text2;
return 0;
IL_79:
this._currentStream = 0;
throw new NullReferenceException();
}
// Token: 0x0600A3D1 RID: 41937 RVA: 0x00261F44 File Offset: 0x00260144
[Token(Token = "0x600A3D1")]
[Address(RVA = "0x1ECCB70", Offset = "0x1ECB570", VA = "0x181ECCB70", Slot = "28")]
public override int ReadByte()
{
int num;
string text2;
do
{
Stream currentStream = this._currentStream;
if (currentStream == 0)
{
if (this._first == currentStream)
{
return 0;
}
string text = this._parser.ToString();
if (text == 0)
{
return 0;
}
if (text == 0)
{
continue;
}
this._currentStream = text;
}
num = 0;
text2 = this._parser.ToString();
if (text2 == 0)
{
goto IL_65;
}
}
while (text2 == 0);
num += num;
num++;
this._currentStream = text2;
return 0;
IL_65:
this._currentStream = 0;
throw new NullReferenceException();
}
// Token: 0x04006B55 RID: 27477
[global::Cpp2IlInjected.FieldOffset(Offset = "0x30")]
[Token(Token = "0x4006B55")]
private readonly Asn1StreamParser _parser;
// Token: 0x04006B56 RID: 27478
[global::Cpp2IlInjected.FieldOffset(Offset = "0x38")]
[Token(Token = "0x4006B56")]
private bool _first = true;
// Token: 0x04006B57 RID: 27479
[global::Cpp2IlInjected.FieldOffset(Offset = "0x40")]
[Token(Token = "0x4006B57")]
private Stream _currentStream;
}
}