summaryrefslogtreecommitdiff
path: root/test/integration/test-bug-595691-empty-and-broken-archive-files
Commit message (Collapse)AuthorAgeFilesLines
* avoid using global PendingError to avoid failing too often too soonDavid Kalnischkies2015-09-141-0/+2
| | | | | | | | | | | | | | | | | | | Our error reporting is historically grown into some kind of mess. A while ago I implemented stacking for the global error which is used in this commit now to wrap calls to functions which do not report (all) errors via return, so that only failures in those calls cause a failure to propergate down the chain rather than failing if anything (potentially totally unrelated) has failed at some point in the past. This way we can avoid stopping the entire acquire process just because a single source produced an error for example. It also means that after the acquire process the cache is generated – even if the acquire process had failures – as we still have the old good data around we can and should generate a cache for (again). There are probably more instances of this hiding, but all these looked like the easiest to work with and fix with reasonable (aka net-positive) effects.
* drop extra newline in 'Failed to fetch' and 'GPG error' messageDavid Kalnischkies2015-08-101-2/+0
| | | | | | I never understood why there is an extra newline in those messages, so now is as good time as any to drop them. Lets see if someone complains with a good reason to keep it…
* show item ID in Hit, Ign and Err lines as wellDavid Kalnischkies2015-06-151-7/+7
| | | | | | | | Again, consistency is the main sellingpoint here, but this way it is now also easier to explain that some files move through different stages and lines are printed for them hence multiple times: That is a bit hard to believe if the number is changing all the time, but now that it keeps consistent.
* call URIStart in cdrom and file methodDavid Kalnischkies2015-06-151-16/+4
| | | | | | | | | | | | | | | All other methods call it, so they should follow along even if the work they do afterwards is hardly breathtaking and usually results in a URIDone pretty soon, but the acquire system tells the individual item about this via a virtual method call, so even through none of our existing items contains any critical code in these, maybe one day they might. Consistency at least once… Which is also why this has a good sideeffect: file: and cdrom: requests appear now in the 'apt-get update' output. Finally - it never made sense to hide them for me. Okay, I guess it made before the new hit behavior, but now that you can actually see the difference in an update it makes sense to see if a file: repository changed or not as well.
* show URI.Path in all acquire item descriptionsDavid Kalnischkies2015-06-111-2/+3
| | | | | | | | | | | | | | It is a rather strange sight that index items use SiteOnly which strips the Path, while e.g. deb files are downloaded with NoUserPassword which does not. Important to note here is that for the file transport Path is pretty important as there is no Host which would be displayed by Site, which always resulted in "interesting" unspecific errors for "file:". Adding a 'middle' ground between the two which does show the Path but potentially modifies it (it strips a pending / at the end if existing) solves this "file:" issue, syncs the output and in the end helps to identify which file is meant exactly in progress output and co as a single site can have multiple repositories in different paths.
* rework hashsum verification in the acquire systemDavid Kalnischkies2015-06-091-1/+1
| | | | | | | | | | | | | | | | | | | | | Having every item having its own code to verify the file(s) it handles is an errorprune process and easy to break, especially if items move through various stages (download, uncompress, patching, …). With a giant rework we centralize (most of) the verification to have a better enforcement rate and (hopefully) less chance for bugs, but it breaks the ABI bigtime in exchange – and as we break it anyway, it is broken even harder. It shouldn't effect most frontends as they don't deal with the acquire system at all or implement their own items, but some do and will need to be patched (might be an opportunity to use apt on-board material). The theory is simple: Items implement methods to decide if hashes need to be checked (in this stage) and to return the expected hashes for this item (in this stage). The verification itself is done in worker message passing which has the benefit that a hashsum error is now a proper error for the acquire system rather than a Done() which is later revised to a Failed().
* Only support Translation-* that are listed in the {In,}Release fileMichael Vogt2014-10-291-10/+0
| | | | | | | | Handle Translation-* files exactly like Packages files (with the expection that it is ok if a download of them fails). Remove all "guessing" on apts side. This will elimimnate a bunch of errors releated to captive portals and similar. Its also more correct and removes another potential attack vector.
* display errortext for all Err as well as Ign logsDavid Kalnischkies2014-10-071-1/+1
| | | | | | | consistently using Item::Failed in all specializec classes helps setting up some information bits otherwise unset, so some errors had an empty reason as an error. Ign is upgraded to display the error message we ignored to further help in understanding what happens.
* Merge branch 'debian/sid' into debian/experimentalMichael Vogt2014-09-291-32/+3
|\ | | | | | | | | Conflicts: apt-pkg/acquire-item.cc
| * rewrite compressed indexes test to check with all compressorsDavid Kalnischkies2014-09-251-31/+2
| | | | | | | | Git-Dch: Ignore
| * generalize Acquire::GzipIndexMichael Vogt2014-09-211-1/+1
| |
* | tests: be able to disable "Fetched …" statistics messageDavid Kalnischkies2014-05-091-1/+1
|/ | | | | | | | The line contains everchanging execution statistics which is harmful for testcases as they need to filter out such lines, but this is hard so we can just add an option to disable them instead and be done. Git-Dch: Ignore
* merged patch from Daniel Hartwig to fix URI and proxy releated issuesMichael Vogt2013-05-081-7/+7
|
* * SECURITY UPDATE: InRelease verification bypassMichael Vogt2013-03-141-19/+11
| | | | | | | | | - CVE-2013-1051 * apt-pkg/deb/debmetaindex.cc, test/integration/test-bug-595691-empty-and-broken-archive-files, test/integration/test-releasefile-verification: - disable InRelease downloading until the verification issue is fixed, thanks to Ansgar Burchardt for finding the flaw
* use xz-utils in the testcases instead of lzma and ensure that we reallyDavid Kalnischkies2012-04-111-4/+8
| | | | ignore the presents (or absence) of lzma if we decided to use xz
* run integration tests on my new amd64 box without failuresDavid Kalnischkies2011-10-111-7/+1
|
* remove the caches in 'apt-get update', too, as they will beDavid Kalnischkies2011-08-221-1/+1
| | | invalid in most cases anyway
* test the xz compressor, tooDavid Kalnischkies2011-02-221-3/+5
|
* * merged lp:~evfool/apt/fix641673:Michael Vogt2011-02-101-2/+2
| | | | * merged lp:~evfool/apt/fix418552: - Grammar fix for bug LP: #418552, thanks to Robert Roth
* - download and use i18n/Index to choose which Translations to downloadDavid Kalnischkies2011-01-281-14/+14
| | | | * apt-pkg/aptconfiguration.cc: - remove the inbuilt Translation files whitelist
* - change the internal handling of Extensions in pkgAcqIndexDavid Kalnischkies2011-01-261-4/+5
| | | | | - add a special uncompressed compression type to prefer those files * methods/{gzip,bzip}.cc: - print a good error message if FileSize() is zero
* - try downloading clearsigned InRelease before trying Release.gpgDavid Kalnischkies2011-01-201-20/+12
| | | | * apt-pkg/deb/deblistparser.cc: - rewrite LoadReleaseInfo to cope with clearsigned Releasefiles
* do not touch Packages and Sources in the framework if the files doDavid Kalnischkies2010-11-301-0/+1
| | | | not exist to not generate sources.list entries later for them
* * apt-pkg/contrib/fileutl.cc:David Kalnischkies2010-10-211-51/+108
| | | | | | | - Add a FileFd::FileSize() method to get the size of the underlying file and not the size of the content in the file as FileFd::Size() does - the sizes can differ since the direct gzip integration * methods/{gzip,bzip2}.cc: - use FileSize() to determine if the file is invalid (Closes: #600852)
* tests/integration/test-*: remove a bunch of "local" that are used outside ↵Michael Vogt2010-10-131-1/+1
| | | | funtions (bash complains)
* fix the testcases which were broken by the new space between number and unitDavid Kalnischkies2010-09-291-1/+1
|
* add a simple testcase for the previously fixed bug 595691 to checkDavid Kalnischkies2010-09-091-0/+91
in future that APT plays considerable well with empty archives