public void WritePacket(PacketWriter writer)
 {
     writer.WriteInt32((int)FailureReason);
     if (Fingerprint != null)
         writer.WriteString(Fingerprint.ToJson());
     else
         writer.WriteString(null);
     writer.WriteString(HostName);
     writer.WriteString(AssetsRootUrl);
     writer.WriteString(iTunesUrl);
     writer.WriteString(Unknown1);
     writer.WriteInt32(RemainingTime);
     writer.WriteByte(Unknown2);
     writer.WriteByteArray(CompressedFingerprintJson);
     writer.WriteString(Unknown3);
     writer.WriteString(Unknown4);
     File.WriteAllBytes("dump", ((MemoryStream)writer.BaseStream).ToArray());
 }