Roman Zeyde
83f17704cb
server: remove 'SSH_AUTH_SOCK=' from logging
8 years ago
Roman Zeyde
4c8fcd6714
ssh: use special UNIX socket name
8 years ago
Roman Zeyde
97efdf4a45
ssh: handle connections concurrently
8 years ago
Roman Zeyde
ee2f6b75dc
server: log SSH version for debugging
8 years ago
Roman Zeyde
513e99dd57
server: refactor server_thread() to decouple it from handle_connection()
8 years ago
Roman Zeyde
1022e54d6a
protocol: fail gracefully on cancellation
9 years ago
Roman Zeyde
b07d7e6535
server: handle IOError gracefully
9 years ago
Roman Zeyde
4384b93c19
main: remove unneeded use_shell parameter
9 years ago
Roman Zeyde
2ebefff909
server: add docstrings
9 years ago
Roman Zeyde
cafa218e19
server: pass handler and add debug option
9 years ago
Roman Zeyde
9afd07e867
server: make sure accepted UNIX sockets are blocking
...
It was a problem on Mac OS X, where sometimes we got EAGAIN
errors from calling socket.recv() on them.
9 years ago
Roman Zeyde
0c63aef719
sort imports using isort tool
9 years ago
Roman Zeyde
33a6951a96
server: don't crash after single exception
9 years ago
Roman Zeyde
fb0d0a5f61
server: stop the server via a threading.Event
...
It seems that Mac OS does not support calling socket.shutdown(socket.SHUT_RD)
on a listening socket (see https://github.com/romanz/trezor-agent/issues/6 ).
The following implementation will set the accept() timeout to 0.1s and stop
the server if a threading.Event (named "quit_event") is set by the main thread.
9 years ago
Roman Zeyde
fe1e1d2bb9
server: log command with INFO level
9 years ago
Roman Zeyde
c3fa79e450
Fix a few pylint issues
9 years ago
Roman Zeyde
a8c6e71825
rename package name to trezor_agent
9 years ago