Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

https issues #16

Closed
cesmarvin opened this issue May 16, 2011 · 19 comments
Closed

https issues #16

cesmarvin opened this issue May 16, 2011 · 19 comments
Labels
bug Something isn't working

Comments

@cesmarvin
Copy link
Contributor

Original report by Anonymous.


Hi,

I just changed the SCM manager settings to use https on an different port but now I can't reach the SCM Manager again.

using https://host:sslport/scm

any idea?

From the system output I can't see any entry about sslport (using 8001).

Just the http port is shown at the end:
2011-05-16 14:06:37.951:INFO::Started SelectChannelConnector@0.0.0.0:8000

but http://hostname:port/scm is not working as well.

Thanks!

@cesmarvin
Copy link
Contributor Author

Original comment by Sebastian Sdorra (Bitbucket: sdorra, GitHub: sdorra).


Have you an SSL-Listener in the server-config.xml configured? The ssl-port in the general config panel is only for a redirect to that port.

@cesmarvin
Copy link
Contributor Author

Original comment by Sebastian Sdorra (Bitbucket: sdorra, GitHub: sdorra).


When you try to access your scm-manager the ssl-filter redirects you to https://hostname:sslport/scm and if no listener is configured to hostname:sslport then you get this issue. Have a look at <<issue 9>>.

@cesmarvin
Copy link
Contributor Author

Original comment by Sebastian Sdorra (Bitbucket: sdorra, GitHub: sdorra).


To disable the https redirect do the following steps:

Edit the config.xml in your scm home. Search the line

true

and replace it with:

false

Restart the scm-server.

@cesmarvin
Copy link
Contributor Author

Original comment by Anonymous.


okay, looks like this is not so easy to handle because there is no listener configured from my site.

I have no idea how to do this.......

@cesmarvin
Copy link
Contributor Author

Original comment by Sebastian Sdorra (Bitbucket: sdorra, GitHub: sdorra).


I will add a wiki page tomorrow.

@cesmarvin
Copy link
Contributor Author

Original comment by Anonymous.


That sounds GREAT!

Thanks

@cesmarvin
Copy link
Contributor Author

Original comment by Anonymous.


Just a quick question - Any update here today?

THANKS A LOT!

@cesmarvin
Copy link
Contributor Author

Original comment by Sebastian Sdorra (Bitbucket: sdorra, GitHub: sdorra).


Here is a first version of the wiki page. https://bitbucket.org/sdorra/scm-manager/wiki/scm-server-ssl

@cesmarvin
Copy link
Contributor Author

Original comment by Anonymous.


okay - thanks!

Just one problem.....I'm running a windows server :-(

@cesmarvin
Copy link
Contributor Author

Original comment by Sebastian Sdorra (Bitbucket: sdorra, GitHub: sdorra).


That is not a problem. Start the cmd.exe and run the keytool.exe. If the keytool.exe is not in your path then you must use the complete path. For example:

#!bash

c:\Progamm Files\java\jdk1.6.x\bin\keytool.exe -genkey -alias scm -keyalg RSA -keystore keystore.jks

@cesmarvin
Copy link
Contributor Author

Original comment by Anonymous.


okay - scm manager is using ssl now.

When I try to clone the repository now

git clone https://host.com:8181/git

I receive an error

error: error setting certificate verify locations:
CAfile: /bin/curl-ca-bundle.crt
CApath: none

What does this need?

@cesmarvin
Copy link
Contributor Author

Original comment by Anonymous.


$ git clone https://scmadmin@host.com:8181/scm/git/test test_ssl2
Initialized empty Git repository in C:/Users/scmadmin/test_ssl2/.git/
Password:

error: error setting certificate verify locations:
CAfile: /bin/curl-ca-bundle.crt
CApath: none

while accessing https://scmadmin@host.com:8181/scm/git/test/info/refs

fatal: HTTP request failed

@cesmarvin
Copy link
Contributor Author

Original comment by Sebastian Sdorra (Bitbucket: sdorra, GitHub: sdorra).


Git does not know the certifacte. A quick and dirty workaround is to disable the certificate check:

#!bash

git config http.sslVerify false

@cesmarvin
Copy link
Contributor Author

Original comment by Sebastian Sdorra (Bitbucket: sdorra, GitHub: sdorra).


For the nice way you have to export the certificate from keystore:

#!bash

keytool -exportcert -keystore keystore.jks -alias scm -rfc -file cert.pem

And set the absolute path to cert.pem as sslCAInfo path:

#!bash

git config http.sslCAInfo c:\scm-server\conf\cert.pem

@cesmarvin
Copy link
Contributor Author

Original comment by scm_manager_tester (Bitbucket: scm_manager_tester, ).


Second option sound useful - will give it a try but not before Thursday. - SORRY

@cesmarvin
Copy link
Contributor Author

Original comment by Sebastian Sdorra (Bitbucket: sdorra, GitHub: sdorra).


Wiki page updated:

https://bitbucket.org/sdorra/scm-manager/wiki/scm-server-ssl

@cesmarvin
Copy link
Contributor Author

Original comment by Sebastian Sdorra (Bitbucket: sdorra, GitHub: sdorra).


I think this issue is solved. The clone problem is a git problem. If you have questions to the git configuration send me a bitbucket notification.

@cesmarvin
Copy link
Contributor Author

Original comment by Luís Bastiao Silva (Bitbucket: [Luis Bastiao](https://bitbucket.org/Luis Bastiao), ).


Sorry for re-open this topic. But why this is a git issue? The https works in github. Can you clarify it to me?

@cesmarvin
Copy link
Contributor Author

Original comment by Sebastian Sdorra (Bitbucket: sdorra, GitHub: sdorra).


It is not really a git issue. It is the normal behavior of a ssl connection. If the client could not verify the certificate, it abort the connection (same behavior you could watch with a browser and a self signed certificate). Https works for github, because they have signed their certificate by a authority like verisign. You could also use a signed certificate with scm-manager, than you don't have to configure "http.sslVerify" or "http.sslCAInfo". For more information's on ssl connections http://en.wikipedia.org/wiki/Secure_Sockets_Layer. Next time please write to the mailing list https://groups.google.com/group/scmmanager for questions.

@cesmarvin cesmarvin added major bug Something isn't working labels Mar 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant