Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dDRYh-0001Go-Ag for pgadmin-hackers@arkaria.postgresql.org; Wed, 24 May 2017 08:22:19 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1dDRYf-0006p2-Uy for pgadmin-hackers@arkaria.postgresql.org; Wed, 24 May 2017 08:22:17 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dDRYf-0006oX-1f for pgadmin-hackers@postgresql.org; Wed, 24 May 2017 08:22:17 +0000 Received: from mail-pg0-x236.google.com ([2607:f8b0:400e:c05::236]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84_2) (envelope-from ) id 1dDRYZ-0003OC-GP for pgadmin-hackers@postgresql.org; Wed, 24 May 2017 08:22:16 +0000 Received: by mail-pg0-x236.google.com with SMTP id u28so62293945pgn.1 for ; Wed, 24 May 2017 01:22:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=enterprisedb-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=wfOOwcljoXcVIhRgOp89KNOT1qKH52lph0/Tcqye8a0=; b=DQw4H4dCtCTk8PrVWJ9V0+p1EeJlglRK69glxWb63P15ajtmj0sWEU8DepIHMzANhr pJ7bNhqWkmATS7I7A9TaUG5wLv0PqHKV1wc+5zC0kIlqK/pz9yBJV4ispd54b3Vz9cRX ssVPGPjiRAhVKWNJg+BPqSTdUU42zOxCkJJlKzwkt+ZWGat+DbHabKEKdb8j/gzETkT1 dKuunzmQBHAFNC2iAG6c6vvHeMDggW0azr/YC7Um042WyWM1eBEo5KSZkXYn61EJso27 Ksse8S+Hbokjs8ZeT8kAO8tynl8QD8vnQ7abPMWOZQzADecvnrq+Zayoz9z8xSZHjyUk RbsQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=wfOOwcljoXcVIhRgOp89KNOT1qKH52lph0/Tcqye8a0=; b=do7wzScH6WvIRMlQ5DLYWWLdSvAgjLO1ngzR8zGhdsfkMByv3aYAvwZF0Wd/9ncCwo ebJP+rIEw5kxRsRxwQDhHGW2x9RbYiQ10YlHDMHqapYv6sfIPxrTjVfKH0YJphfYpJbi 5HG12h56FN2tI/S/bkqzNBOyF1XpSVxRgRP2AuCaM2J/gEui7BGCL19bZYGT/MA8OXMr jbSX1Oew98mrfCDeGj/WR1XU/YuVMAQfqUOeLHFk2SmexuXsU6fKs1R07mDCI6YmaIW0 9zJ4Ckqqm7P1B/mZcLc2jksOvwamGVSZNp7o76Vaib2hCeAsde0Ol3tSzISft9vVVhrF bz5g== X-Gm-Message-State: AODbwcDn97K6CsJC4dj009WVpwUoSnNujKV8gKGS1tImN1m65f/TJsQW lDuhoJOF7HjrmFxH0erjW5HxCCXUNnBe X-Received: by 10.98.66.214 with SMTP id h83mr37267906pfd.182.1495614128727; Wed, 24 May 2017 01:22:08 -0700 (PDT) MIME-Version: 1.0 Received: by 10.100.134.79 with HTTP; Wed, 24 May 2017 01:22:07 -0700 (PDT) In-Reply-To: References: From: Neel Patel Date: Wed, 24 May 2017 13:52:07 +0530 Message-ID: Subject: Re: [pgAdmin4][runtime][patch]: RM#2398 - Proxy not bypassed for embedded server in runtime on Windows To: Dave Page , dp.maxime@gmail.com Cc: pgadmin-hackers Content-Type: multipart/mixed; boundary="94eb2c0c0bcedd91ca055040cc6a" X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgadmin-hackers Precedence: bulk Sender: pgadmin-hackers-owner@postgresql.org --94eb2c0c0bcedd91ca055040cc6a Content-Type: multipart/alternative; boundary="94eb2c0c0bcedd91c5055040cc68" --94eb2c0c0bcedd91c5055040cc68 Content-Type: text/plain; charset="UTF-8" Hi, After debugging the issue in windows, we came to know that "random port" generation logic in runtime is getting failed if we configured proxy server in windows. Below are the code where we are finding random free port and use with our URL "localhost:". Below code return "0" as port value so application is not able to start and it hangs on splash screen. Here, if we configured proxy server in windows then "bind" method always return false and gives message "Operation not permitted" but when we disable proxy server then below code gives valid random port number. QTcpSocket socket; socket.bind(0, QTcpSocket::ShareAddress); port = socket.localPort(); Same happens with Linux OS - when user defined "http_proxy" environment variable and run pgAdmin4 application then above code fails and gives "0" as random port number and application hangs on splash screen.