l.a.d.SignableTagFile : class documentation

Part of lp.archiveuploader.dscfile View In Hierarchy

Known subclasses: lp.archiveuploader.buildinfofile.BuildInfoFile, lp.archiveuploader.changesfile.ChangesFile, lp.archiveuploader.dscfile.DSCFile

Base class for signed file verification.
Method signer Undocumented
Method parse Parse the tag file, optionally verifying the signature.
Method parseAddress Parse an address, using the policy to decide if we should add a
Method _verifySignature Verify the signature on the file content.
@property
def signer(self):
Undocumented
def parse(self, verify_signature=True):
Parse the tag file, optionally verifying the signature.

If verify_signature is True, signingkey will be set to the signing IGPGKey, and only the verified content will be parsed. Otherwise, any signature will be stripped and the contained content parsed.

Will raise an UploadError if the tag file was unparsable, or if signature verification was requested but failed.

def _verifySignature(self, content, filename):
Verify the signature on the file content.

Raise UploadError if the signing key cannot be found in launchpad or if the GPG verification failed for any other reason.

Returns a tuple of the key (IGPGKey object) and the verified cleartext data.

def parseAddress(self, addr, fieldname='Maintainer'):
Parse an address, using the policy to decide if we should add a non-existent person or not.

Raise an UploadError if the parsing of the maintainer string fails for any reason, or if the email address then cannot be found within the launchpad database.

Return a dict containing the person's name, email address and person record within the launchpad database.

API Documentation for Launchpad, generated by pydoctor at 2018-02-21 00:00:11.