HTTP Clients

PyMailcap

Python stdlib module — mailcap. Auto-indexed from CDN. Method-level security roles have not been annotated; rule writers should inspect the source before use.

Other Methods

.findmatch()Neutral
#
Signature
findmatch(caps, MIMEtype, key, filename, plist)

Find a match for a mailcap entry.

.findparam()Neutral
#
Signature
findparam(name, plist)

findparam function.

.getcaps()Neutral
#
Signature
getcaps()

Return a dictionary containing the mailcap database.

.lineno_sort_key()Neutral
#
Signature
lineno_sort_key(entry)

lineno_sort_key function.

.listmailcapfiles()Neutral
#
Signature
listmailcapfiles()

Return a list of all mailcap files found on the system.

.lookup()Neutral
#
Signature
lookup(caps, MIMEtype, key)

lookup function.

.parsefield()Neutral
#
Signature
parsefield(line, i, n)

Separate one key-value pair in a mailcap entry.

.parseline()Neutral
#
Signature
parseline(line)

Parse one entry in a mailcap file and return a dictionary.

.readmailcapfile()Neutral
#
Signature
readmailcapfile(fp)

Read a mailcap file and return a dictionary keyed by MIME type.

.show()Neutral
#
Signature
show(caps)

show function.

Fully-Qualified Names

FQNField
mailcapfqns[0]

Wrong FQN → 0 findings. Verify with: change fqns to garbage → must produce 0 results.

Import

rule.py
import mailcap