title: Java Jarsigner does not use provided Proxy
body: <p>I cannot get Jarsigner to use HTTPS Proxy. For my system I have configured the http &amp; https proxy in /etc/sysconfig/proxy. I have even added proxy in Java Control.</p>
  
  <p>Checking with wget and the proxy does work:</p>
  
  <pre><code>user@machineLinx:~/workspace/myApp&gt; wget     https://timestamp.geotrust.com/tsa
  --2015-10-05 16:06:30--  https://timestamp.geotrust.com/tsa
  Resolving proxy.spacetec.no... 100.11.4.6
  Connecting to proxy.spacetec.no|100.11.4.6|:3128... connected.
  Proxy request sent, awaiting response... 404 Not Found
  2015-10-05 16:06:31 ERROR 404: Not Found.
  </code></pre>
  
  <p>Using Jarsigner does not use the provided Proxy:</p>
  
  <pre><code>/usr/java/jdk1.7.0_80/bin/jarsigner -J-Dhttps.proxyHost=http://proxy.company.com -J-Dhttps.proxyPort=3128 -keystore /home/user/keystore.p12 -storepass myStorePass -storetype pkcs12 -tsa https://timestamp.geotrust.com/tsa workspace/myApp/target/myApp-1.0.0-SNAPSHOT.jar alias
  
  jarsigner: unable to sign jar: no response from the Timestamping Authority. When connecting from behind a firewall an HTTP or HTTPS proxy may need to be specified. Supply the following options to jarsigner:
    -J-Dhttp.proxyHost=&lt;hostname&gt;
    -J-Dhttp.proxyPort=&lt;portnumber&gt;
  or
    -J-Dhttps.proxyHost=&lt;hostname&gt; 
    -J-Dhttps.proxyPort=&lt;portnumber&gt; 
  </code></pre>
  
  <p>So why is the proxy working on my system, but not with Java? I have tried with both jdk1.7.0_80 and jdk1.8.0_60</p>
  
  <p>jarsigner communicates with the TSA using the Time-Stamp Protocol (TSP) defined in RFC 3161. The protocol basically assumes a listener process on a TSA that can accept TSA messages on a well-defined port (IP port number 318).</p>
  
  <p>Could it be that my Proxy does not communicate with this port for TSP?</p>