'Runs some overall archive checks.
fatal: if the archive is not valid and fatal is True, it will raise
an error, otherwise it will return False.'

def is_valid(self, fatal=True):

    try:
        self.zip = zipfile.ZipFile(self.source, self.mode)
    except (zipfile.BadZipfile, IOError):
        if fatal:
            log.info('Error    extracting', exc_info=True)
            raise
        return False
    self.info = self.zip.infolist()
    sum_size = 0
    for info in self.info:
        if (('..' in info.filename) or info.filename.startswith('/')):
            log.error((u'Extraction    error,    invalid    file    name    (%s)    in    archive:    %s' % (info.filename, self.source)))
            raise forms.ValidationError(_(u'Invalid    file    name    in    archive:    {0}').format(info.filename))
        if (info.file_size > settings.FILE_UNZIP_SIZE_LIMIT):
            log.error((u'Extraction    error,    file    too    big    (%s)    in    archive    %s' % (info.filename, self.source)))
            raise forms.ValidationError(_(u'File    exceeding    size    limit    in    archive:    {0}').format(info.filename))
        sum_size += info.file_size
    if (sum_size > settings.FILE_UNZIP_SIZE_LIMIT):
        log.error(('Extraction    error,    total    size    of    files    too    big    (%s)    in    archive:    %s' % (sum_size, self.source)))
        raise forms.ValidationError(_('Total    size    of    files    exceeding    limit    in    archive:    {0}').format(info.filename))
    return True
