Commit graph

69 commits

Author SHA1 Message Date
Ev Kontsevoy c6c77a183c SCP improvements
- Removed strange handling of the ending / symbol, causing directories
  not being created. Fixes #606

- Added per-file progress indicator (reports "XXX uploaded").
2016-11-03 20:06:43 -07:00
Ev Kontsevoy 380d2f366b Preliminary SCP work
1) -r flag handling

   Proper handling of `-r` flag on the tsh side (recursive).
   Prior to this commit it was all uploads were _always_ recursive.

2) less verbose logging.

   Replaced a bunch of log.Info() with log.Debug()
2016-11-03 18:07:39 -07:00
Ev Kontsevoy b4a6a4f972 Cleaned up Teleport logging
* Downgraded many messages from `Debug` to `Info`
* Edited messages so they're not verbose and not too short
* Added "context" to some
* Added logical teleport component as [COMPONENT] at the beginning of
  many, making logs **vastly** easier to read.
* Added one more logging level option when creating Teleport (only
  Teleconsole uses it for now)

The output with 'info' severity now look extremely clean.
This is startup, for example:

```
INFO[0000] [AUTH]  Auth service is starting on turing:32829  file=utils/cli.go:107
INFO[0000] [SSH:auth] listening socket: 127.0.0.1:32829  file=sshutils/server.go:119
INFO[0000] [SSH:auth] is listening on 127.0.0.1:32829    file=sshutils/server.go:144
INFO[0000] [Proxy] Successfully registered with the cluster  file=utils/cli.go:107
INFO[0000] [Node] Successfully registered with the cluster  file=utils/cli.go:107
INFO[0000] [AUTH] keyAuth: 127.0.0.1:56886->127.0.0.1:32829, user=turing  file=auth/tun.go:370
WARN[0000] unable to load the auth server cache: open /tmp/cluster-teleconsole-client781495771/authservers.json: no such file or directory  file=auth/tun.go:594
INFO[0000] [SSH:auth] new connection 127.0.0.1:56886 -> 127.0.0.1:32829 vesion: SSH-2.0-Go  file=sshutils/server.go:205
INFO[0000] [AUTH] keyAuth: 127.0.0.1:56888->127.0.0.1:32829, user=turing.teleconsole-client  file=auth/tun.go:370
INFO[0000] [AUTH] keyAuth: 127.0.0.1:56890->127.0.0.1:32829, user=turing.teleconsole-client  file=auth/tun.go:370
INFO[0000] [Node] turing connected to the cluster 'teleconsole-client'  file=service/service.go:158
INFO[0000] [AUTH] keyAuth: 127.0.0.1:56892->127.0.0.1:32829, user=turing  file=auth/tun.go:370
INFO[0000] [SSH:auth] new connection 127.0.0.1:56890 -> 127.0.0.1:32829 vesion: SSH-2.0-Go  file=sshutils/server.go:205
INFO[0000] [SSH:auth] new connection 127.0.0.1:56888 -> 127.0.0.1:32829 vesion: SSH-2.0-Go  file=sshutils/server.go:205
INFO[0000] [Node] turing.teleconsole-client connected to the cluster 'teleconsole-client'  file=service/service.go:158
INFO[0000] [Node] turing.teleconsole-client connected to the cluster 'teleconsole-client'  file=service/service.go:158
INFO[0000] [SSH] received event(SSHIdentity)             file=service/service.go:436
INFO[0000] [SSH] received event(ProxyIdentity)           file=service/service.go:563
```
You can easily tell that auth, ssh node and proxy have successfully started.
2016-09-02 17:28:18 -07:00
Ev Kontsevoy 7c3b74d8ff PR comments - implemented! 2016-05-27 11:26:48 -07:00
Ev Kontsevoy ce3bbbde3f SCP error messages are proper now
`tsh scp` now reports the same error messages as OpenSSH scp:

- when talking to Teleport servers
- when talking to OpenSSH servers
2016-05-26 18:00:40 -07:00
Ev Kontsevoy 48a74fbeca Intermediate commit (scp up/down works agaisnt openSSH servers) 2016-05-26 14:46:56 -07:00
Ev Kontsevoy 6e6e951650 Intermediate commit 2016-05-25 22:33:07 -07:00
Ev Kontsevoy 2d566ecbe2 Intermediate commit 2016-05-23 15:50:53 -07:00
Ev Kontsevoy b175d92052 PR comments - implemented! 2016-05-07 21:51:35 -07:00
Ev Kontsevoy e10612028e Preparations for a PR
Fixes #394
2016-05-06 20:48:02 -07:00
Ev Kontsevoy 9d2a5c3536 Buffer overflow issue 2016-05-06 13:37:11 -07:00
Ev Kontsevoy d36fced780 Added multi-party real-time window size support 2016-05-02 23:21:13 -07:00
Ev Kontsevoy 98568578ea Quick size fix 2016-05-02 20:39:11 -07:00
Ev Kontsevoy bec224fe97 Dirty size pushing 2016-05-02 19:12:16 -07:00
Ev Kontsevoy 17268c0c73 Removed extra UTF-8 encoding 2016-05-01 22:25:54 -07:00
Ev Kontsevoy 5629f76868 Added utf-8 encoding of terminal streams 2016-04-29 00:55:58 -07:00
Ev Kontsevoy 69177fd751 Almost fixed tests 2016-04-28 21:44:18 -07:00
Ev Kontsevoy 5e01bc3d55 Merge branch 'ev/log' of github.com:gravitational/teleport into ev/log 2016-04-28 17:42:14 -07:00
Ev Kontsevoy 29d5ef454d Audit log improvements
Added clear separation between 'user' (Teleport user) and 'login' (OS
host login)
2016-04-26 17:41:04 -07:00
Ev Kontsevoy 2e099cdd0b Added full audit event support for:
- Port forwarding
- SCP up/down
- Auth attempts
2016-04-26 17:41:04 -07:00
klizhentas d68e693cad migrate to trace errors 2016-04-12 11:07:14 -07:00
Ev Kontsevoy 6ac710f308 Nicer inetgration package 2016-04-11 16:32:37 -07:00
Ev Kontsevoy 757c34a755 Added the ability to stop teleport without restarting the process 2016-04-03 12:17:28 -07:00
klizhentas ca7e3820d7 This commit adds ability to preconfigure the cluster without running
auth server. This is needed when you configure cluster from scratch and
all nodes including auth server spin up simultaneously.

* Add tctl tools to generate keys and certificates

  + Command "tctl authorities gen" generates public and private keypair.
  + Command "tctl authorities gencert" generates public and private keypair signed
    by existng private key
  + Command "tctl authorities export" was modified to be able to export exisitng private
    CA keys to local storage

   All of these commands are hidden by default.

section "static configuration"

* Add ability to configure teleport from environment variable

Environment variable TELEPORT_CONFIG can contain base64 encoded
YAML file config file of the standard file format, so teleport will use it on start

* Add special secrets section to the config file

Section "secrets" was updated to support pre-configured trusted CA keys and pre-generated keys

* Add special rts hidden section to add support for provisioning
2016-03-28 12:58:34 -07:00
klizhentas bba45fceae fix unsync in scp client impplementation, recover tests, fixes #274 2016-03-22 10:40:26 -07:00
Ev Kontsevoy a07b3226b8 Added supporto for user home directory for scp 2016-03-21 23:47:57 -07:00
Ev Kontsevoy e2c495bb76 Merge remote-tracking branch 'origin/master' into ev/scp-bug 2016-03-21 22:13:25 -07:00
klizhentas 942318c576 resize terminal 2016-03-20 12:30:50 -07:00
Ev Kontsevoy a7d28971ac Refactoring
1. Removed scp.Server structure. It is redundant and doesn't add
   anything on top of scp.Command

2. Added user.User instance to scp.Command, so it now knows who
   the owner of uploaded files is.
2016-03-19 13:10:27 -07:00
Ev Kontsevoy 2ad2fb4ff1 SCP bugfixes
- also removed annoying log messages
- refs #274
2016-03-18 20:35:28 -07:00
klizhentas 6edd6675e6 re-introduce reverse tunnels into teleport
Reverse tunnels are now first class citizens of teleport.
There's no longer static configuration for reverse tunnel agents
in the config. Instead, admins can add and remove reverse tunnels
using tctl reversetunnel (hidden) commands.

* tctl reversetunnel ls
  lists reverse tunnels

* tctl reversetunnel upsert a.example.com 10.0.0.4:2023,10.0.0.5:2033 --ttl=10m
  updates or inserts reverse tunnel for 10 minutes

* tctl reversetunnel del a.example.com
  deletes a reverse tunnel

Teleport proxies watch changes in the reverse tunnels on the backend and
spin up / spin down reverse tunnels according to these changes.
2016-03-18 17:13:22 -07:00
klizhentas 75a430bfa9 add resize sync and detection on tsh on both sides, fixes #235 2016-03-15 17:16:58 -07:00
Ev Kontsevoy 5d3787eacd Fixed craziness 2016-03-14 14:52:35 -07:00
Ev Kontsevoy 3418ac80b6 Merge remote-tracking branch 'origin/master' into ev/ssh-api
Conflicts:
	tool/tctl/main.go
	tool/teleport/main.go
	tool/tsh/main.go
2016-03-14 14:27:43 -07:00
klizhentas 7a2a9e334f add support for TELEPORT_DEBUG_TESTS environment variable turning on verbose testing 2016-03-14 14:07:45 -07:00
Ev Kontsevoy 7521b57e56 Rough implementation of SCP
Refs #244
Closes #244
2016-03-13 16:18:08 -07:00
klizhentas 0e503ca376 Add proper integration with OpenSSH on both sides 2016-03-09 19:39:15 -08:00
klizhentas e05fc50baf fix data races found in tests, fixes #165 2016-03-04 14:38:19 -08:00
klizhentas 07fd46bb1d fix orphane processes, fixes #191 2016-03-03 12:28:10 -08:00
Ev Kontsevoy 6a8dc6c668 Nonintrusive minor refactoring of "auth tunnel"
1. Wrote comments in places where I was confused
2. Renamed variables/structs that were confusing
3. Cleaned up code for easier reading
2016-03-01 14:40:10 -08:00
Ev Kontsevoy e02378baf8 Minor code refactoring and commenting...
...in preparation for server side chagnes
2016-02-29 19:00:45 -08:00
Alex Lyulkov bd61f6793f Changed limiter initialization 2016-02-26 16:59:35 +03:00
Alex Lyulkov 07c0ca47f9 Fixed tsh tests, changed tests ports 2016-02-25 20:30:44 +03:00
klizhentas ef28bf4b24 reverse tunnel roundrobin, refs #114
* reverese tunnel now supports multiple inbound connections
* load balances between them
* discards and removes bad connections from the pool
2016-02-19 20:56:25 -08:00
klizhentas 9fcc861e09 Replace dependencies with code.google.com paths, remove unused code
* Remove usage of lemma/secret and gravitational/session
* Replace deps using code.google.com with alternatives
* Vendor test keys to the code base
2016-02-17 18:36:52 -08:00
klizhentas 6cdaba2ef6 user mappings should be deleted if user is deleted, fixes #116
This commit includes refactoring and cleanup of cert authority sybsystem:

* User keys methods are deleted
* Authorities CRUD is simplified
* Lots of code removed
2016-02-17 15:29:01 -08:00
klizhentas 7270361876 fix other tests logic as well 2016-02-15 20:06:59 -08:00
klizhentas 6640b80597 fix scp flaky test, fixes #72 2016-02-15 18:33:06 -08:00
Alex Lyulkov c2b6d96485 Fixed OS username in tests 2016-02-06 15:15:01 +03:00
Alex Lyulkov d2f50cf4b6 Fixed tests logging 2016-02-05 17:09:21 +03:00