Go to the latest version of this document.
search in docstrings

Search bar offers the following options:

- Term presence. The below example searches for documents that must contain “foo”, might contain “bar” and must not contain “baz”: `+foo bar -baz`
- Wildcards. The below example searches for documents with words beginning with “foo”: `foo*`
- Search in specific fields. The following search matches all objects in "twisted.mail" that matches “search”: `+qname:twisted.mail.* +search`

  Possible fields: 'name', 'qname' (fully qualified name), 'docstring', and 'kind'. Last two fields are only applicable if "search in docstrings" is enabled.

- Fuzzy matches. The following search matches all documents that have a word within 1 edit distance of “foo”: `foo~1`

Results provided by Lunr.js

# ``twisted`.`conch`.`checkers`.`UNIXAuthorizedKeysFiles``

class documentation

`class UNIXAuthorizedKeysFiles: (source)`

Constructor: `UNIXAuthorizedKeysFiles(userdb, parseKey)`

Implements interfaces: `twisted.conch.checkers.IAuthorizedKeysDB`

View In Hierarchy

Object that provides SSH public keys based on public keys listed in authorized_keys and authorized_keys2 files in UNIX user .ssh/ directories. If any of the files cannot be read, a message is logged but that file is otherwise ignored.

Present Since
15.0

Method | `__init__` | Initializes a new `UNIXAuthorizedKeysFiles`.
Method | `getAuthorizedKeys` | Gets an iterable of authorized keys that are valid for the given `avatarId`.
Instance Variable | `_parseKey` | Undocumented
Instance Variable | `_userdb` | Undocumented

def __init__(self, userdb: `Optional[UserDB]` = None, parseKey: `Callable[[bytes], keys.Key]` = keys.Key.fromString): (source)

Initializes a new `UNIXAuthorizedKeysFiles`.

Parameters
userdb:`Optional[UserDB]` | access to the Unix user account and password database (default is the Python module `pwd`, if available)
parseKey:`Callable[[bytes], keys.Key]` | a callable that takes a string and returns a `twisted.conch.ssh.keys.Key`, mainly to be used for testing. The default is `twisted.conch.ssh.keys.Key.fromString`.

def getAuthorizedKeys(self, username: `bytes`) -> `Iterable[keys.Key]`: (source)
from `twisted.conch.checkers.IAuthorizedKeysDB`

Gets an iterable of authorized keys that are valid for the given `avatarId`.

Parameters
username:`bytes` | Undocumented
avatarId:valid return value of `twisted.cred.checkers.ICredentialsChecker.requestAvatarId` | the ID of the avatar
Returns
`Iterable[keys.Key]` | an iterable of `twisted.conch.ssh.keys.Key`

_parseKey = (source)

Undocumented

_userdb: `UserDB` = (source)

Undocumented