summaryrefslogtreecommitdiff
path: root/apt-private/private-download.h
Commit message (Collapse)AuthorAgeFilesLines
* drop some needlessly public declarations in libapt-privateDavid Kalnischkies2015-11-291-3/+3
| | | | Git-Dch: Ignore
* hidden support more apt-get/apt-cache commands in aptDavid Kalnischkies2015-11-041-0/+8
| | | | | | | | | | | | | | apt is supposed to be a user-friendly interface, so while these commands are usually poweruser material and therefore do not need to be shown in general introduction manpages/help messages its of no use to not allow users to use them. This includes clean, autoclean, build-dep, source, download, changelog, depends, rdepends and showsrc – it doesn't include more non-interactive commands like dump or xvcg as those are usually used by scripts if at all. Closes: 778234, 780700, 781237
* new quiet level -qq for apt to hide progress outputDavid Kalnischkies2015-11-041-2/+10
| | | | | | | | | -q is for logging and -qqq (old -qq) basically kills every output expect errors, so there should be a way of declaring a middleground in which the output of e.g. 'update' isn't as verbose, but still shows some things. The test framework was actually making use of by accident as it ignored the quiet level in output setup for apt before. Eventually we should figure out some better quiet levels for all tools…
* if file is inaccessible for _apt, disable privilege drop in acquireDavid Kalnischkies2015-08-311-2/+0
| | | | | | | | | | | | | | | We had a very similar method previously for our own private usage, but with some generalisation we can move this check into the acquire system proper so that all frontends profit from this compatibility change. As we are disabling a security feature here a warning is issued and frontends are advised to consider reworking their download logic if possible. Note that this is implemented as an all or nothing situation: We can't just (not) drop privileges for a subset of the files in a fetcher, so in case you have to download some files with and some without you need to use two fetchers.
* show or-groups in not-installed recommends and suggests listsDavid Kalnischkies2015-08-101-1/+2
| | | | | | | | Further abstracting our new ShowList allows to use it for containers of strings as well giving us the option to implement an or-groups display for the recommends and suggests lists which is a nice trick given that it also helps with migrating the last remaining other cases of old ShowList.
* check for available space, excluding root reserved blocksDavid Kalnischkies2014-10-151-0/+2
| | | | | | | | | | | We are checking the space requirements for ages, but the check uses the free blocks count, which includes the blocks reserved for usage by root. Now that we use an unprivileged user it has no access to these blocks anymore – and more importantly these blocks are a reserve, they shouldn't be used by apt without special encouragement by the user as it would be bad to have dpkg run out of diskspace and maintainerscripts like man-db skip certain actions if not enough space is available freely.
* don't drop privileges if _apt has not enough rightsDavid Kalnischkies2014-10-151-1/+5
| | | | | | | | | | | | | | | | | Privilege dropping breaks download/source/changelog commands as they require the _apt user to have write permissions in the current directory, which is e.g. the case in /tmp, but not in /root, so we disable the privilege dropping if we deal with such a directory based on idea and code by Michael Vogt. The alternative would be to download always to a temp directory and move it then done, but this breaks partial file support. To resolve this, we could move to one of our partial/ directories, but this would require a lock which would block root from using two of these commands in parallel. As both seems unacceptable we instead let the user choose what to do: Either a directory is setupped for _apt, downloading as root is accepted or – which is potentially even better – an unprivileged user is used for the commands.
* Show unauthenticated warning for source packages as wellMichael Vogt2014-06-021-0/+6
| | | | | | | | | This will show the same unauthenticated warning for source packages as for binary packages and will not download a source package if it is unauthenticated. This can be overridden with --allow-unauthenticated Closes: #749795
* enable fvisibility=hidden for our private libraryDavid Kalnischkies2014-03-211-2/+4
| | | | | | | | | | While it is a huge undertaking to enable it for our public libraries as basically everything we exported so far could be seen as public interface our private library is new and under our full control, so we can do whatever we like with it. The benefits are not that big in return of course, but it reduces the size a bit, so thats great nontheless. Git-Dch: ignore
* cleanup headers and especially #includes everywhereDavid Kalnischkies2014-03-131-1/+1
| | | | | | | | Beside being a bit cleaner it hopefully also resolves oddball problems I have with high levels of parallel jobs. Git-Dch: Ignore Reported-By: iwyu (include-what-you-use)
* put fetch errors in 'source' on our errorstackDavid Kalnischkies2013-10-031-0/+9
refactor the fetching process so that it looks more like the others we have in the hope that we can reuse code in the future. This is a soft interface change as 'source' previously printed errors directly on stderr, while it will now push it onto our usual error stack.