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

Source postgres: Validate SSH key before checking connection. #10004

Closed
alafanechere opened this issue Feb 2, 2022 · 3 comments
Closed

Source postgres: Validate SSH key before checking connection. #10004

alafanechere opened this issue Feb 2, 2022 · 3 comments
Assignees
Labels
area/connectors Connector related issues autoteam connectors/source/postgres team/db-dw-sources Backlog for Database and Data Warehouse Sources team type/enhancement New feature or request

Comments

@alafanechere
Copy link
Contributor

If an invalid SSH key (not RSA format, typo during copy paste etc) is used the failure happens at connection check:
Cannot invoke "org.bouncycastle.openssl.PEMKeyPair.getPublicKeyInfo()" because "keypair" is null

It would be great if we could validate the SSH key in the front-end with regex patterns.

@alafanechere alafanechere added type/enhancement New feature or request area/connectors Connector related issues connectors/source/postgres labels Feb 2, 2022
@grishick grishick added the team/db-dw-sources Backlog for Database and Data Warehouse Sources team label Sep 27, 2022
@bleonard
Copy link
Contributor

We should validate this as part of the CHECK command

@akashkulk
Copy link
Contributor

@ryankfu is this a duplicate that will be resolved by your recent PR? #18041

@ryankfu
Copy link
Contributor

ryankfu commented Oct 20, 2022

@akashkulk yes, this appears to have been fixed with the recent PR #18041 at least based on the changes from Rodi's PR which changes the retrieval method from getPublicKeyInfo() to keyPairs.iterator().next()

I will close this ticket as completed and update #18041 to include a description with this comment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/connectors Connector related issues autoteam connectors/source/postgres team/db-dw-sources Backlog for Database and Data Warehouse Sources team type/enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

6 participants