// Token: 0x060029ED RID: 10733 RVA: 0x000A0F8C File Offset: 0x0009F18C
        private bool method_15(Class145.Class146 data, string requestedFile, out string response)
        {
            response = null;
            Uri    uri      = new Uri(new Uri("http://" + ((IPEndPoint)data.socket_0.LocalEndPoint).Address.ToString()), requestedFile);
            string fileName = Path.GetFileName(uri.LocalPath);

            if (fileName != Class145.string_2)
            {
                return(false);
            }
            StringBuilder stringBuilder = new StringBuilder();

            stringBuilder.Append("HTTP/1.1 200 OK\r\n");
            stringBuilder.Append(string.Format("Date: {0:r}\r\n", DateTime.UtcNow));
            stringBuilder.Append(string.Format("Last-Modified: {0:r}\r\n", DateTime.UtcNow));
            stringBuilder.Append("Apache/2.2.3 (Red Hat)\r\n");
            stringBuilder.Append("Connection: close\r\n");
            stringBuilder.Append("Content-Type: text/plain; charset=ISO-8859-1\r\n");
            string text = this.class96_0.method_10(this.PANDA_DOWNLOAD_URL);

            stringBuilder.Append(string.Format("Content-Length: {0}\r\n", text.Length));
            stringBuilder.Append("\r\n");
            stringBuilder.Append(text);
            response = stringBuilder.ToString();
            return(true);
        }
 // Token: 0x060029EB RID: 10731 RVA: 0x000A0E5C File Offset: 0x0009F05C
 private void method_14(IAsyncResult result)
 {
     Class145.Class146 @class = result.AsyncState as Class145.Class146;
     lock (this.object_0)
     {
         @class.int_1 += @class.socket_0.EndSend(result);
     }
     this.method_13(@class);
 }
 // Token: 0x060029E9 RID: 10729 RVA: 0x000A0D7C File Offset: 0x0009EF7C
 private static void smethod_0(IAsyncResult ar)
 {
     try
     {
         Class145.Class146 @class = ar.AsyncState as Class145.Class146;
         @class.socket_0.EndDisconnect(ar);
         @class.Dispose();
     }
     catch (Exception ex)
     {
         ex.smethod_0();
     }
 }
 // Token: 0x060029E5 RID: 10725 RVA: 0x000A0AFC File Offset: 0x0009ECFC
 private void method_9(Class145.Class146 data)
 {
     try
     {
         data.dateTime_0 = DateTime.Now;
         data.socket_0.BeginReceive(data.byte_0, 0, Class145.Class146.int_0, SocketFlags.None, new AsyncCallback(this.method_10), data);
     }
     catch (Exception ex)
     {
         ex.smethod_0();
         this.method_12(data);
     }
 }
        // Token: 0x060029E4 RID: 10724 RVA: 0x000A09D8 File Offset: 0x0009EBD8
        private void method_8(IAsyncResult ar)
        {
            Socket socket = null;

            try
            {
                socket = this.tcpListener_0.EndAcceptSocket(ar);
            }
            catch (ObjectDisposedException)
            {
                if (base.IsDisposed || base.IsDisposing || !this.bool_2)
                {
                    return;
                }
            }
            Class145.Class146 @class = null;
            try
            {
                @class = new Class145.Class146(socket);
                lock (this.object_0)
                {
                    this.list_0.Add(@class);
                }
                if (Class145.smethod_2(((IPEndPoint)socket.RemoteEndPoint).Address))
                {
                    this.method_9(@class);
                }
                else
                {
                    this.method_12(@class);
                }
            }
            catch (Exception ex)
            {
                ex.smethod_0();
                if (@class != null)
                {
                    this.method_12(@class);
                }
            }
            this.method_7();
            lock (this.object_0)
            {
                if (!this.timer_0.Enabled)
                {
                    this.timer_0.Enabled = true;
                }
            }
        }
 // Token: 0x060029EA RID: 10730 RVA: 0x000A0DC4 File Offset: 0x0009EFC4
 private void method_13(Class145.Class146 data)
 {
     lock (this.object_0)
     {
         int num = data.byte_0.Length - data.int_1;
         data.dateTime_0 = DateTime.Now;
         if (num > 0)
         {
             data.socket_0.BeginSend(data.byte_0, data.int_1, (num > Class145.Class146.int_0) ? Class145.Class146.int_0 : num, SocketFlags.None, new AsyncCallback(this.method_14), data);
         }
         else
         {
             this.method_12(data);
         }
     }
 }
 // Token: 0x060029E8 RID: 10728 RVA: 0x000A0D18 File Offset: 0x0009EF18
 private void method_12(Class145.Class146 data)
 {
     this.method_4(data);
     try
     {
         if (data.socket_0.Connected)
         {
             data.socket_0.BeginDisconnect(false, new AsyncCallback(Class145.smethod_0), data);
         }
         else
         {
             data.Dispose();
         }
     }
     catch (Exception ex)
     {
         ex.smethod_0();
         data.Dispose();
     }
 }
 // Token: 0x060029DF RID: 10719 RVA: 0x000A0748 File Offset: 0x0009E948
 private void method_4(Class145.Class146 data)
 {
     try
     {
         lock (this.object_0)
         {
             if (this.list_0.Contains(data))
             {
                 this.list_0.Remove(data);
             }
             if (this.list_0.Count == 0)
             {
                 this.timer_0.Enabled = false;
             }
         }
     }
     catch (Exception ex)
     {
         ex.smethod_0();
     }
 }
 // Token: 0x060029E6 RID: 10726 RVA: 0x000A0B5C File Offset: 0x0009ED5C
 private void method_10(IAsyncResult ar)
 {
     Class145.Class146 @class = ar.AsyncState as Class145.Class146;
     if ([email protected] && [email protected])
     {
         lock (this.object_0)
         {
             try
             {
                 int num = @class.socket_0.EndReceive(ar);
                 if (@class.socket_0.Connected)
                 {
                     if (num > 0)
                     {
                         @class.stringBuilder_0.Append(Encoding.ASCII.GetString(@class.byte_0, 0, num));
                         if (@class.stringBuilder_0.Length <= 8190)
                         {
                             string text = @class.stringBuilder_0.ToString();
                             if (text.EndsWith("\r\n\r\n"))
                             {
                                 string requestedFile;
                                 string s;
                                 if (Class145.smethod_1(text, out requestedFile) && this.method_15(@class, requestedFile, out s))
                                 {
                                     @class.byte_0 = Encoding.ASCII.GetBytes(s);
                                     this.method_13(@class);
                                 }
                                 else
                                 {
                                     this.method_12(@class);
                                 }
                             }
                             else
                             {
                                 this.method_9(@class);
                             }
                         }
                         else
                         {
                             this.method_12(@class);
                         }
                     }
                     else
                     {
                         this.method_12(@class);
                     }
                 }
                 else
                 {
                     this.method_4(@class);
                     @class.Dispose();
                 }
             }
             catch (Exception ex)
             {
                 this.method_4(@class);
                 @class.Dispose();
                 ex.smethod_0();
             }
         }
         return;
     }
 }