plainbox.impl.secure.qualifiers – Job Qualifiers

Qualifiers are callable objects that can be used to ‘match’ a job definition to some set of rules.

class plainbox.impl.secure.qualifiers.CompositeQualifier(inclusive_qualifier_list, exclusive_qualifier_list)[source]

A JobQualifier that has qualifies jobs matching any inclusive qualifiers while not matching all of the exclusive qualifiers

designates(job)[source]
class plainbox.impl.secure.qualifiers.NameJobQualifier(name)[source]

A JobQualifier that designates a single job with a particular name

designates(job)[source]
class plainbox.impl.secure.qualifiers.RegExpJobQualifier(pattern)[source]

A JobQualifier that designates jobs by matching their name to a regular expression

designates(job)[source]
pattern_text[source]

text of the regular expression embedded in this qualifier

class plainbox.impl.secure.qualifiers.WhiteList(pattern_list, name=None)[source]

A qualifier that understands checkbox whitelist files.

A whitelist file is a plain text, line oriented file. Each line represents a regular expression pattern that can be matched against the name of a job.

The file can contain simple shell-style comments that begin with the pound or hash key (#). Those are ignored. Comments can span both a fraction of a line as well as the whole line.

For historical reasons each pattern has an implicit ‘^’ and ‘$’ prepended and appended (respectively) to the actual pattern specified in the file.

classmethod from_file(pathname)[source]

Load and initialize the WhiteList object from the specified file.

Parameters:pathname – file to load
Returns:a fresh WhiteList object
name[source]

name of this WhiteList (might be None)

Previous topic

plainbox.impl.secure.providers.v1 – Implementation of V1 provider

Next topic

plainbox.impl.secure.rfc822 – RFC822 parser

This Page