/// <summary>
            /// Initializes a new instance of the ExtensionRequestPacket class
            /// </summary>
            /// <param name="currentContext">Current HTTP Context in use</param>
            public ExtensionRequestPacket(HttpListenerContext currentContext)
            {
                packetContext = currentContext;

                if (string.Compare(packetContext.Request.HttpMethod, "get", StringComparison.OrdinalIgnoreCase) == 0)
                {
                    extensionPacketType = ChromeExtensionPacketType.Get;
                }
                else
                {
                    extensionPacketType = ChromeExtensionPacketType.Post;
                }

                DateTime            readTimeout = DateTime.Now.AddSeconds(10);
                HttpListenerRequest request     = packetContext.Request;
                int length = (int)request.ContentLength64;

                byte[] packetDataBuffer = new byte[length];
                int    totalBytesRead   = request.InputStream.Read(packetDataBuffer, 0, length);

                while (totalBytesRead < length && DateTime.Now <= readTimeout)
                {
                    totalBytesRead += request.InputStream.Read(packetDataBuffer, totalBytesRead, length - totalBytesRead);
                }

                content = Encoding.UTF8.GetString(packetDataBuffer);
            }
        /// <summary>
        /// Initializes a new instance of the ExtensionRequestPacket class
        /// </summary>
        /// <param name="currentContext">Current HTTP Context in use</param>
        public ExtensionRequestPacket(HttpListenerContext currentContext)
        {
            packetContext = currentContext;

            if (string.Compare(packetContext.Request.HttpMethod, "get", StringComparison.OrdinalIgnoreCase) == 0)
            {
                extensionPacketType = ChromeExtensionPacketType.Get;
            }
            else
            {
                extensionPacketType = ChromeExtensionPacketType.Post;
            }

            DateTime readTimeout = DateTime.Now.AddSeconds(10);
            HttpListenerRequest request = packetContext.Request;

            int length = (int)request.ContentLength64;
            byte[] packetDataBuffer = new byte[length];
            int totalBytesRead = 0;

            do
            {
                totalBytesRead += request.InputStream.Read(packetDataBuffer, totalBytesRead, length - totalBytesRead);
            }
            while (totalBytesRead < length && DateTime.Now <= readTimeout);

            content = Encoding.UTF8.GetString(packetDataBuffer);
        }