diff options
author | Robey Pointer <robey@lag.net> | 2004-01-04 09:29:13 +0000 |
---|---|---|
committer | Robey Pointer <robey@lag.net> | 2004-01-04 09:29:13 +0000 |
commit | 988c6abda08dd7380da37cfc74b9642437afe1ae (patch) | |
tree | 64ef726eb8fdf17e01f832a8487c7a2776939067 /demo_server.py | |
parent | 3a8887a42083dda796f50e1e9b32f625abcb5d5a (diff) |
[project @ Arch-1:robey@lag.net--2003-public%secsh--dev--1.0--patch-20]
more docs, and password-protected key files can now be read
lots more documentation, some of it moved out of the README file, which is
now much smaller and less rambling.
repr(Transport) now reports the number of bits used in the cipher.
cleaned up BER to use util functions, and throw a proper exception (the new
BERException) on error. it doesn't ever have to be a full BER decoder, but
it can at least comb its hair and tuck in its shirt.
lots of stuff added to PKey.read_private_key_file so it can try to decode
password-protected key files. right now it only understands "DES-EDE3-CBC"
format, but this is the only format i've seen openssh make so far. if the
key is password-protected, but no password was given, a new exception
(PasswordRequiredException) is raised so an outer layer can ask for a password
and try again.
Diffstat (limited to 'demo_server.py')
-rwxr-xr-x | demo_server.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/demo_server.py b/demo_server.py index a80b7f9e..6447d4a0 100755 --- a/demo_server.py +++ b/demo_server.py @@ -37,6 +37,7 @@ class ServerTransport(paramiko.Transport): return self.AUTH_FAILED def check_auth_publickey(self, username, key): + print 'Auth attempt with key: ' + paramiko.util.hexify(key.get_fingerprint()) if (username == 'robey') and (key == self.good_pub_key): return self.AUTH_SUCCESSFUL return self.AUTH_FAILED @@ -66,6 +67,7 @@ try: sock.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) sock.bind(('', 2200)) except Exception, e: + print '*** Bind failed: ' + str(e) traceback.print_exc() sys.exit(1) |