WIP: improve sshcert authentication #507

Draft
noerw wants to merge 21 commits from noerw/tea:sshcert-noerw into main
Member
No description provided.
noerw added this to the v0.10.0 milestone 2022-09-14 22:23:51 +00:00
noerw added the
kind
enhancement
kind
refactor
labels 2022-09-14 22:23:51 +00:00
noerw added 18 commits 2022-09-14 22:23:52 +00:00
Add support for API authentication via ssh certificates/pubkey
All checks were successful
continuous-integration/drone/pr Build is passing
1502f26af5
Add support for keys outside of ssh-agent and simplify interact menu
Some checks failed
continuous-integration/drone/pr Build is failing
62a335557e
Fix linting issue
Some checks failed
continuous-integration/drone/pr Build is failing
1318ff4e2f
Fix typo
All checks were successful
continuous-integration/drone/pr Build is passing
7e2edacb4a
Fix ssh-agent-principal and ssh-agent-key login params
All checks were successful
continuous-integration/drone/pr Build is passing
d6d76ad4cd
Fix ssh certificate from disk
All checks were successful
continuous-integration/drone/pr Build is passing
16a8dec23d
Make sshKey option work with certificates
All checks were successful
continuous-integration/drone/pr Build is passing
0744ebc93f
Add support for encrypted ssh keys
All checks were successful
continuous-integration/drone/pr Build is passing
393671f779
People really should use ssh-agent but in the case they don't ask for
the passphrase. We do not save the passphrase, so for every action tea
will ask their passphrase.
Use upstream go-sdk
All checks were successful
continuous-integration/drone/pr Build is passing
02e77d463f
Merge branch 'master' into sshcert
Some checks failed
continuous-integration/drone/pr Build is failing
4292e79cbd
as a preparation for another refactor to avoid an import cycle
- add more checks
- avoid importing survey in modules/config (importing modules/interact
  in modules/config is still not great, but I don't see how this could
  be solved without making the Client() api very awkward).
- don't make the login method selection a two-prompt process
  (provide all 3 options first)
- don't ask about the SSHKey path again, when using the new auth method

NOTE: the SSHKey path prompt could be removed completely, as users that
have want to use a custom key, would probably use LoginMethodSsh.
However that method does not work with ecdsa-sha2-nistp521 and other key
types - users with that sort of key still may need this option.
Merge branch 'main' into sshcert-noerw
Some checks failed
continuous-integration/drone/pr Build is failing
01ee577d1d
6543 added 1 commit 2022-09-14 23:43:18 +00:00
Merge branch 'master' into sshcert-noerw
Some checks failed
continuous-integration/drone/pr Build is failing
a08044da40
6543 reviewed 2022-09-14 23:50:01 +00:00
@ -0,0 +129,4 @@
}
// Select creates a generic select prompt, with processing of custom values or none-option.
func Select(prompt string, options []string, customVal, noneVal string) (string, error) {
Owner

can options have len = 0 ?

if so we could get a out of slice access issue at L138

can options have len = 0 ? if so we could get a out of slice access issue at L138
Owner

yes if it's 0 then the Select is wrong used anyway ...

yes if it's 0 then the Select is wrong used anyway ...
6543 marked this conversation as resolved
6543 added 2 commits 2022-09-14 23:59:44 +00:00
fix lint
All checks were successful
continuous-integration/drone/pr Build is passing
a154f39dde
Owner

@noerw ok now I'll wait until u make it non wip ;)

@noerw ok now I'll wait until u make it non wip ;)
6543 approved these changes 2022-09-26 20:34:11 +00:00
Some checks are pending
continuous-integration/drone/pr Build is passing
check-and-test / check-and-test (pull_request)
Required
This pull request has changes conflicting with the target branch.
  • modules/interact/login.go
  • modules/interact/prompts.go

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u sshcert-noerw:noerw-sshcert-noerw
git checkout noerw-sshcert-noerw
Sign in to join this conversation.
No description provided.