Commit Graph
14 Commits
Author SHA1 Message Date
Brian Joerger 488af75797 Client store generalization (#19420)
- Add a generalized client store made up of a key, profile, and trusted certs store. Each sub store can support different backends (~/.tsh, identity_file, in-memory). 
- Replace custom identity file handling with in-memory client store.
- Fix issues with trusted certs handling.
2023-01-06 01:34:04 +00:00
Brian Joerger 32c4ae255f Add Credential loader support for tsh profiles. (#5993) 2021-03-23 16:35:42 -07:00
xacrimon d162b02060 implement rfd 18 2021-03-17 19:04:06 +01:00
Andrew Lytvynov 566b7cc457 RFD 1: user testify/require instead of testify/assert
`require` is a sister package to `assert` that terminates the test on
failure. `assert` records the failure but lets the test proceed, which
is un-intuitive.

Also update all existing tests to match.
2020-10-16 00:15:25 +00:00
Andrew Lytvynov 92ed2db38a Fixing golint warnings, batch 1
Mostly cosmetic changes:
- making receiver names consistent
- renaming `foo.FooBar` to `foo.Bar` (using package name as prefix)
- removing redundant `else` branches
- changing `a += 1` to `a++`
2020-10-13 00:22:49 +00:00
Forrest Marshall b2faac1d0d track current profile via regular file instead of symlink 2020-09-29 10:15:17 -07:00
Andrew Lytvynov 3c94003379 errcheck: fix findings in lib/backend, lib/client 2020-06-01 20:16:16 +00:00
Sasha Klizhentas 9d2a881f48 Break endless retry loop.
Previous Login code path was calling itself recursively.
In some cases that lead to endless loops with browser
opening up forever.

This commit factors out retry logic to RetryWithLogin
decorator handler that is used by CLI explicitly.

Client code became better as a result as there are no
hidden side effects.
2019-04-25 14:22:49 -07:00
Alexander Klizhentas 269706691c Use relevant SSHProxyAddr after Login (#2657)
Login could change the SSH proxy address based
on the information from "ping" endpoint

The function ConnectToProxy was saving
old version of the variable and kept using
it during login procedure.

This commit fixes that so the relevant
variable is always referenced.
2019-04-24 16:02:23 -07:00
Steven Aerts e1d896621f FIX 1693: SOCKS5 dynamic port forwarding
Implements the -D flag of ssh, but only with a SOCKS5 proxy.
OpenSSH also supports a SOCKS4 proxy.

This commit also fixes a bug in the server which prevented it from
forwarding raw IPv6 sockets, as the addresses were incorrectly
escaped.
2018-10-15 11:52:02 -07:00
Russell Jones 97074076cb Split public_addr into web_proxy_addr and ssh_proxy_addr. 2018-08-31 16:33:54 -07:00
Russell Jones 2590e716c3 Always read tsh profile. 2017-06-07 11:37:55 -07:00
Ev Kontsevoy a8889271c6 Finished polish of tsh login
This commit:

* Improves on the previous commit on better name resolution by the proxy
  (and fixes a bug introduced by the previous commit)

* Removes 'host_login' from tsh client profile. Closes #729
2017-01-29 17:52:42 -08:00
Ev Kontsevoy 7964bfc54e Client profiles for TSH 2016-10-22 12:54:16 -07:00