diff options
Diffstat (limited to 'lang/python/src/callbacks.py')
-rw-r--r-- | lang/python/src/callbacks.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lang/python/src/callbacks.py b/lang/python/src/callbacks.py index b25a9a74..e8a9c432 100644 --- a/lang/python/src/callbacks.py +++ b/lang/python/src/callbacks.py @@ -20,6 +20,7 @@ del absolute_import, print_function, unicode_literals from getpass import getpass + def passphrase_stdin(hint, desc, prev_bad, hook=None): """This is a sample callback that will read a passphrase from the terminal. The hook here, if present, will be used to describe @@ -32,10 +33,12 @@ def passphrase_stdin(hint, desc, prev_bad, hook=None): print("Please supply %s' password%s:" % (hint, why)) return getpass() + def progress_stdout(what, type, current, total, hook=None): print("PROGRESS UPDATE: what = %s, type = %d, current = %d, total = %d" %\ (what, type, current, total)) + def readcb_fh(count, hook): """A callback for data. hook should be a Python file-like object.""" if count: |