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

Support OpenSSH formatted private keys #67

Open
felixzieger opened this issue Feb 9, 2022 · 1 comment
Open

Support OpenSSH formatted private keys #67

felixzieger opened this issue Feb 9, 2022 · 1 comment

Comments

@felixzieger
Copy link
Contributor

felixzieger commented Feb 9, 2022

UniPipe crashes if it receives keys OpenSSH encoded keys with an error message similar to:

org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'catalogRepository' defined in URL [jar:file:/app/unipipe-service-broker-1.0.0.jar!/BOOT-INF/classes!/io/meshcloud/dockerosb/persistence/CatalogRepository.class]: Unsatisfied dependency expressed through constructor parameter 1; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'gitHandlerService' defined in URL [jar:file:/app/unipipe-service-broker-1.0.0.jar!/BOOT-INF/classes!/io/meshcloud/dockerosb/persistence/GitHandlerService.class]: Bean instantiation via constructor failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [io.meshcloud.dockerosb.persistence.GitHandlerService]: Constructor threw exception; nested exception is org.eclipse.jgit.api.errors.TransportException: [email protected]:meshcloud/unipipe-demo.git: invalid privatekey: [B@5f233b26
	at org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:800) ~[spring-beans-5.3.7.jar!/:5.3.7]
	at org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:229) ~[spring-beans-5.3.7.jar!/:5.3.7]

Working on this issue could be combined with #33

@felixzieger felixzieger changed the title Support PEM formatted private keys Support OpenSSH formatted private keys Jun 20, 2022
@henryde
Copy link
Contributor

henryde commented Oct 21, 2022

If you tell ssh-keygen to generate a key in PEM format it will not work for current key algorithms so you will be stuck with an insecure key which will then get refused by GitHub, this is a pretty bad experience for what should be the most normal use case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants