Package paramiko :: Module server :: Class InteractiveQuery
[frames] | no frames]

Class InteractiveQuery

source code

object --+
         |
        InteractiveQuery

A query (set of prompts) for a user during interactive authentication.

Instance Methods
 
__init__(self, name='', instructions='', *prompts)
Create a new interactive query to send to the client.
source code
 
add_prompt(self, prompt, echo=True)
Add a prompt to this query.
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties

Inherited from object: __class__

Method Details

__init__(self, name='', instructions='', *prompts)
(Constructor)

source code 

Create a new interactive query to send to the client.  The name and
instructions are optional, but are generally displayed to the end
user.  A list of prompts may be included, or they may be added via
the `add_prompt` method.

:param str name: name of this query
:param str instructions:
    user instructions (usually short) about this query
:param str prompts: one or more authentication prompts

Overrides: object.__init__

add_prompt(self, prompt, echo=True)

source code 

Add a prompt to this query.  The prompt should be a (reasonably short)
string.  Multiple prompts can be added to the same query.

:param str prompt: the user prompt
:param bool echo:
    ``True`` (default) if the user's response should be echoed;
    ``False`` if not (for a password or similar)