Skip to content

Commit ecfed4f

Browse files
authored
[3.7] gh-95778: add doc missing in some places (GH-100627) (GH-101631)
(cherry picked from commit 4652182)
1 parent d729c5c commit ecfed4f

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

Misc/python.man

+9
Original file line numberDiff line numberDiff line change
@@ -309,6 +309,10 @@ Set implementation specific option. The following options are available:
309309
locale-aware mode. -X utf8=0 explicitly disables UTF-8 mode (even when it would
310310
otherwise activate automatically). See PYTHONUTF8 for more details
311311

312+
-X int_max_str_digits=number: limit the size of int<->str conversions.
313+
This helps avoid denial of service attacks when parsing untrusted data.
314+
The default is sys.int_info.default_max_str_digits. 0 disables.
315+
312316
.TP
313317
.B \-x
314318
Skip the first line of the source. This is intended for a DOS
@@ -476,6 +480,11 @@ values.
476480

477481
The integer must be a decimal number in the range [0,4294967295]. Specifying
478482
the value 0 will disable hash randomization.
483+
.IP PYTHONINTMAXSTRDIGITS
484+
Limit the maximum digit characters in an int value
485+
when converting from a string and when converting an int back to a str.
486+
A value of 0 disables the limit. Conversions to or from bases 2, 4, 8,
487+
16, and 32 are never limited.
479488
.IP PYTHONMALLOC
480489
Set the Python memory allocators and/or install debug hooks. The available
481490
memory allocators are

0 commit comments

Comments
 (0)