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

Question: how to connect via HTTPS? #3

Closed
mouse07410 opened this issue Nov 27, 2018 · 1 comment
Closed

Question: how to connect via HTTPS? #3

mouse07410 opened this issue Nov 27, 2018 · 1 comment

Comments

@mouse07410
Copy link
Contributor

When I specify connector as https://localhost:12345 (and provide the key and the cert to the yubihsm-connector, of course), the shell fails to connect with the following debug messages:

yubihsm> connect https://127.0.0.1:12345
[LIB - INF 16:23:06.975870] yubihsm.c:4048 (yh_init_connector): Loading http backend
[LIB - INF 16:23:06.981988] yubihsm.c:4056 (yh_init_connector): Loaded a backend
[LIB - INF 16:23:06.982002] yubihsm.c:3901 (create_connector): Creating connector
[LIB - INF 16:23:06.982023] yubihsm.c:3953 (create_connector): Creating *connector->connection
[LIB - INF 16:23:06.982044] yubihsm.c:3963 (create_connector): Created connector
[LIB - INF 16:23:06.982054] yubihsm_curl.c:86 (backend_connect): Trying to connect to http://127.0.0.1:12345/connector/status
[LIB - ERR 16:23:06.982685] yubihsm_curl.c:113 (backend_connect): Amount of data received does not match scratch buffer. Expected 3, found 7
[LIB - ERR 16:23:06.982700] yubihsm.c:4088 (yh_connect): Failed when connecting: Generic error

yubihsm-connector displays the following:

2018/11/27 16:23:06 http: TLS handshake error from 127.0.0.1:51001: tls: first record does not look like a TLS handshake
@klali
Copy link
Member

klali commented Nov 28, 2018

the connector URL to use can only be set when starting the yubihsm-shell, like:

$ yubihsm-shell --connector=https://127.0.0.1:12345

@klali klali closed this as completed Nov 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants