Exemple #1
0
    private byte[] method_11(byte[] A_0, int A_1, byte[] A_2, byte[] A_3)
    {
        byte[] buffer;
        int    length = A_0.Length;

        if ((length % A_1) != 0)
        {
            length = ((length / A_1) + 1) * A_1;
            buffer = this.class299_0.method_13(A_0, length, 0);
        }
        else
        {
            buffer = A_0;
        }
        byte[]   dst     = new byte[length];
        byte[]   buffer2 = new byte[A_1];
        byte[]   buffer3 = new byte[A_1];
        Class441 class2  = new Class441(Class441.KeySize.Bits128, A_2);

        for (int i = 0; i < length; i += A_1)
        {
            Buffer.BlockCopy(buffer, i, buffer2, 0, A_1);
            if (i == 0)
            {
                buffer2 = this.class299_0.method_14(buffer2, A_3);
            }
            else
            {
                buffer2 = this.class299_0.method_14(buffer2, buffer3);
            }
            class2.method_1(buffer2, buffer3);
            Buffer.BlockCopy(buffer3, 0, dst, i, A_1);
        }
        return(dst);
    }
Exemple #2
0
    private void method_9(Stream A_0, byte[] A_1, Stream A_2)
    {
        Class441 class2 = new Class441(Class441.KeySize.Bits128, A_1);

        byte[] buffer  = new byte[0x10];
        byte[] buffer2 = new byte[0x10];
        while (A_0.Read(buffer, 0, 0x10) > 0)
        {
            class2.method_1(buffer, buffer2);
            A_2.Write(buffer2, 0, 0x10);
        }
    }
Exemple #3
0
        private void method_23(Class441 page, byte[] data, int offset, int length)
        {
            if (this.stream_0.Position % 32L != 0L)
            {
                throw new Exception();
            }
            long position = this.stream_0.Position;

            page.Id           = (long)(this.list_1.Count + 1);
            page.StreamOffset = (ulong)(position - 1152L);
            this.stream_0.Write(data, offset, length);
            this.method_25(this.stream_0, (uint)(((ulong)(length + 32 - 1) & 18446744073709551584UL) - (ulong)length));
            page.Length = this.stream_0.Position - position;
            this.list_1.Add(page);
        }
Exemple #4
0
 // Token: 0x06001FD3 RID: 8147
 // RVA: 0x0001A06B File Offset: 0x0001826B
 public void method_0(Class441 class441_1)
 {
     if (class441_1 != this.class441_0)
     {
         class441_1.method_13();
     }
 }
    private byte[] method_5(byte[] A_0, int A_1, byte[] A_2, byte[] A_3, int A_4)
    {
        byte[] buffer5;
        int    length = A_0.Length;

        byte[] dst     = new byte[length];
        byte[] src     = new byte[A_1];
        byte[] buffer3 = new byte[A_1];
        byte[] buffer4 = new byte[A_1];
        int    num2    = this.class62_0.method_4().method_4().method_0().method_6();

        Class441.KeySize size = Class441.KeySize.Bits128;
        switch (num2)
        {
        case 0xc0:
            size = Class441.KeySize.Bits192;
            break;

        case 0x100:
            size = Class441.KeySize.Bits256;
            break;

        default:
            size = Class441.KeySize.Bits128;
            break;
        }
        Class441 class2    = new Class441(size, A_2);
        int      srcOffset = 0;

        if ((length % A_1) != 0)
        {
            length  = ((length / A_1) + 1) * A_1;
            buffer5 = this.class299_0.method_13(A_0, length, 0);
        }
        else
        {
            buffer5 = A_0;
        }
        while (srcOffset < length)
        {
            if (srcOffset == 0)
            {
                Buffer.BlockCopy(A_3, 0, buffer4, 0, A_1);
            }
            else
            {
                Buffer.BlockCopy(src, 0, buffer4, 0, A_1);
            }
            Buffer.BlockCopy(buffer5, srcOffset, src, 0, A_1);
            class2.method_2(src, buffer3);
            buffer3 = this.class299_0.method_14(buffer3, buffer4);
            Buffer.BlockCopy(buffer3, 0, dst, srcOffset, A_1);
            srcOffset += A_1;
        }
        if (dst.Length > A_4)
        {
            src = new byte[A_4];
            Buffer.BlockCopy(dst, 0, src, 0, A_4);
            dst = src;
        }
        return(dst);
    }
Exemple #6
0
        private void method_18()
        {
            this.class442_0.StreamOffset = 0UL;
            ulong pageSize = this.method_19(this.list_1.Count);
            long  num1     = (long)(this.list_1.Count + 1 + 2);

            if (pageSize <= 1024UL)
            {
                Class441 class441 = this.list_1[0];
                long     num2     = num1;
                long     num3     = num2 + 1L;
                class441.Id                     = num2;
                this.list_1[1].Id               = num3;
                this.class954_0.PagesMapId      = (ulong)this.list_1[0].Id;
                this.class954_0.PagesMapOffset  = this.list_1[0].StreamOffset;
                this.class954_0.PagesMap2Id     = (ulong)this.list_1[1].Id;
                this.class954_0.PagesMap2Offset = this.list_1[1].StreamOffset;
            }
            else
            {
                Class441 class441_1 = this.list_1[0];
                long     num2       = num1;
                long     num3       = num2 + 1L;
                long     num4       = -num2;
                class441_1.Id = num4;
                Class441 class441_2 = this.list_1[1];
                long     num5       = num3;
                long     num6       = num5 + 1L;
                long     num7       = -num5;
                class441_2.Id = num7;
                uint     num8       = (uint)(this.stream_0.Position - 1152L);
                Class442 class442_1 = new Class442();
                Class442 class442_2 = class442_1;
                long     num9       = num6;
                long     num10      = num9 + 1L;
                class442_2.Id           = num9;
                class442_1.StreamOffset = (ulong)(num8 - 1152U);
                this.list_1.Add((Class441)class442_1);
                Class442 class442_3 = new Class442();
                class442_3.Id           = num10;
                class442_3.StreamOffset = (ulong)((long)num8 + (long)pageSize - 1152L);
                this.list_1.Add((Class441)class442_3);
            }
            this.class954_0.PagesMaxId     = 0UL;
            this.class954_0.PageCount      = (ulong)(uint)this.list_1.Count;
            this.class954_0.PagesMapOffset = this.class442_0.StreamOffset;
            MemoryStream sectionStream = new MemoryStream();
            Class889     class889      = Class889.Create((Stream)sectionStream, this.dxfVersion_0, this.encoding_0);

            foreach (Class441 class441 in this.list_1)
            {
                if (class441 != null)
                {
                    class889.vmethod_13(class441.Length);
                    class889.vmethod_13(class441.Id);
                    if (class441.Id > (long)this.class954_0.PagesMaxId)
                    {
                        this.class954_0.PagesMaxId = (ulong)class441.Id;
                    }
                }
            }
            byte[] pageData;
            this.method_20(this.class442_0, sectionStream, this.class954_0.PagesMapCrcSeed, pageSize, out pageData);
            this.class442_0.Length = (long)pageData.Length;
            long id = this.class442_1.Id;

            this.class442_1.CopyFrom(this.class442_0);
            this.class442_1.Id           = id;
            this.class442_1.StreamOffset = 1024UL;
            this.stream_0.Position       = (long)this.class954_0.PagesMapOffset + 1152L;
            this.stream_0.Write(pageData, 0, pageData.Length);
            this.stream_0.Position = (long)this.class954_0.PagesMap2Offset + 1152L;
            this.stream_0.Write(pageData, 0, pageData.Length);
            this.class954_0.PagesMapDataRepeatCount  = this.class442_0.DataRepeatCount;
            this.class954_0.PagesMapSizeCompressed   = this.class442_0.CompressedSize;
            this.class954_0.PagesMapSizeDecompressed = this.class442_0.DecompressedSize;
            this.class954_0.PagesMapCrcCompressed    = this.class442_0.CompressedCrc;
            this.class954_0.PagesMapCrcDecompressed  = this.class442_0.DecompressedCrc;
        }
Exemple #7
0
    private byte[] method_8(byte[] A_0, byte[] A_1)
    {
        Class441 class2 = new Class441(Class441.KeySize.Bits128, A_1);

        return(this.class299_0.method_11(A_0, new Class299.Delegate2(class2.method_1), A_1.Length));
    }
 public abstract void Visit(Class441 c);
 public override void Visit(Class441 c) { }