]> source.dussan.org Git - gitblit.git/commitdiff
Document SNI workaround for Java-based clients
authorJames Moger <james.moger@gitblit.com>
Fri, 29 Mar 2013 21:07:23 +0000 (17:07 -0400)
committerJames Moger <james.moger@gitblit.com>
Fri, 29 Mar 2013 21:47:44 +0000 (17:47 -0400)
src/site/faq.mkd
src/site/setup.mkd

index cdf3d59ef4739f818afc056ebf30ef2644d8d99a..fb1b599451c3ce03a74f648d5eccbfeb798963df 100644 (file)
@@ -3,18 +3,19 @@
 ### Eclipse/Egit/JGit complains that it "can't open upload pack"?\r
 There are a few ways this can occur:\r
 \r
-1. You are using https with a self-signed certificate and you **did not** configure *http.sslVerify=false*\r
+1. Are you running Java 7?<br />Java 7 introduced SNI support for SSL connections and it is enabled by default.<br />[Java 7 Security Enhancements](http://docs.oracle.com/javase/7/docs/technotes/guides/security/enhancements-7.html)<br />To disable SNI alerts, add this line to your eclipse.ini file and restart Eclipse.<br /><pre>-Djsse.enableSNIExtension=false</pre>\r
+2. You are using https with a self-signed certificate and you **did not** configure *http.sslVerify=false*\r
     1. Window->Preferences->Team->Git->Configuration\r
     2. Click the *New Entry* button\r
     3. <pre>Key = <em>http.sslVerify</em>\r
 Value = <em>false</em></pre>\r
-2. Gitblit GO's default self-signed certificate is bound to *localhost* and you are trying to clone/push between machines.\r
+3. Gitblit GO's default self-signed certificate is bound to *localhost* and you are trying to clone/push between machines.\r
     1. Review the contents of `makekeystore.cmd`\r
     2. Set *your hostname* in the *HOSTNAME* variable.\r
     3. Execute the script.<br/>This will generate a new certificate and keystore for *your hostname* protected by *server.storePassword*. \r
-3. The repository is clone-restricted and you don't have access.\r
-4. The repository is clone-restricted and your password changed.\r
-5. A regression in Gitblit.  :(\r
+4. The repository is clone-restricted and you don't have access.\r
+5. The repository is clone-restricted and your password changed.\r
+6. A regression in Gitblit.  :(\r
 \r
 ### Why can't I access Gitblit GO from another machine?\r
 1. Please check *server.httpBindInterface* and *server.httpsBindInterface* in `gitblit.properties`, you may be only be serving on *localhost*.\r
index 8a3d99a4b46064ac06804ffe6276a8fae8809916..525be855ee444541fa0f8f46b6c25e243de8c3d7 100644 (file)
@@ -741,7 +741,7 @@ You must tell Git/JGit not to verify the self-signed certificate in order to per
 **NOTE:**  \r
 The default self-signed certificate generated by Gitlbit GO is bound to *localhost*.  \r
 If you are using Eclipse/EGit/JGit clients, you will have to generate your own certificate that specifies the exact hostname used in your clone/push url.  \r
-You must do this because Eclipse/EGit/JGit (<= 2.1.0) always verifies certificate hostnames, regardless of the *http.sslVerify=false* client-side setting. \r
+You must do this because Eclipse/EGit/JGit (<= 2.3.1) always verifies certificate hostnames, regardless of the *http.sslVerify=false* client-side setting. \r
  \r
 - **Eclipse/EGit/JGit**\r
     1. Window->Preferences->Team->Git->Configuration\r
@@ -757,6 +757,25 @@ You may find the default post buffer of your git client is too small to push lar
 This can be adjusted on your client by changing the default post buffer size:\r
 <pre>git config --global http.postBuffer 524288000</pre>\r
 \r
+### Disabling SNI\r
+\r
+You may run into SNI alerts (Server Name Indication).  These will manifest as failures to clone or push to your Gitblit instance.\r
+\r
+#### Java-based Clients\r
+\r
+When using Java 7-based clients, SNI is enabled by default.  You can disable SNI by specifying the JVM system parameter `-Djsse.enableSNIExtension=false` when your Java-based client launches.\r
+\r
+For Eclipse, you can append `-Djsse.enableSNIExtension=false` to your *eclipse.ini* file.\r
+\r
+#### Native Clients\r
+\r
+Native clients may display an error when attempting to clone or push that looks like this:\r
+---FIXED---\r
+C:\projects\git\gitblit>git push rhcloud master\r
+error: error:14077458:SSL routines:SSL23_GET_SERVER_HELLO:reason(1112) while accessing https://demo-gitblit.rhcloud.com/git/gitblit.git/info/refs?service=git-receive-pack\r
+fatal: HTTP request failed\r
+---FIXED---\r
+\r
 ### Cloning an Access Restricted Repository \r
 - **Eclipse/EGit/JGit**  \r
 Nothing special to configure, EGit figures out everything.\r