<feed xmlns='http://www.w3.org/2005/Atom'>
<title>apt/methods/http.h, branch 2.9.27</title>
<subtitle>Debians commandline package manager</subtitle>
<id>https://git.kalnischkies.de/apt/atom?h=2.9.27</id>
<link rel='self' href='https://git.kalnischkies.de/apt/atom?h=2.9.27'/>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/'/>
<updated>2025-01-05T22:16:08Z</updated>
<entry>
<title>Drop usage of macro APT_OVERRIDE for simple override</title>
<updated>2025-01-05T22:16:08Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2024-12-26T19:41:53Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=f73593a4034d9eec0ec4466b8e173d4a4daece1f'/>
<id>urn:sha1:f73593a4034d9eec0ec4466b8e173d4a4daece1f</id>
<content type='text'>
We were rather inconsistent in using it and as our public headers
contain deduction guides (a c++17 feature) it seems silly to try to hide
a c++11 feature in a macro, so lets stop this charade and drop the
macro and while we are changing all these lines lets apply [[nodiscard]]
(another c++17 feature) and other suggestions from clang-tidy and
formatting for a little more consistency.
</content>
</entry>
<entry>
<title>Tag hidden acquire classes as final for devirtualization</title>
<updated>2024-11-22T12:13:25Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2024-11-19T22:42:44Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=8c760266c8c736bff62055c008ab74d78f3ed82a'/>
<id>urn:sha1:8c760266c8c736bff62055c008ab74d78f3ed82a</id>
<content type='text'>
gcc reports `warning: Declaring type ‘class X’ final would
enable devirtualization of Y calls [-Wsuggest-final-types]`.
Not that this would massively improve performance, but it
shouldn't hurt telling the compiler what is obvious for a human.
</content>
</entry>
<entry>
<title>http: Fully flush local file both before/after server read</title>
<updated>2020-08-11T11:09:04Z</updated>
<author>
<name>Julian Andres Klode</name>
<email>julian.klode@canonical.com</email>
</author>
<published>2020-08-11T08:55:09Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=73780d7f664a4ea1da55527d726b4c9c7753f1fb'/>
<id>urn:sha1:73780d7f664a4ea1da55527d726b4c9c7753f1fb</id>
<content type='text'>
We do not want to end up in a code path while reading content
from the server where we have local data left to write, which
can happen if a previous read included both headers and content.

Restructure Flush() to accept a new argument to allow incomplete
flushs (which do not match our limit), so that it can flush as
far as possible, and modify Go() and use that before and after
reading from the server.
</content>
</entry>
<entry>
<title>Use steady clock source for bandwidth limitation</title>
<updated>2018-05-29T11:04:59Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2018-05-26T19:26:03Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=f6655a1138a11e80884959014939a25f23a1e308'/>
<id>urn:sha1:f6655a1138a11e80884959014939a25f23a1e308</id>
<content type='text'>
Using the time of day for this is slightly wrong just like it is for
progress, just less visible.
</content>
</entry>
<entry>
<title>Remove unused time-tracking from http method</title>
<updated>2018-05-28T15:59:38Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2018-05-26T19:28:55Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=2fc09a90e7e62a4c3e4a67506bf90fcf4c6ccfaf'/>
<id>urn:sha1:2fc09a90e7e62a4c3e4a67506bf90fcf4c6ccfaf</id>
<content type='text'>
The Stats method isn't called anywhere, was partly commented out before,
but we keep updating the time for it – lets avoid this pointless busywork.

Gbp-Dch: Ignore
</content>
</entry>
<entry>
<title>Remove obsolete RCS keywords</title>
<updated>2018-05-07T11:41:31Z</updated>
<author>
<name>Guillem Jover</name>
<email>guillem@debian.org</email>
</author>
<published>2018-05-06T20:32:41Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=164f1b78d1849a0f33df7352875f86e28f5de06a'/>
<id>urn:sha1:164f1b78d1849a0f33df7352875f86e28f5de06a</id>
<content type='text'>
Prompted-by: Jakub Wilk &lt;jwilk@debian.org&gt;
</content>
</entry>
<entry>
<title>report transient errors as transient errors</title>
<updated>2017-12-13T22:56:29Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2017-10-25T22:57:26Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=47c0bdc310c8cd62374ca6e6bb456dd183bdfc07'/>
<id>urn:sha1:47c0bdc310c8cd62374ca6e6bb456dd183bdfc07</id>
<content type='text'>
The Fail method for acquire methods has a boolean parameter indicating
the transient-nature of a reported error. The problem with this is that
Fail is called very late at a point where it is no longer easily
identifiable if an error is indeed transient or not, so some calls were
and some weren't and the acquire system would later mostly ignore the
transient flag and guess by using the FailReason instead.

Introducing a tri-state enum we can pass the information about fatal or
transient errors through the callstack to generate the correct fails.
</content>
</entry>
<entry>
<title>allow the auth.conf to be root:root owned</title>
<updated>2017-07-26T17:09:04Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2017-07-07T20:21:44Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=881ec045b6660e2fe0c6953720260e380ceeeb99'/>
<id>urn:sha1:881ec045b6660e2fe0c6953720260e380ceeeb99</id>
<content type='text'>
Opening the file before we drop privileges in the methods allows us to
avoid chowning in the acquire main process which can apply to the wrong
file (imagine Binary scoped settings) and surprises users as their
permission setup is overridden.

There are no security benefits as the file is open, so an evil method
could as before read the contents of the file, but it isn't worse than
before and we avoid permission problems in this setup.
</content>
</entry>
<entry>
<title>http: Add support for CONNECT proxying to HTTPS locations</title>
<updated>2017-06-30T13:00:41Z</updated>
<author>
<name>Julian Andres Klode</name>
<email>jak@debian.org</email>
</author>
<published>2017-06-30T11:24:04Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=64207dad49f1c803d2b004ccf8fc6432789a8cc2'/>
<id>urn:sha1:64207dad49f1c803d2b004ccf8fc6432789a8cc2</id>
<content type='text'>
Proxying HTTPS traffic requires the proxy providing the
CONNECT method. This implements the client side of it,
although it is a bit hacky.

HTTP connect is a normal HTTP CONNECT request, followed
by a normal HTTP response, just that the body of the
response is the TCP stream of the target host.

We use a special wrapper in case there are data bytes
in the header packets - in that case, the bytes are
stored in a buffer and the buffer will be drained first,
afterwards the connection continues directly with the
TCP stream (with one more vcall).

Also: Do not send full URI to https destinations when proxying,
as we are directly interfacing with the destination data stream.
</content>
</entry>
<entry>
<title>methods: connect: Switch from int fds to new MethodFd</title>
<updated>2017-06-28T13:52:38Z</updated>
<author>
<name>Julian Andres Klode</name>
<email>jak@debian.org</email>
</author>
<published>2017-06-28T08:55:08Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=5666084ecfe140aaa3f89388de557c2f875b4244'/>
<id>urn:sha1:5666084ecfe140aaa3f89388de557c2f875b4244</id>
<content type='text'>
Use std::unique_ptr&lt;MethodFd&gt; everywhere we used an
integer-based file descriptor before. This allows us
to implement stuff like TLS support easily.

Gbp-Dch: ignore
</content>
</entry>
</feed>
