// Decompiled with JetBrains decompiler
// Type: Sixxpack.Compressor
// Assembly: actmp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
// MVID: 50C41484-D1A9-4872-9CEC-A8081495D24E
// Assembly location: C:\Users\Administrateur\Downloads\Virusshare-00001-msil\Trojan-Dropper.MSIL.Late.jc-6e02b71a709e42516d7a14e4e52d08479b8d86674e6e6992da3654142ae73613.exe

using SevenZip;
using SevenZip.Compression.LZMA;
using System;
using System.IO;

namespace Sixxpack
{
  internal class Compressor
  {
    public byte[] Decompress(Stream inStream)
    {
      MemoryStream outStream = new MemoryStream();
      byte[] numArray = new byte[5];
      if (inStream.Read(numArray, 0, 5) != 5)
        throw new Exception("Err");
      Decoder decoder = new Decoder();
      decoder.SetDecoderProperties(numArray);
      long outSize = 0;
      for (int index = 0; index < 8; ++index)
      {
        int num = inStream.ReadByte();
        if (num < 0)
          throw new Exception("Err");
        outSize |= (long) (byte) num << 8 * index;
      }
      long inSize = inStream.Length - inStream.Position;
      decoder.Code(inStream, (Stream) outStream, inSize, outSize, (ICodeProgress) null);
      return outStream.ToArray();
    }
  }
}
