<feed xmlns='http://www.w3.org/2005/Atom'>
<title>python.git/Doc/using, branch 3.8</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<id>http://dangofactory.net/cgit/cgit.cgi/Server/python.git/atom/Doc/using?h=3.8</id>
<link rel='self' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/atom/Doc/using?h=3.8'/>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/'/>
<updated>2024-07-22T15:08:28Z</updated>
<entry>
<title>[3.8] gh-121957: Emit audit events for python -i and python -m asyncio (GH-122121)</title>
<updated>2024-07-22T15:08:28Z</updated>
<author>
<name>Łukasz Langa</name>
<email>lukasz@langa.pl</email>
</author>
<published>2024-07-22T15:08:28Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=1fb69b324720d9e0463c8fd52bd5737837167162'/>
<id>urn:sha1:1fb69b324720d9e0463c8fd52bd5737837167162</id>
<content type='text'>
</content>
</entry>
<entry>
<title>[3.8] gh-95778: CVE-2020-10735: Prevent DoS by very large int() (#96503)</title>
<updated>2022-09-05T20:26:09Z</updated>
<author>
<name>Gregory P. Smith</name>
<email>greg@krypto.org</email>
</author>
<published>2022-09-05T20:26:09Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=b5e331fdb38684808ffc540d53e8595bdc408b89'/>
<id>urn:sha1:b5e331fdb38684808ffc540d53e8595bdc408b89</id>
<content type='text'>
* Correctly pre-check for int-to-str conversion

Converting a large enough `int` to a decimal string raises `ValueError` as expected. However, the raise comes _after_ the quadratic-time base-conversion algorithm has run to completion. For effective DOS prevention, we need some kind of check before entering the quadratic-time loop. Oops! =)

The quick fix: essentially we catch _most_ values that exceed the threshold up front. Those that slip through will still be on the small side (read: sufficiently fast), and will get caught by the existing check so that the limit remains exact.

The justification for the current check. The C code check is:
```c
max_str_digits / (3 * PyLong_SHIFT) &lt;= (size_a - 11) / 10
```

In GitHub markdown math-speak, writing $M$ for `max_str_digits`, $L$ for `PyLong_SHIFT` and $s$ for `size_a`, that check is:
$$\left\lfloor\frac{M}{3L}\right\rfloor \le \left\lfloor\frac{s - 11}{10}\right\rfloor$$

From this it follows that
$$\frac{M}{3L} &lt; \frac{s-1}{10}$$
hence that
$$\frac{L(s-1)}{M} &gt; \frac{10}{3} &gt; \log_2(10).$$
So
$$2^{L(s-1)} &gt; 10^M.$$
But our input integer $a$ satisfies $|a| \ge 2^{L(s-1)}$, so $|a|$ is larger than $10^M$. This shows that we don't accidentally capture anything _below_ the intended limit in the check.

&lt;!-- gh-issue-number: gh-95778 --&gt;
* Issue: gh-95778
&lt;!-- /gh-issue-number --&gt;

Co-authored-by: Gregory P. Smith [Google LLC] &lt;greg@krypto.org&gt;
Co-authored-by: Christian Heimes &lt;christian@python.org&gt;
Co-authored-by: Mark Dickinson &lt;dickinsm@gmail.com&gt;</content>
</entry>
<entry>
<title>Fix broken links and improve stand-alone tools list in FAQ GH-25610</title>
<updated>2021-04-26T01:43:28Z</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2021-04-26T01:43:28Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=f28a59c13efb3db021e1eb404f74bd10b0c8036e'/>
<id>urn:sha1:f28a59c13efb3db021e1eb404f74bd10b0c8036e</id>
<content type='text'>
(cherry picked from commit d28b34695301ec99a9334ad8d69b6092f4f703d5)

Co-authored-by: Andre Delfino &lt;adelfino@gmail.com&gt;</content>
</entry>
<entry>
<title>[3.8] [doc] Document VIRTUAL_ENV environment variable (GH-21970) (GH-24363)</title>
<updated>2021-03-01T15:07:31Z</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2021-03-01T15:07:31Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=6900a515c8410795f9a8ef2ad38740847a919b6d'/>
<id>urn:sha1:6900a515c8410795f9a8ef2ad38740847a919b6d</id>
<content type='text'>
(cherry picked from commit 3584d4b64a5373440f78237eac734831cfd83f79)</content>
</entry>
<entry>
<title>Remove all links to mingw.org (GH-24552)</title>
<updated>2021-02-18T20:07:24Z</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2021-02-18T20:07:24Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=f03b61aaed28e005305210979261d5040c9df1aa'/>
<id>urn:sha1:f03b61aaed28e005305210979261d5040c9df1aa</id>
<content type='text'>
This lease on this domain has lapsed. This not only makes these dead links, but a potential attack vector for readers of python.org as the domain can be obtained by an untrustworthy party.

I considered redirecting these links to http://mingw-w64.org/ which is a maintained fork of mingw, but beyond my unfamiliarity with the exact level of compatibility, at the time of this PR that site had an expired cert and so is not much of a vulnerability fix.

Automerge-Triggered-By: GH:Mariatta
(cherry picked from commit 743932d50815edbe4ffd530ae091c53ae47dd34b)

Co-authored-by: Jeremy Paige &lt;ucodery@gmail.com&gt;</content>
</entry>
<entry>
<title>Add link to Microsoft docs for limitations in Windows Store package (GH-24422)</title>
<updated>2021-02-03T01:23:27Z</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2021-02-03T01:23:27Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=12ec8ce471c5bae2c5ba8ce0d50dd59fc8d233c6'/>
<id>urn:sha1:12ec8ce471c5bae2c5ba8ce0d50dd59fc8d233c6</id>
<content type='text'>
(cherry picked from commit 1ba08a121a25fcf7c947d8d37e72e46dae59168c)

Co-authored-by: Steve Dower &lt;steve.dower@python.org&gt;</content>
</entry>
<entry>
<title>bpo-42339: Adds note about KB2533623 to embeddable package docs (GH-23322)</title>
<updated>2020-11-16T21:28:29Z</updated>
<author>
<name>Steve Dower</name>
<email>steve.dower@python.org</email>
</author>
<published>2020-11-16T21:28:29Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=fa86614078f1f700f350f98486dddf83587ab69e'/>
<id>urn:sha1:fa86614078f1f700f350f98486dddf83587ab69e</id>
<content type='text'>
</content>
</entry>
<entry>
<title>bpo-30612: Tweak Windows registry path syntax in the docs (GH-20281)</title>
<updated>2020-10-20T12:11:25Z</updated>
<author>
<name>Miss Skeleton (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2020-10-20T12:11:25Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=f53ea8adaecacfe8c1e4a093136fb5318b15d779'/>
<id>urn:sha1:f53ea8adaecacfe8c1e4a093136fb5318b15d779</id>
<content type='text'>
(cherry picked from commit ff1ae3dd334faa2006394c2318db385cdc42030a)

Co-authored-by: Zackery Spytz &lt;zspytz@gmail.com&gt;</content>
</entry>
<entry>
<title>bpo-41192: Fix some broken anchors for audit event entries (GH-21310) (GH-22770)</title>
<updated>2020-10-19T18:52:27Z</updated>
<author>
<name>Miss Skeleton (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2020-10-19T18:52:27Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=ec18c468b8aed4b4a3d1942ae18b96d8efebe04b'/>
<id>urn:sha1:ec18c468b8aed4b4a3d1942ae18b96d8efebe04b</id>
<content type='text'>
(cherry picked from commit ebc8c3828779374b9be4fae5c8ffc0059d36ac8c)

Co-authored-by: Saiyang Gou &lt;gousaiyang@163.com&gt;</content>
</entry>
<entry>
<title>bpo-40831: Remove an incorrect statement in the Windows docs (GH-20570)</title>
<updated>2020-06-01T15:53:33Z</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2020-06-01T15:53:33Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=d0dc369a90e356bf2eba651816feb7ad736ce28a'/>
<id>urn:sha1:d0dc369a90e356bf2eba651816feb7ad736ce28a</id>
<content type='text'>
(cherry picked from commit c8966667bbdb284c3780ef6cec8a3870935a6bb7)

Co-authored-by: Zackery Spytz &lt;zspytz@gmail.com&gt;</content>
</entry>
</feed>
