Linux server1.dn-server.com 4.18.0-553.89.1.lve.el8.x86_64 #1 SMP Wed Dec 10 13:58:50 UTC 2025 x86_64
LiteSpeed
Server IP : 195.201.204.189 & Your IP : 216.73.217.128
Domains :
Cant Read [ /etc/named.conf ]
User : beriska1
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
opt /
alt /
python37 /
lib64 /
python3.7 /
test /
Delete
Unzip
Name
Size
Permission
Date
Action
__pycache__
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
audiodata
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
capath
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
cjkencodings
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
data
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
decimaltestdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
dtracedata
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
eintrdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
encoded_modules
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
imghdrdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
libregrtest
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
sndhdrdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
subprocessdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
support
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
test_asyncio
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
test_email
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
test_import
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
test_importlib
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
test_json
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
test_tools
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
test_warnings
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
tracedmodules
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
xmltestdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:20
Sine-1000Hz-300ms.aif
60.25
KB
-rw-r--r--
2023-06-06 00:15
__init__.py
47
B
-rw-r--r--
2024-04-17 21:06
__main__.py
41
B
-rw-r--r--
2024-04-17 21:06
_test_multiprocessing.py
157.18
KB
-rw-r--r--
2024-04-17 21:06
allsans.pem
4.92
KB
-rw-r--r--
2023-06-06 00:15
ann_module.py
1.08
KB
-rw-r--r--
2024-04-17 21:06
ann_module2.py
519
B
-rw-r--r--
2024-04-17 21:06
ann_module3.py
448
B
-rw-r--r--
2024-04-17 21:06
audiotests.py
12.46
KB
-rw-r--r--
2024-04-17 21:06
autotest.py
209
B
-rw-r--r--
2024-04-17 21:06
bad_coding.py
24
B
-rw-r--r--
2024-04-17 21:06
bad_coding2.py
30
B
-rw-r--r--
2024-04-17 21:06
bad_getattr.py
61
B
-rw-r--r--
2024-04-17 21:06
bad_getattr2.py
77
B
-rw-r--r--
2024-04-17 21:06
bad_getattr3.py
139
B
-rw-r--r--
2024-04-17 21:06
badcert.pem
1.88
KB
-rw-r--r--
2023-06-06 00:15
badkey.pem
2.11
KB
-rw-r--r--
2023-06-06 00:15
badsyntax_3131.py
32
B
-rw-r--r--
2024-04-17 21:06
badsyntax_future10.py
95
B
-rw-r--r--
2024-04-17 21:06
badsyntax_future3.py
172
B
-rw-r--r--
2024-04-17 21:06
badsyntax_future4.py
153
B
-rw-r--r--
2024-04-17 21:06
badsyntax_future5.py
184
B
-rw-r--r--
2024-04-17 21:06
badsyntax_future6.py
161
B
-rw-r--r--
2024-04-17 21:06
badsyntax_future7.py
196
B
-rw-r--r--
2024-04-17 21:06
badsyntax_future8.py
122
B
-rw-r--r--
2024-04-17 21:06
badsyntax_future9.py
142
B
-rw-r--r--
2024-04-17 21:06
badsyntax_pep3120.py
14
B
-rw-r--r--
2024-04-17 21:06
bisect_cmd.py
4.86
KB
-rwxr-xr-x
2024-04-17 21:06
bytecode_helper.py
1.56
KB
-rw-r--r--
2024-04-17 21:06
cfgparser.1
67
B
-rw-r--r--
2023-06-06 00:15
cfgparser.2
19.02
KB
-rw-r--r--
2023-06-06 00:15
cfgparser.3
1.55
KB
-rw-r--r--
2023-06-06 00:15
clinic.test
36.31
KB
-rw-r--r--
2023-06-06 00:15
cmath_testcases.txt
141.05
KB
-rw-r--r--
2023-06-06 00:15
coding20731.py
18
B
-rw-r--r--
2024-04-17 21:06
curses_tests.py
1.22
KB
-rwxr-xr-x
2024-04-17 21:06
dataclass_module_1.py
837
B
-rw-r--r--
2024-04-17 21:06
dataclass_module_1_str.py
835
B
-rw-r--r--
2024-04-17 21:06
dataclass_module_2.py
756
B
-rw-r--r--
2024-04-17 21:06
dataclass_module_2_str.py
754
B
-rw-r--r--
2024-04-17 21:06
dataclass_textanno.py
126
B
-rw-r--r--
2024-04-17 21:06
datetimetester.py
230.63
KB
-rw-r--r--
2024-04-17 21:06
dis_module.py
76
B
-rw-r--r--
2024-04-17 21:06
doctest_aliases.py
240
B
-rw-r--r--
2024-04-17 21:06
double_const.py
1.18
KB
-rw-r--r--
2024-04-17 21:06
empty.vbs
70
B
-rw-r--r--
2023-06-06 00:15
exception_hierarchy.txt
1.78
KB
-rw-r--r--
2023-06-06 00:15
ffdh3072.pem
2.16
KB
-rw-r--r--
2023-06-06 00:15
final_a.py
411
B
-rw-r--r--
2024-04-17 21:06
final_b.py
411
B
-rw-r--r--
2024-04-17 21:06
floating_points.txt
15.92
KB
-rw-r--r--
2023-06-06 00:15
fork_wait.py
2.53
KB
-rw-r--r--
2024-04-17 21:06
formatfloat_testcases.txt
7.45
KB
-rw-r--r--
2023-06-06 00:15
future_test1.py
229
B
-rw-r--r--
2024-04-17 21:06
future_test2.py
149
B
-rw-r--r--
2024-04-17 21:06
gdb_sample.py
153
B
-rw-r--r--
2024-04-17 21:06
good_getattr.py
198
B
-rw-r--r--
2024-04-17 21:06
idnsans.pem
9.71
KB
-rw-r--r--
2023-06-06 00:15
ieee754.txt
3.21
KB
-rw-r--r--
2023-06-06 00:15
imp_dummy.py
63
B
-rw-r--r--
2024-04-17 21:06
inspect_fodder.py
1.24
KB
-rw-r--r--
2024-04-17 21:06
inspect_fodder2.py
1.77
KB
-rw-r--r--
2024-04-17 21:06
keycert.passwd.pem
4.13
KB
-rw-r--r--
2023-06-06 00:15
keycert.pem
3.96
KB
-rw-r--r--
2023-06-06 00:15
keycert2.pem
3.97
KB
-rw-r--r--
2023-06-06 00:15
keycert3.pem
9.22
KB
-rw-r--r--
2023-06-06 00:15
keycert4.pem
9.23
KB
-rw-r--r--
2023-06-06 00:15
keycertecc.pem
5.5
KB
-rw-r--r--
2023-06-06 00:15
list_tests.py
16.54
KB
-rw-r--r--
2024-04-17 21:06
lock_tests.py
28.26
KB
-rw-r--r--
2024-04-17 21:06
mailcap.txt
1.24
KB
-rw-r--r--
2023-06-06 00:15
make_ssl_certs.py
8.52
KB
-rw-r--r--
2024-04-17 21:06
mapping_tests.py
21.75
KB
-rw-r--r--
2024-04-17 21:06
math_testcases.txt
23.19
KB
-rw-r--r--
2023-06-06 00:15
memory_watchdog.py
859
B
-rw-r--r--
2024-04-17 21:06
mime.types
47.37
KB
-rw-r--r--
2023-06-06 00:15
mock_socket.py
3.53
KB
-rw-r--r--
2024-04-17 21:06
mod_generics_cache.py
1.13
KB
-rw-r--r--
2024-04-17 21:06
mp_fork_bomb.py
448
B
-rw-r--r--
2024-04-17 21:06
mp_preload.py
351
B
-rw-r--r--
2024-04-17 21:06
multibytecodec_support.py
14.17
KB
-rw-r--r--
2024-04-17 21:06
nokia.pem
1.88
KB
-rw-r--r--
2023-06-06 00:15
nullbytecert.pem
5.31
KB
-rw-r--r--
2023-06-06 00:15
nullcert.pem
0
B
-rw-r--r--
2023-06-06 00:15
outstanding_bugs.py
370
B
-rw-r--r--
2024-04-17 21:06
pickletester.py
108.89
KB
-rw-r--r--
2024-04-17 21:06
profilee.py
2.97
KB
-rw-r--r--
2024-04-17 21:06
pstats.pck
65.05
KB
-rw-r--r--
2023-06-06 00:15
pycacert.pem
5.52
KB
-rw-r--r--
2023-06-06 00:15
pycakey.pem
2.43
KB
-rw-r--r--
2023-06-06 00:15
pyclbr_input.py
648
B
-rw-r--r--
2024-04-17 21:06
pydoc_mod.py
713
B
-rw-r--r--
2024-04-17 21:06
pydocfodder.py
6.18
KB
-rw-r--r--
2024-04-17 21:06
pythoninfo.py
18.75
KB
-rw-r--r--
2024-04-17 21:06
randv2_32.pck
7.34
KB
-rw-r--r--
2023-06-06 00:15
randv2_64.pck
7.19
KB
-rw-r--r--
2023-06-06 00:15
randv3.pck
7.82
KB
-rw-r--r--
2023-06-06 00:15
re_tests.py
31.06
KB
-rwxr-xr-x
2024-04-17 21:06
recursion.tar
516
B
-rw-r--r--
2023-06-06 00:15
regrtest.py
1.34
KB
-rwxr-xr-x
2024-04-17 21:06
relimport.py
27
B
-rw-r--r--
2024-04-17 21:06
reperf.py
538
B
-rw-r--r--
2024-04-17 21:06
revocation.crl
800
B
-rw-r--r--
2023-06-06 00:15
sample_doctest.py
1.02
KB
-rw-r--r--
2024-04-17 21:06
sample_doctest_no_docstrings.py
227
B
-rw-r--r--
2024-04-17 21:06
sample_doctest_no_doctests.py
269
B
-rw-r--r--
2024-04-17 21:06
secp384r1.pem
256
B
-rw-r--r--
2023-06-06 00:15
selfsigned_pythontestdotnet.pem
2.08
KB
-rw-r--r--
2023-06-06 00:15
seq_tests.py
14.18
KB
-rw-r--r--
2024-04-17 21:06
sgml_input.html
8.1
KB
-rw-r--r--
2023-06-06 00:15
signalinterproctester.py
2.7
KB
-rw-r--r--
2024-04-17 21:06
sortperf.py
4.69
KB
-rw-r--r--
2024-04-17 21:06
ssl_cert.pem
1.53
KB
-rw-r--r--
2023-06-06 00:15
ssl_key.passwd.pem
2.59
KB
-rw-r--r--
2023-06-06 00:15
ssl_key.pem
2.43
KB
-rw-r--r--
2023-06-06 00:15
ssl_servers.py
7.04
KB
-rw-r--r--
2024-04-17 21:06
ssltests.py
1.03
KB
-rw-r--r--
2024-04-17 21:06
string_tests.py
64.66
KB
-rw-r--r--
2024-04-17 21:06
talos-2019-0758.pem
1.3
KB
-rw-r--r--
2023-06-06 00:15
test___all__.py
3.81
KB
-rw-r--r--
2024-04-17 21:06
test___future__.py
2.36
KB
-rw-r--r--
2024-04-17 21:06
test__locale.py
7.71
KB
-rw-r--r--
2024-04-17 21:06
test__opcode.py
850
B
-rw-r--r--
2024-04-17 21:06
test__osx_support.py
13.66
KB
-rw-r--r--
2024-04-17 21:06
test_abc.py
18
KB
-rw-r--r--
2024-04-17 21:06
test_abstract_numbers.py
1.49
KB
-rw-r--r--
2024-04-17 21:06
test_aifc.py
17.7
KB
-rw-r--r--
2024-04-17 21:06
test_argparse.py
169.13
KB
-rw-r--r--
2024-04-17 21:06
test_array.py
47.38
KB
-rw-r--r--
2024-04-17 21:06
test_asdl_parser.py
3.92
KB
-rw-r--r--
2024-04-17 21:06
test_ast.py
56.94
KB
-rw-r--r--
2024-04-17 21:06
test_asyncgen.py
33.21
KB
-rw-r--r--
2024-04-17 21:06
test_asynchat.py
9.31
KB
-rw-r--r--
2024-04-17 21:06
test_asyncore.py
25.81
KB
-rw-r--r--
2024-04-17 21:06
test_atexit.py
5.81
KB
-rw-r--r--
2024-04-17 21:06
test_audioop.py
28.24
KB
-rw-r--r--
2024-04-17 21:06
test_augassign.py
7.68
KB
-rw-r--r--
2024-04-17 21:06
test_base64.py
30.17
KB
-rw-r--r--
2024-04-17 21:06
test_baseexception.py
6.86
KB
-rw-r--r--
2024-04-17 21:06
test_bdb.py
41.21
KB
-rw-r--r--
2024-04-17 21:06
test_bigaddrspace.py
2.92
KB
-rw-r--r--
2024-04-17 21:06
test_bigmem.py
44.88
KB
-rw-r--r--
2024-04-17 21:06
test_binascii.py
16.94
KB
-rw-r--r--
2024-04-17 21:06
test_binhex.py
1.46
KB
-rw-r--r--
2024-04-17 21:06
test_binop.py
14.14
KB
-rw-r--r--
2024-04-17 21:06
test_bisect.py
13.63
KB
-rw-r--r--
2024-04-17 21:06
test_bool.py
12.52
KB
-rw-r--r--
2024-04-17 21:06
test_buffer.py
159.08
KB
-rw-r--r--
2024-04-17 21:06
test_bufio.py
2.54
KB
-rw-r--r--
2024-04-17 21:06
test_builtin.py
71.43
KB
-rw-r--r--
2024-04-17 21:06
test_bytes.py
68.75
KB
-rw-r--r--
2024-04-17 21:06
test_bz2.py
36.69
KB
-rw-r--r--
2024-04-17 21:06
test_c_locale_coercion.py
18.34
KB
-rw-r--r--
2024-04-17 21:06
test_calendar.py
48.71
KB
-rw-r--r--
2024-04-17 21:06
test_call.py
14.59
KB
-rw-r--r--
2024-04-17 21:06
test_capi.py
22.54
KB
-rw-r--r--
2024-04-17 21:06
test_cgi.py
23.44
KB
-rw-r--r--
2024-04-17 21:06
test_cgitb.py
2.5
KB
-rw-r--r--
2024-04-17 21:06
test_charmapcodec.py
1.68
KB
-rw-r--r--
2024-04-17 21:06
test_class.py
16.93
KB
-rw-r--r--
2024-04-17 21:06
test_clinic.py
21.24
KB
-rw-r--r--
2024-04-17 21:06
test_cmath.py
24.28
KB
-rw-r--r--
2024-04-17 21:06
test_cmd.py
6.1
KB
-rw-r--r--
2024-04-17 21:06
test_cmd_line.py
31.75
KB
-rw-r--r--
2024-04-17 21:06
test_cmd_line_script.py
29.15
KB
-rw-r--r--
2024-04-17 21:06
test_code.py
10.4
KB
-rw-r--r--
2024-04-17 21:06
test_code_module.py
5.51
KB
-rw-r--r--
2024-04-17 21:06
test_codeccallbacks.py
42.8
KB
-rw-r--r--
2024-04-17 21:06
test_codecencodings_cn.py
3.86
KB
-rw-r--r--
2024-04-17 21:06
test_codecencodings_hk.py
701
B
-rw-r--r--
2024-04-17 21:06
test_codecencodings_iso2022.py
1.36
KB
-rw-r--r--
2024-04-17 21:06
test_codecencodings_jp.py
4.79
KB
-rw-r--r--
2024-04-17 21:06
test_codecencodings_kr.py
2.96
KB
-rw-r--r--
2024-04-17 21:06
test_codecencodings_tw.py
681
B
-rw-r--r--
2024-04-17 21:06
test_codecmaps_cn.py
746
B
-rw-r--r--
2024-04-17 21:06
test_codecmaps_hk.py
386
B
-rw-r--r--
2024-04-17 21:06
test_codecmaps_jp.py
1.7
KB
-rw-r--r--
2024-04-17 21:06
test_codecmaps_kr.py
1.16
KB
-rw-r--r--
2024-04-17 21:06
test_codecmaps_tw.py
705
B
-rw-r--r--
2024-04-17 21:06
test_codecs.py
130.73
KB
-rw-r--r--
2024-04-17 21:06
test_codeop.py
7.63
KB
-rw-r--r--
2024-04-17 21:06
test_collections.py
79.61
KB
-rw-r--r--
2024-04-17 21:06
test_colorsys.py
3.83
KB
-rw-r--r--
2024-04-17 21:06
test_compare.py
3.82
KB
-rw-r--r--
2024-04-17 21:06
test_compile.py
34.99
KB
-rw-r--r--
2024-04-17 21:06
test_compileall.py
26.78
KB
-rw-r--r--
2024-04-17 21:06
test_complex.py
29.68
KB
-rw-r--r--
2024-04-17 21:06
test_concurrent_futures.py
43.15
KB
-rw-r--r--
2024-04-17 21:06
test_configparser.py
84.69
KB
-rw-r--r--
2024-04-17 21:06
test_contains.py
3.49
KB
-rw-r--r--
2024-04-17 21:06
test_context.py
30.74
KB
-rw-r--r--
2024-04-17 21:06
test_contextlib.py
32.5
KB
-rw-r--r--
2024-04-17 21:06
test_contextlib_async.py
14.7
KB
-rw-r--r--
2024-04-17 21:06
test_copy.py
25.81
KB
-rw-r--r--
2024-04-17 21:06
test_copyreg.py
4.39
KB
-rw-r--r--
2024-04-17 21:06
test_coroutines.py
62.27
KB
-rw-r--r--
2024-04-17 21:06
test_cprofile.py
6.15
KB
-rw-r--r--
2024-04-17 21:06
test_crashers.py
1.16
KB
-rw-r--r--
2024-04-17 21:06
test_crypt.py
3.5
KB
-rw-r--r--
2024-04-17 21:06
test_csv.py
47.06
KB
-rw-r--r--
2024-04-17 21:06
test_ctypes.py
184
B
-rw-r--r--
2024-04-17 21:06
test_curses.py
18.85
KB
-rw-r--r--
2024-04-17 21:06
test_dataclasses.py
107.41
KB
-rw-r--r--
2024-04-17 21:06
test_datetime.py
2.15
KB
-rw-r--r--
2024-04-17 21:06
test_dbm.py
6.44
KB
-rw-r--r--
2024-04-17 21:06
test_dbm_dumb.py
10.77
KB
-rw-r--r--
2024-04-17 21:06
test_dbm_gnu.py
5.22
KB
-rw-r--r--
2024-04-17 21:06
test_dbm_ndbm.py
4.31
KB
-rw-r--r--
2024-04-17 21:06
test_decimal.py
207.14
KB
-rw-r--r--
2024-04-17 21:06
test_decorators.py
9.48
KB
-rw-r--r--
2024-04-17 21:06
test_defaultdict.py
5.88
KB
-rw-r--r--
2024-04-17 21:06
test_deque.py
33.84
KB
-rw-r--r--
2024-04-17 21:06
test_descr.py
185.7
KB
-rw-r--r--
2024-04-17 21:06
test_descrtut.py
11.53
KB
-rw-r--r--
2024-04-17 21:06
test_devpoll.py
4.51
KB
-rw-r--r--
2024-04-17 21:06
test_dict.py
40.02
KB
-rw-r--r--
2024-04-17 21:06
test_dict_version.py
5.87
KB
-rw-r--r--
2024-04-17 21:06
test_dictcomps.py
3.67
KB
-rw-r--r--
2024-04-17 21:06
test_dictviews.py
11.68
KB
-rw-r--r--
2024-04-17 21:06
test_difflib.py
19.36
KB
-rw-r--r--
2024-04-17 21:06
test_difflib_expect.html
100.85
KB
-rw-r--r--
2023-06-06 00:15
test_dis.py
48.53
KB
-rw-r--r--
2024-04-17 21:06
test_distutils.py
375
B
-rw-r--r--
2024-04-17 21:06
test_doctest.py
98.51
KB
-rw-r--r--
2024-04-17 21:06
test_doctest.txt
300
B
-rw-r--r--
2023-06-06 00:15
test_doctest2.py
2.3
KB
-rw-r--r--
2024-04-17 21:06
test_doctest2.txt
392
B
-rw-r--r--
2023-06-06 00:15
test_doctest3.txt
82
B
-rw-r--r--
2023-06-06 00:15
test_doctest4.txt
244
B
-rw-r--r--
2023-06-06 00:15
test_docxmlrpc.py
8.7
KB
-rw-r--r--
2024-04-17 21:06
test_dtrace.py
5.23
KB
-rw-r--r--
2024-04-17 21:06
test_dummy_thread.py
9.69
KB
-rw-r--r--
2024-04-17 21:06
test_dummy_threading.py
1.7
KB
-rw-r--r--
2024-04-17 21:06
test_dynamic.py
4.29
KB
-rw-r--r--
2024-04-17 21:06
test_dynamicclassattribute.py
9.57
KB
-rw-r--r--
2024-04-17 21:06
test_eintr.py
1.32
KB
-rw-r--r--
2024-04-17 21:06
test_embed.py
20.38
KB
-rw-r--r--
2024-04-17 21:06
test_ensurepip.py
9.83
KB
-rw-r--r--
2024-04-17 21:06
test_enum.py
106.03
KB
-rw-r--r--
2024-04-17 21:06
test_enumerate.py
7.9
KB
-rw-r--r--
2024-04-17 21:06
test_eof.py
803
B
-rw-r--r--
2024-04-17 21:06
test_epoll.py
8.99
KB
-rw-r--r--
2024-04-17 21:06
test_errno.py
1.04
KB
-rw-r--r--
2024-04-17 21:06
test_exception_hierarchy.py
7.23
KB
-rw-r--r--
2024-04-17 21:06
test_exception_variations.py
3.86
KB
-rw-r--r--
2024-04-17 21:06
test_exceptions.py
47.48
KB
-rw-r--r--
2024-04-17 21:06
test_extcall.py
12.09
KB
-rw-r--r--
2024-04-17 21:06
test_faulthandler.py
27.98
KB
-rw-r--r--
2024-04-17 21:06
test_fcntl.py
6.23
KB
-rw-r--r--
2024-04-17 21:06
test_file.py
10.61
KB
-rw-r--r--
2024-04-17 21:06
test_file_eintr.py
10.6
KB
-rw-r--r--
2024-04-17 21:06
test_filecmp.py
8.69
KB
-rw-r--r--
2024-04-17 21:06
test_fileinput.py
37.29
KB
-rw-r--r--
2024-04-17 21:06
test_fileio.py
19.19
KB
-rw-r--r--
2024-04-17 21:06
test_finalization.py
14.16
KB
-rw-r--r--
2024-04-17 21:06
test_float.py
63
KB
-rw-r--r--
2024-04-17 21:06
test_flufl.py
1.32
KB
-rw-r--r--
2024-04-17 21:06
test_fnmatch.py
5.07
KB
-rw-r--r--
2024-04-17 21:06
test_fork1.py
3.71
KB
-rw-r--r--
2024-04-17 21:06
test_format.py
22.47
KB
-rw-r--r--
2024-04-17 21:06
test_fractions.py
27.03
KB
-rw-r--r--
2024-04-17 21:06
test_frame.py
5.67
KB
-rw-r--r--
2024-04-17 21:06
test_frozen.py
970
B
-rw-r--r--
2024-04-17 21:06
test_fstring.py
40.23
KB
-rw-r--r--
2024-04-17 21:06
test_ftplib.py
39.75
KB
-rw-r--r--
2024-04-17 21:06
test_funcattrs.py
13.25
KB
-rw-r--r--
2024-04-17 21:06
test_functools.py
82.6
KB
-rw-r--r--
2024-04-17 21:06
test_future.py
9.98
KB
-rw-r--r--
2024-04-17 21:06
test_future3.py
490
B
-rw-r--r--
2024-04-17 21:06
test_future4.py
222
B
-rw-r--r--
2024-04-17 21:06
test_future5.py
510
B
-rw-r--r--
2024-04-17 21:06
test_gc.py
36.08
KB
-rw-r--r--
2024-04-17 21:06
test_gdb.py
40.09
KB
-rw-r--r--
2024-04-17 21:06
test_generator_stop.py
943
B
-rw-r--r--
2024-04-17 21:06
test_generators.py
58.47
KB
-rw-r--r--
2024-04-17 21:06
test_genericclass.py
9.28
KB
-rw-r--r--
2024-04-17 21:06
test_genericpath.py
20.54
KB
-rw-r--r--
2024-04-17 21:06
test_genexps.py
7.12
KB
-rw-r--r--
2024-04-17 21:06
test_getargs2.py
45.5
KB
-rw-r--r--
2024-04-17 21:06
test_getopt.py
6.75
KB
-rw-r--r--
2024-04-17 21:06
test_getpass.py
6.29
KB
-rw-r--r--
2024-04-17 21:06
test_gettext.py
33.12
KB
-rw-r--r--
2024-04-17 21:06
test_glob.py
12.39
KB
-rw-r--r--
2024-04-17 21:06
test_global.py
1.31
KB
-rw-r--r--
2024-04-17 21:06
test_grammar.py
48.46
KB
-rw-r--r--
2024-04-17 21:06
test_grp.py
3.54
KB
-rw-r--r--
2024-04-17 21:06
test_gzip.py
27.72
KB
-rw-r--r--
2024-04-17 21:06
test_hash.py
11.45
KB
-rw-r--r--
2024-04-17 21:06
test_hashlib.py
39.09
KB
-rw-r--r--
2024-04-17 21:06
test_heapq.py
15.66
KB
-rw-r--r--
2024-04-17 21:06
test_hmac.py
21.51
KB
-rw-r--r--
2024-04-17 21:06
test_html.py
4.23
KB
-rw-r--r--
2024-04-17 21:06
test_htmlparser.py
31.93
KB
-rw-r--r--
2024-04-17 21:06
test_http_cookiejar.py
75.64
KB
-rw-r--r--
2024-04-17 21:06
test_http_cookies.py
18.13
KB
-rw-r--r--
2024-04-17 21:06
test_httplib.py
76.63
KB
-rw-r--r--
2024-04-17 21:06
test_httpservers.py
47.56
KB
-rw-r--r--
2024-04-17 21:06
test_idle.py
822
B
-rw-r--r--
2024-04-17 21:06
test_imaplib.py
38.82
KB
-rw-r--r--
2024-04-17 21:06
test_imghdr.py
4.66
KB
-rw-r--r--
2024-04-17 21:06
test_imp.py
17.32
KB
-rw-r--r--
2024-04-17 21:06
test_index.py
8.37
KB
-rw-r--r--
2024-04-17 21:06
test_inspect.py
145.17
KB
-rw-r--r--
2024-04-17 21:06
test_int.py
26.93
KB
-rw-r--r--
2024-04-17 21:06
test_int_literal.py
6.89
KB
-rw-r--r--
2024-04-17 21:06
test_io.py
160.77
KB
-rw-r--r--
2024-04-17 21:06
test_ioctl.py
3.19
KB
-rw-r--r--
2024-04-17 21:06
test_ipaddress.py
91.43
KB
-rw-r--r--
2024-04-17 21:06
test_isinstance.py
9.91
KB
-rw-r--r--
2024-04-17 21:06
test_iter.py
31.51
KB
-rw-r--r--
2024-04-17 21:06
test_iterlen.py
7.1
KB
-rw-r--r--
2024-04-17 21:06
test_itertools.py
99.19
KB
-rw-r--r--
2024-04-17 21:06
test_keyword.py
5.7
KB
-rw-r--r--
2024-04-17 21:06
test_keywordonlyarg.py
6.85
KB
-rw-r--r--
2024-04-17 21:06
test_kqueue.py
8.81
KB
-rw-r--r--
2024-04-17 21:06
test_largefile.py
6.83
KB
-rw-r--r--
2024-04-17 21:06
test_lib2to3.py
101
B
-rw-r--r--
2024-04-17 21:06
test_linecache.py
7.79
KB
-rw-r--r--
2024-04-17 21:06
test_list.py
7.69
KB
-rw-r--r--
2024-04-17 21:06
test_listcomps.py
3.76
KB
-rw-r--r--
2024-04-17 21:06
test_locale.py
23.56
KB
-rw-r--r--
2024-04-17 21:06
test_logging.py
166.71
KB
-rw-r--r--
2024-04-17 21:06
test_long.py
52.8
KB
-rw-r--r--
2024-04-17 21:06
test_longexp.py
233
B
-rw-r--r--
2024-04-17 21:06
test_lzma.py
87.86
KB
-rw-r--r--
2024-04-17 21:06
test_macpath.py
6.2
KB
-rw-r--r--
2024-04-17 21:06
test_mailbox.py
90.64
KB
-rw-r--r--
2024-04-17 21:06
test_mailcap.py
10.03
KB
-rw-r--r--
2024-04-17 21:06
test_marshal.py
19.62
KB
-rw-r--r--
2024-04-17 21:06
test_math.py
63.88
KB
-rw-r--r--
2024-04-17 21:06
test_memoryio.py
31.48
KB
-rw-r--r--
2024-04-17 21:06
test_memoryview.py
17.44
KB
-rw-r--r--
2024-04-17 21:06
test_metaclass.py
6.2
KB
-rw-r--r--
2024-04-17 21:06
test_mimetypes.py
8.62
KB
-rw-r--r--
2024-04-17 21:06
test_minidom.py
65.82
KB
-rw-r--r--
2024-04-17 21:06
test_mmap.py
27.79
KB
-rw-r--r--
2024-04-17 21:06
test_module.py
10.3
KB
-rw-r--r--
2024-04-17 21:06
test_modulefinder.py
9.05
KB
-rw-r--r--
2024-04-17 21:06
test_msilib.py
4.37
KB
-rw-r--r--
2024-04-17 21:06
test_multibytecodec.py
10.06
KB
-rw-r--r--
2024-04-17 21:06
test_multiprocessing_fork.py
477
B
-rw-r--r--
2024-04-17 21:06
test_multiprocessing_forkserver.py
392
B
-rw-r--r--
2024-04-17 21:06
test_multiprocessing_main_handling.py
11.45
KB
-rw-r--r--
2024-04-17 21:06
test_multiprocessing_spawn.py
277
B
-rw-r--r--
2024-04-17 21:06
test_netrc.py
5.93
KB
-rw-r--r--
2024-04-17 21:06
test_nis.py
1.13
KB
-rw-r--r--
2024-04-17 21:06
test_nntplib.py
61.7
KB
-rw-r--r--
2024-04-17 21:06
test_normalization.py
3.32
KB
-rw-r--r--
2024-04-17 21:06
test_ntpath.py
23.95
KB
-rw-r--r--
2024-04-17 21:06
test_numeric_tower.py
7.18
KB
-rw-r--r--
2024-04-17 21:06
test_opcodes.py
3.61
KB
-rw-r--r--
2024-04-17 21:06
test_openpty.py
600
B
-rw-r--r--
2024-04-17 21:06
test_operator.py
22.74
KB
-rw-r--r--
2024-04-17 21:06
test_optparse.py
60.99
KB
-rw-r--r--
2024-04-17 21:06
test_ordered_dict.py
29.38
KB
-rw-r--r--
2024-04-17 21:06
test_os.py
139.15
KB
-rw-r--r--
2024-04-17 21:06
test_ossaudiodev.py
7.06
KB
-rw-r--r--
2024-04-17 21:06
test_osx_env.py
1.3
KB
-rw-r--r--
2024-04-17 21:06
test_parser.py
33.13
KB
-rw-r--r--
2024-04-17 21:06
test_pathlib.py
91.46
KB
-rw-r--r--
2024-04-17 21:06
test_pdb.py
49.15
KB
-rw-r--r--
2024-04-17 21:06
test_peepholer.py
12.81
KB
-rw-r--r--
2024-04-17 21:06
test_pickle.py
18.57
KB
-rw-r--r--
2024-04-17 21:06
test_pickletools.py
4.23
KB
-rw-r--r--
2024-04-17 21:06
test_pipes.py
6.59
KB
-rw-r--r--
2024-04-17 21:06
test_pkg.py
9.59
KB
-rw-r--r--
2024-04-17 21:06
test_pkgimport.py
2.67
KB
-rw-r--r--
2024-04-17 21:06
test_pkgutil.py
17.61
KB
-rw-r--r--
2024-04-17 21:06
test_platform.py
17.39
KB
-rw-r--r--
2024-04-17 21:06
test_plistlib.py
37.01
KB
-rw-r--r--
2024-04-17 21:06
test_poll.py
7.23
KB
-rw-r--r--
2024-04-17 21:06
test_popen.py
1.98
KB
-rw-r--r--
2024-04-17 21:06
test_poplib.py
16.88
KB
-rw-r--r--
2024-04-17 21:06
test_posix.py
61.46
KB
-rw-r--r--
2024-04-17 21:06
test_posixpath.py
28.66
KB
-rw-r--r--
2024-04-17 21:06
test_pow.py
4.37
KB
-rw-r--r--
2024-04-17 21:06
test_pprint.py
43.49
KB
-rw-r--r--
2024-04-17 21:06
test_print.py
7.37
KB
-rw-r--r--
2024-04-17 21:06
test_profile.py
7.71
KB
-rw-r--r--
2024-04-17 21:06
test_property.py
8.77
KB
-rw-r--r--
2024-04-17 21:06
test_pstats.py
2.89
KB
-rw-r--r--
2024-04-17 21:06
test_pty.py
11.97
KB
-rw-r--r--
2024-04-17 21:06
test_pulldom.py
12.33
KB
-rw-r--r--
2024-04-17 21:06
test_pwd.py
4.17
KB
-rw-r--r--
2024-04-17 21:06
test_py_compile.py
8.14
KB
-rw-r--r--
2024-04-17 21:06
test_pyclbr.py
9.45
KB
-rw-r--r--
2024-04-17 21:06
test_pydoc.py
46.61
KB
-rw-r--r--
2024-04-17 21:06
test_pyexpat.py
26.52
KB
-rw-r--r--
2024-04-17 21:06
test_queue.py
19.07
KB
-rw-r--r--
2024-04-17 21:06
test_quopri.py
7.78
KB
-rw-r--r--
2024-04-17 21:06
test_raise.py
12.78
KB
-rw-r--r--
2024-04-17 21:06
test_random.py
41.09
KB
-rw-r--r--
2024-04-17 21:06
test_range.py
23.35
KB
-rw-r--r--
2024-04-17 21:06
test_re.py
104.3
KB
-rw-r--r--
2024-04-17 21:06
test_readline.py
12.95
KB
-rw-r--r--
2024-04-17 21:06
test_regrtest.py
44.92
KB
-rw-r--r--
2024-04-17 21:06
test_repl.py
2.25
KB
-rw-r--r--
2024-04-17 21:06
test_reprlib.py
15.12
KB
-rw-r--r--
2024-04-17 21:06
test_resource.py
6.8
KB
-rw-r--r--
2024-04-17 21:06
test_richcmp.py
11.91
KB
-rw-r--r--
2024-04-17 21:06
test_rlcompleter.py
6.3
KB
-rw-r--r--
2024-04-17 21:06
test_robotparser.py
10.01
KB
-rw-r--r--
2024-04-17 21:06
test_runpy.py
31.05
KB
-rw-r--r--
2024-04-17 21:06
test_sax.py
45.46
KB
-rw-r--r--
2024-04-17 21:06
test_sched.py
6.41
KB
-rw-r--r--
2024-04-17 21:06
test_scope.py
19.7
KB
-rw-r--r--
2024-04-17 21:06
test_script_helper.py
5.78
KB
-rw-r--r--
2024-04-17 21:06
test_secrets.py
4.28
KB
-rw-r--r--
2024-04-17 21:06
test_select.py
2.65
KB
-rw-r--r--
2024-04-17 21:06
test_selectors.py
17.79
KB
-rw-r--r--
2024-04-17 21:06
test_set.py
64.41
KB
-rw-r--r--
2024-04-17 21:06
test_setcomps.py
3.7
KB
-rw-r--r--
2024-04-17 21:06
test_shelve.py
6.24
KB
-rw-r--r--
2024-04-17 21:06
test_shlex.py
11.24
KB
-rw-r--r--
2024-04-17 21:06
test_shutil.py
78.63
KB
-rw-r--r--
2024-04-17 21:06
test_signal.py
40.2
KB
-rw-r--r--
2024-04-17 21:06
test_site.py
27.05
KB
-rw-r--r--
2024-04-17 21:06
test_slice.py
8.25
KB
-rw-r--r--
2024-04-17 21:06
test_smtpd.py
40.14
KB
-rw-r--r--
2024-04-17 21:06
test_smtplib.py
52.91
KB
-rw-r--r--
2024-04-17 21:06
test_smtpnet.py
2.87
KB
-rw-r--r--
2024-04-17 21:06
test_sndhdr.py
1.43
KB
-rw-r--r--
2024-04-17 21:06
test_socket.py
223.55
KB
-rw-r--r--
2024-04-17 21:06
test_socketserver.py
16.87
KB
-rw-r--r--
2024-04-17 21:06
test_sort.py
13.42
KB
-rw-r--r--
2024-04-17 21:06
test_source_encoding.py
7.89
KB
-rw-r--r--
2024-04-17 21:06
test_spwd.py
2.71
KB
-rw-r--r--
2024-04-17 21:06
test_sqlite.py
948
B
-rw-r--r--
2024-04-17 21:06
test_ssl.py
195.89
KB
-rw-r--r--
2024-04-17 21:06
test_startfile.py
1.17
KB
-rw-r--r--
2024-04-17 21:06
test_stat.py
7.96
KB
-rw-r--r--
2024-04-17 21:06
test_statistics.py
74.35
KB
-rw-r--r--
2024-04-17 21:06
test_strftime.py
7.54
KB
-rw-r--r--
2024-04-17 21:06
test_string.py
19.8
KB
-rw-r--r--
2024-04-17 21:06
test_string_literals.py
9.83
KB
-rw-r--r--
2024-04-17 21:06
test_stringprep.py
3.04
KB
-rw-r--r--
2024-04-17 21:06
test_strptime.py
34.21
KB
-rw-r--r--
2024-04-17 21:06
test_strtod.py
20.06
KB
-rw-r--r--
2024-04-17 21:06
test_struct.py
33.4
KB
-rw-r--r--
2024-04-17 21:06
test_structmembers.py
4.7
KB
-rw-r--r--
2024-04-17 21:06
test_structseq.py
3.87
KB
-rw-r--r--
2024-04-17 21:06
test_subclassinit.py
8.12
KB
-rw-r--r--
2024-04-17 21:06
test_subprocess.py
139.5
KB
-rw-r--r--
2024-04-17 21:06
test_sunau.py
6.07
KB
-rw-r--r--
2024-04-17 21:06
test_sundry.py
2.04
KB
-rw-r--r--
2024-04-17 21:06
test_super.py
10.65
KB
-rw-r--r--
2024-04-17 21:06
test_support.py
23.45
KB
-rw-r--r--
2024-04-17 21:06
test_symbol.py
1.86
KB
-rw-r--r--
2024-04-17 21:06
test_symtable.py
6.93
KB
-rw-r--r--
2024-04-17 21:06
test_syntax.py
22.13
KB
-rw-r--r--
2024-04-17 21:06
test_sys.py
49.65
KB
-rw-r--r--
2024-04-17 21:06
test_sys_setprofile.py
11.42
KB
-rw-r--r--
2024-04-17 21:06
test_sys_settrace.py
39.98
KB
-rw-r--r--
2024-04-17 21:06
test_sysconfig.py
18.34
KB
-rw-r--r--
2024-04-17 21:06
test_syslog.py
1.15
KB
-rw-r--r--
2024-04-17 21:06
test_tarfile.py
97.46
KB
-rw-r--r--
2024-04-17 21:06
test_tcl.py
29.2
KB
-rw-r--r--
2024-04-17 21:06
test_telnetlib.py
12.7
KB
-rw-r--r--
2024-04-17 21:06
test_tempfile.py
51.01
KB
-rw-r--r--
2024-04-17 21:06
test_textwrap.py
38.84
KB
-rw-r--r--
2024-04-17 21:06
test_thread.py
8.42
KB
-rw-r--r--
2024-04-17 21:06
test_threaded_import.py
8.91
KB
-rw-r--r--
2024-04-17 21:06
test_threadedtempfile.py
1.87
KB
-rw-r--r--
2024-04-17 21:06
test_threading.py
44.21
KB
-rw-r--r--
2024-04-17 21:06
test_threading_local.py
6.09
KB
-rw-r--r--
2024-04-17 21:06
test_threadsignals.py
10.09
KB
-rw-r--r--
2024-04-17 21:06
test_time.py
38.88
KB
-rw-r--r--
2024-04-17 21:06
test_timeit.py
14.8
KB
-rw-r--r--
2024-04-17 21:06
test_timeout.py
11.19
KB
-rw-r--r--
2024-04-17 21:06
test_tix.py
756
B
-rw-r--r--
2024-04-17 21:06
test_tk.py
362
B
-rw-r--r--
2024-04-17 21:06
test_tokenize.py
62.68
KB
-rw-r--r--
2024-04-17 21:06
test_trace.py
17.45
KB
-rw-r--r--
2024-04-17 21:06
test_traceback.py
43.48
KB
-rw-r--r--
2024-04-17 21:06
test_tracemalloc.py
36.44
KB
-rw-r--r--
2024-04-17 21:06
test_ttk_guionly.py
746
B
-rw-r--r--
2024-04-17 21:06
test_ttk_textonly.py
299
B
-rw-r--r--
2024-04-17 21:06
test_tuple.py
7.58
KB
-rw-r--r--
2024-04-17 21:06
test_turtle.py
12.36
KB
-rw-r--r--
2024-04-17 21:06
test_typechecks.py
2.55
KB
-rw-r--r--
2024-04-17 21:06
test_types.py
58
KB
-rw-r--r--
2024-04-17 21:06
test_typing.py
92.67
KB
-rw-r--r--
2024-04-17 21:06
test_ucn.py
9.35
KB
-rw-r--r--
2024-04-17 21:06
test_unary.py
1.63
KB
-rw-r--r--
2024-04-17 21:06
test_unicode.py
130.28
KB
-rw-r--r--
2024-04-17 21:06
test_unicode_file.py
5.73
KB
-rw-r--r--
2024-04-17 21:06
test_unicode_file_functions.py
6.84
KB
-rw-r--r--
2024-04-17 21:06
test_unicode_identifiers.py
891
B
-rw-r--r--
2024-04-17 21:06
test_unicodedata.py
12.6
KB
-rw-r--r--
2024-04-17 21:06
test_unittest.py
286
B
-rw-r--r--
2024-04-17 21:06
test_univnewlines.py
3.83
KB
-rw-r--r--
2024-04-17 21:06
test_unpack.py
3.01
KB
-rw-r--r--
2024-04-17 21:06
test_unpack_ex.py
8.73
KB
-rw-r--r--
2024-04-17 21:06
test_urllib.py
68.91
KB
-rw-r--r--
2024-04-17 21:06
test_urllib2.py
77.01
KB
-rw-r--r--
2024-04-17 21:06
test_urllib2_localnet.py
24.26
KB
-rw-r--r--
2024-04-17 21:06
test_urllib2net.py
12.39
KB
-rw-r--r--
2024-04-17 21:06
test_urllib_response.py
1.69
KB
-rw-r--r--
2024-04-17 21:06
test_urllibnet.py
8.9
KB
-rw-r--r--
2024-04-17 21:06
test_urlparse.py
63.23
KB
-rw-r--r--
2024-04-17 21:06
test_userdict.py
7.64
KB
-rw-r--r--
2024-04-17 21:06
test_userlist.py
1.97
KB
-rw-r--r--
2024-04-17 21:06
test_userstring.py
1.43
KB
-rw-r--r--
2024-04-17 21:06
test_utf8_mode.py
9.17
KB
-rw-r--r--
2024-04-17 21:06
test_utf8source.py
1.15
KB
-rw-r--r--
2024-04-17 21:06
test_uu.py
8.83
KB
-rw-r--r--
2024-04-17 21:06
test_uuid.py
34.15
KB
-rw-r--r--
2024-04-17 21:06
test_venv.py
19.97
KB
-rw-r--r--
2024-04-17 21:06
test_wait3.py
1.16
KB
-rw-r--r--
2024-04-17 21:06
test_wait4.py
1.15
KB
-rw-r--r--
2024-04-17 21:06
test_wave.py
6.57
KB
-rw-r--r--
2024-04-17 21:06
test_weakref.py
68.94
KB
-rw-r--r--
2024-04-17 21:06
test_weakset.py
14.95
KB
-rw-r--r--
2024-04-17 21:06
test_webbrowser.py
10.47
KB
-rw-r--r--
2024-04-17 21:06
test_winconsoleio.py
6.15
KB
-rw-r--r--
2024-04-17 21:06
test_winreg.py
21.25
KB
-rw-r--r--
2024-04-17 21:06
test_winsound.py
4.57
KB
-rw-r--r--
2024-04-17 21:06
test_with.py
25.78
KB
-rw-r--r--
2024-04-17 21:06
test_wsgiref.py
29.72
KB
-rw-r--r--
2024-04-17 21:06
test_xdrlib.py
2.17
KB
-rw-r--r--
2024-04-17 21:06
test_xml_dom_minicompat.py
4.18
KB
-rw-r--r--
2024-04-17 21:06
test_xml_etree.py
116.47
KB
-rw-r--r--
2024-04-17 21:06
test_xml_etree_c.py
8.11
KB
-rw-r--r--
2024-04-17 21:06
test_xmlrpc.py
54.09
KB
-rw-r--r--
2024-04-17 21:06
test_xmlrpc_net.py
1015
B
-rw-r--r--
2024-04-17 21:06
test_xxtestfuzz.py
597
B
-rw-r--r--
2024-04-17 21:06
test_yield_from.py
29.96
KB
-rw-r--r--
2024-04-17 21:06
test_zipapp.py
15.92
KB
-rw-r--r--
2024-04-17 21:06
test_zipfile.py
104.5
KB
-rw-r--r--
2024-04-17 21:06
test_zipfile64.py
5.72
KB
-rw-r--r--
2024-04-17 21:06
test_zipimport.py
30.34
KB
-rw-r--r--
2024-04-17 21:06
test_zipimport_support.py
10.46
KB
-rw-r--r--
2024-04-17 21:06
test_zlib.py
34.03
KB
-rw-r--r--
2024-04-17 21:06
testcodec.py
1.02
KB
-rw-r--r--
2024-04-17 21:06
testtar.tar
425
KB
-rw-r--r--
2023-06-06 00:15
tf_inherit_check.py
714
B
-rw-r--r--
2024-04-17 21:06
threaded_import_hangers.py
1.45
KB
-rw-r--r--
2024-04-17 21:06
time_hashlib.py
2.87
KB
-rw-r--r--
2024-04-17 21:06
tokenize_tests-latin1-coding-cookie-and-utf8-bom-sig.txt
443
B
-rw-r--r--
2023-06-06 00:15
tokenize_tests-no-coding-cookie-and-utf8-bom-sig-only.txt
302
B
-rw-r--r--
2023-06-06 00:15
tokenize_tests-utf8-coding-cookie-and-no-utf8-bom-sig.txt
421
B
-rw-r--r--
2023-06-06 00:15
tokenize_tests-utf8-coding-cookie-and-utf8-bom-sig.txt
326
B
-rw-r--r--
2023-06-06 00:15
tokenize_tests.txt
2.65
KB
-rw-r--r--
2023-06-06 00:15
win_console_handler.py
1.38
KB
-rw-r--r--
2024-04-17 21:06
xmltests.py
499
B
-rw-r--r--
2024-04-17 21:06
zip_cp437_header.zip
270
B
-rw-r--r--
2023-06-06 00:15
zipdir.zip
374
B
-rw-r--r--
2023-06-06 00:15
Save
Rename
import unittest from test import support import base64 import binascii import os from array import array from test.support import script_helper class LegacyBase64TestCase(unittest.TestCase): # Legacy API is not as permissive as the modern API def check_type_errors(self, f): self.assertRaises(TypeError, f, "") self.assertRaises(TypeError, f, []) multidimensional = memoryview(b"1234").cast('B', (2, 2)) self.assertRaises(TypeError, f, multidimensional) int_data = memoryview(b"1234").cast('I') self.assertRaises(TypeError, f, int_data) def test_encodestring_warns(self): with self.assertWarns(DeprecationWarning): base64.encodestring(b"www.python.org") def test_decodestring_warns(self): with self.assertWarns(DeprecationWarning): base64.decodestring(b"d3d3LnB5dGhvbi5vcmc=\n") def test_encodebytes(self): eq = self.assertEqual eq(base64.encodebytes(b"www.python.org"), b"d3d3LnB5dGhvbi5vcmc=\n") eq(base64.encodebytes(b"a"), b"YQ==\n") eq(base64.encodebytes(b"ab"), b"YWI=\n") eq(base64.encodebytes(b"abc"), b"YWJj\n") eq(base64.encodebytes(b""), b"") eq(base64.encodebytes(b"abcdefghijklmnopqrstuvwxyz" b"ABCDEFGHIJKLMNOPQRSTUVWXYZ" b"0123456789!@#0^&*();:<>,. []{}"), b"YWJjZGVmZ2hpamtsbW5vcHFyc3R1dnd4eXpBQkNE" b"RUZHSElKS0xNTk9QUVJTVFVWV1hZWjAxMjM0\nNT" b"Y3ODkhQCMwXiYqKCk7Ojw+LC4gW117fQ==\n") # Non-bytes eq(base64.encodebytes(bytearray(b'abc')), b'YWJj\n') eq(base64.encodebytes(memoryview(b'abc')), b'YWJj\n') eq(base64.encodebytes(array('B', b'abc')), b'YWJj\n') self.check_type_errors(base64.encodebytes) def test_decodebytes(self): eq = self.assertEqual eq(base64.decodebytes(b"d3d3LnB5dGhvbi5vcmc=\n"), b"www.python.org") eq(base64.decodebytes(b"YQ==\n"), b"a") eq(base64.decodebytes(b"YWI=\n"), b"ab") eq(base64.decodebytes(b"YWJj\n"), b"abc") eq(base64.decodebytes(b"YWJjZGVmZ2hpamtsbW5vcHFyc3R1dnd4eXpBQkNE" b"RUZHSElKS0xNTk9QUVJTVFVWV1hZWjAxMjM0\nNT" b"Y3ODkhQCMwXiYqKCk7Ojw+LC4gW117fQ==\n"), b"abcdefghijklmnopqrstuvwxyz" b"ABCDEFGHIJKLMNOPQRSTUVWXYZ" b"0123456789!@#0^&*();:<>,. []{}") eq(base64.decodebytes(b''), b'') # Non-bytes eq(base64.decodebytes(bytearray(b'YWJj\n')), b'abc') eq(base64.decodebytes(memoryview(b'YWJj\n')), b'abc') eq(base64.decodebytes(array('B', b'YWJj\n')), b'abc') self.check_type_errors(base64.decodebytes) def test_encode(self): eq = self.assertEqual from io import BytesIO, StringIO infp = BytesIO(b'abcdefghijklmnopqrstuvwxyz' b'ABCDEFGHIJKLMNOPQRSTUVWXYZ' b'0123456789!@#0^&*();:<>,. []{}') outfp = BytesIO() base64.encode(infp, outfp) eq(outfp.getvalue(), b'YWJjZGVmZ2hpamtsbW5vcHFyc3R1dnd4eXpBQkNE' b'RUZHSElKS0xNTk9QUVJTVFVWV1hZWjAxMjM0\nNT' b'Y3ODkhQCMwXiYqKCk7Ojw+LC4gW117fQ==\n') # Non-binary files self.assertRaises(TypeError, base64.encode, StringIO('abc'), BytesIO()) self.assertRaises(TypeError, base64.encode, BytesIO(b'abc'), StringIO()) self.assertRaises(TypeError, base64.encode, StringIO('abc'), StringIO()) def test_decode(self): from io import BytesIO, StringIO infp = BytesIO(b'd3d3LnB5dGhvbi5vcmc=') outfp = BytesIO() base64.decode(infp, outfp) self.assertEqual(outfp.getvalue(), b'www.python.org') # Non-binary files self.assertRaises(TypeError, base64.encode, StringIO('YWJj\n'), BytesIO()) self.assertRaises(TypeError, base64.encode, BytesIO(b'YWJj\n'), StringIO()) self.assertRaises(TypeError, base64.encode, StringIO('YWJj\n'), StringIO()) class BaseXYTestCase(unittest.TestCase): # Modern API completely ignores exported dimension and format data and # treats any buffer as a stream of bytes def check_encode_type_errors(self, f): self.assertRaises(TypeError, f, "") self.assertRaises(TypeError, f, []) def check_decode_type_errors(self, f): self.assertRaises(TypeError, f, []) def check_other_types(self, f, bytes_data, expected): eq = self.assertEqual b = bytearray(bytes_data) eq(f(b), expected) # The bytearray wasn't mutated eq(b, bytes_data) eq(f(memoryview(bytes_data)), expected) eq(f(array('B', bytes_data)), expected) # XXX why is b64encode hardcoded here? self.check_nonbyte_element_format(base64.b64encode, bytes_data) self.check_multidimensional(base64.b64encode, bytes_data) def check_multidimensional(self, f, data): padding = b"\x00" if len(data) % 2 else b"" bytes_data = data + padding # Make sure cast works shape = (len(bytes_data) // 2, 2) multidimensional = memoryview(bytes_data).cast('B', shape) self.assertEqual(f(multidimensional), f(bytes_data)) def check_nonbyte_element_format(self, f, data): padding = b"\x00" * ((4 - len(data)) % 4) bytes_data = data + padding # Make sure cast works int_data = memoryview(bytes_data).cast('I') self.assertEqual(f(int_data), f(bytes_data)) def test_b64encode(self): eq = self.assertEqual # Test default alphabet eq(base64.b64encode(b"www.python.org"), b"d3d3LnB5dGhvbi5vcmc=") eq(base64.b64encode(b'\x00'), b'AA==') eq(base64.b64encode(b"a"), b"YQ==") eq(base64.b64encode(b"ab"), b"YWI=") eq(base64.b64encode(b"abc"), b"YWJj") eq(base64.b64encode(b""), b"") eq(base64.b64encode(b"abcdefghijklmnopqrstuvwxyz" b"ABCDEFGHIJKLMNOPQRSTUVWXYZ" b"0123456789!@#0^&*();:<>,. []{}"), b"YWJjZGVmZ2hpamtsbW5vcHFyc3R1dnd4eXpBQkNE" b"RUZHSElKS0xNTk9QUVJTVFVWV1hZWjAxMjM0NT" b"Y3ODkhQCMwXiYqKCk7Ojw+LC4gW117fQ==") # Test with arbitrary alternative characters eq(base64.b64encode(b'\xd3V\xbeo\xf7\x1d', altchars=b'*$'), b'01a*b$cd') eq(base64.b64encode(b'\xd3V\xbeo\xf7\x1d', altchars=bytearray(b'*$')), b'01a*b$cd') eq(base64.b64encode(b'\xd3V\xbeo\xf7\x1d', altchars=memoryview(b'*$')), b'01a*b$cd') eq(base64.b64encode(b'\xd3V\xbeo\xf7\x1d', altchars=array('B', b'*$')), b'01a*b$cd') # Non-bytes self.check_other_types(base64.b64encode, b'abcd', b'YWJjZA==') self.check_encode_type_errors(base64.b64encode) self.assertRaises(TypeError, base64.b64encode, b"", altchars="*$") # Test standard alphabet eq(base64.standard_b64encode(b"www.python.org"), b"d3d3LnB5dGhvbi5vcmc=") eq(base64.standard_b64encode(b"a"), b"YQ==") eq(base64.standard_b64encode(b"ab"), b"YWI=") eq(base64.standard_b64encode(b"abc"), b"YWJj") eq(base64.standard_b64encode(b""), b"") eq(base64.standard_b64encode(b"abcdefghijklmnopqrstuvwxyz" b"ABCDEFGHIJKLMNOPQRSTUVWXYZ" b"0123456789!@#0^&*();:<>,. []{}"), b"YWJjZGVmZ2hpamtsbW5vcHFyc3R1dnd4eXpBQkNE" b"RUZHSElKS0xNTk9QUVJTVFVWV1hZWjAxMjM0NT" b"Y3ODkhQCMwXiYqKCk7Ojw+LC4gW117fQ==") # Non-bytes self.check_other_types(base64.standard_b64encode, b'abcd', b'YWJjZA==') self.check_encode_type_errors(base64.standard_b64encode) # Test with 'URL safe' alternative characters eq(base64.urlsafe_b64encode(b'\xd3V\xbeo\xf7\x1d'), b'01a-b_cd') # Non-bytes self.check_other_types(base64.urlsafe_b64encode, b'\xd3V\xbeo\xf7\x1d', b'01a-b_cd') self.check_encode_type_errors(base64.urlsafe_b64encode) def test_b64decode(self): eq = self.assertEqual tests = {b"d3d3LnB5dGhvbi5vcmc=": b"www.python.org", b'AA==': b'\x00', b"YQ==": b"a", b"YWI=": b"ab", b"YWJj": b"abc", b"YWJjZGVmZ2hpamtsbW5vcHFyc3R1dnd4eXpBQkNE" b"RUZHSElKS0xNTk9QUVJTVFVWV1hZWjAxMjM0\nNT" b"Y3ODkhQCMwXiYqKCk7Ojw+LC4gW117fQ==": b"abcdefghijklmnopqrstuvwxyz" b"ABCDEFGHIJKLMNOPQRSTUVWXYZ" b"0123456789!@#0^&*();:<>,. []{}", b'': b'', } for data, res in tests.items(): eq(base64.b64decode(data), res) eq(base64.b64decode(data.decode('ascii')), res) # Non-bytes self.check_other_types(base64.b64decode, b"YWJj", b"abc") self.check_decode_type_errors(base64.b64decode) # Test with arbitrary alternative characters tests_altchars = {(b'01a*b$cd', b'*$'): b'\xd3V\xbeo\xf7\x1d', } for (data, altchars), res in tests_altchars.items(): data_str = data.decode('ascii') altchars_str = altchars.decode('ascii') eq(base64.b64decode(data, altchars=altchars), res) eq(base64.b64decode(data_str, altchars=altchars), res) eq(base64.b64decode(data, altchars=altchars_str), res) eq(base64.b64decode(data_str, altchars=altchars_str), res) # Test standard alphabet for data, res in tests.items(): eq(base64.standard_b64decode(data), res) eq(base64.standard_b64decode(data.decode('ascii')), res) # Non-bytes self.check_other_types(base64.standard_b64decode, b"YWJj", b"abc") self.check_decode_type_errors(base64.standard_b64decode) # Test with 'URL safe' alternative characters tests_urlsafe = {b'01a-b_cd': b'\xd3V\xbeo\xf7\x1d', b'': b'', } for data, res in tests_urlsafe.items(): eq(base64.urlsafe_b64decode(data), res) eq(base64.urlsafe_b64decode(data.decode('ascii')), res) # Non-bytes self.check_other_types(base64.urlsafe_b64decode, b'01a-b_cd', b'\xd3V\xbeo\xf7\x1d') self.check_decode_type_errors(base64.urlsafe_b64decode) def test_b64decode_padding_error(self): self.assertRaises(binascii.Error, base64.b64decode, b'abc') self.assertRaises(binascii.Error, base64.b64decode, 'abc') def test_b64decode_invalid_chars(self): # issue 1466065: Test some invalid characters. tests = ((b'%3d==', b'\xdd'), (b'$3d==', b'\xdd'), (b'[==', b''), (b'YW]3=', b'am'), (b'3{d==', b'\xdd'), (b'3d}==', b'\xdd'), (b'@@', b''), (b'!', b''), (b"YWJj\n", b"abc"), (b'YWJj\nYWI=', b'abcab')) funcs = ( base64.b64decode, base64.standard_b64decode, base64.urlsafe_b64decode, ) for bstr, res in tests: for func in funcs: with self.subTest(bstr=bstr, func=func): self.assertEqual(func(bstr), res) self.assertEqual(func(bstr.decode('ascii')), res) with self.assertRaises(binascii.Error): base64.b64decode(bstr, validate=True) with self.assertRaises(binascii.Error): base64.b64decode(bstr.decode('ascii'), validate=True) # Normal alphabet characters not discarded when alternative given res = b'\xFB\xEF\xBE\xFF\xFF\xFF' self.assertEqual(base64.b64decode(b'++[[//]]', b'[]'), res) self.assertEqual(base64.urlsafe_b64decode(b'++--//__'), res) def test_b32encode(self): eq = self.assertEqual eq(base64.b32encode(b''), b'') eq(base64.b32encode(b'\x00'), b'AA======') eq(base64.b32encode(b'a'), b'ME======') eq(base64.b32encode(b'ab'), b'MFRA====') eq(base64.b32encode(b'abc'), b'MFRGG===') eq(base64.b32encode(b'abcd'), b'MFRGGZA=') eq(base64.b32encode(b'abcde'), b'MFRGGZDF') # Non-bytes self.check_other_types(base64.b32encode, b'abcd', b'MFRGGZA=') self.check_encode_type_errors(base64.b32encode) def test_b32decode(self): eq = self.assertEqual tests = {b'': b'', b'AA======': b'\x00', b'ME======': b'a', b'MFRA====': b'ab', b'MFRGG===': b'abc', b'MFRGGZA=': b'abcd', b'MFRGGZDF': b'abcde', } for data, res in tests.items(): eq(base64.b32decode(data), res) eq(base64.b32decode(data.decode('ascii')), res) # Non-bytes self.check_other_types(base64.b32decode, b'MFRGG===', b"abc") self.check_decode_type_errors(base64.b32decode) def test_b32decode_casefold(self): eq = self.assertEqual tests = {b'': b'', b'ME======': b'a', b'MFRA====': b'ab', b'MFRGG===': b'abc', b'MFRGGZA=': b'abcd', b'MFRGGZDF': b'abcde', # Lower cases b'me======': b'a', b'mfra====': b'ab', b'mfrgg===': b'abc', b'mfrggza=': b'abcd', b'mfrggzdf': b'abcde', } for data, res in tests.items(): eq(base64.b32decode(data, True), res) eq(base64.b32decode(data.decode('ascii'), True), res) self.assertRaises(binascii.Error, base64.b32decode, b'me======') self.assertRaises(binascii.Error, base64.b32decode, 'me======') # Mapping zero and one eq(base64.b32decode(b'MLO23456'), b'b\xdd\xad\xf3\xbe') eq(base64.b32decode('MLO23456'), b'b\xdd\xad\xf3\xbe') map_tests = {(b'M1023456', b'L'): b'b\xdd\xad\xf3\xbe', (b'M1023456', b'I'): b'b\x1d\xad\xf3\xbe', } for (data, map01), res in map_tests.items(): data_str = data.decode('ascii') map01_str = map01.decode('ascii') eq(base64.b32decode(data, map01=map01), res) eq(base64.b32decode(data_str, map01=map01), res) eq(base64.b32decode(data, map01=map01_str), res) eq(base64.b32decode(data_str, map01=map01_str), res) self.assertRaises(binascii.Error, base64.b32decode, data) self.assertRaises(binascii.Error, base64.b32decode, data_str) def test_b32decode_error(self): tests = [b'abc', b'ABCDEF==', b'==ABCDEF'] prefixes = [b'M', b'ME', b'MFRA', b'MFRGG', b'MFRGGZA', b'MFRGGZDF'] for i in range(0, 17): if i: tests.append(b'='*i) for prefix in prefixes: if len(prefix) + i != 8: tests.append(prefix + b'='*i) for data in tests: with self.subTest(data=data): with self.assertRaises(binascii.Error): base64.b32decode(data) with self.assertRaises(binascii.Error): base64.b32decode(data.decode('ascii')) def test_b16encode(self): eq = self.assertEqual eq(base64.b16encode(b'\x01\x02\xab\xcd\xef'), b'0102ABCDEF') eq(base64.b16encode(b'\x00'), b'00') # Non-bytes self.check_other_types(base64.b16encode, b'\x01\x02\xab\xcd\xef', b'0102ABCDEF') self.check_encode_type_errors(base64.b16encode) def test_b16decode(self): eq = self.assertEqual eq(base64.b16decode(b'0102ABCDEF'), b'\x01\x02\xab\xcd\xef') eq(base64.b16decode('0102ABCDEF'), b'\x01\x02\xab\xcd\xef') eq(base64.b16decode(b'00'), b'\x00') eq(base64.b16decode('00'), b'\x00') # Lower case is not allowed without a flag self.assertRaises(binascii.Error, base64.b16decode, b'0102abcdef') self.assertRaises(binascii.Error, base64.b16decode, '0102abcdef') # Case fold eq(base64.b16decode(b'0102abcdef', True), b'\x01\x02\xab\xcd\xef') eq(base64.b16decode('0102abcdef', True), b'\x01\x02\xab\xcd\xef') # Non-bytes self.check_other_types(base64.b16decode, b"0102ABCDEF", b'\x01\x02\xab\xcd\xef') self.check_decode_type_errors(base64.b16decode) eq(base64.b16decode(bytearray(b"0102abcdef"), True), b'\x01\x02\xab\xcd\xef') eq(base64.b16decode(memoryview(b"0102abcdef"), True), b'\x01\x02\xab\xcd\xef') eq(base64.b16decode(array('B', b"0102abcdef"), True), b'\x01\x02\xab\xcd\xef') # Non-alphabet characters self.assertRaises(binascii.Error, base64.b16decode, '0102AG') # Incorrect "padding" self.assertRaises(binascii.Error, base64.b16decode, '010') def test_a85encode(self): eq = self.assertEqual tests = { b'': b'', b"www.python.org": b'GB\\6`E-ZP=Df.1GEb>', bytes(range(255)): b"""!!*-'"9eu7#RLhG$k3[W&.oNg'GVB"(`=52*$$""" b"""(B+<_pR,UFcb-n-Vr/1iJ-0JP==1c70M3&s#]4?Ykm5X@_(6q'R884cE""" b"""H9MJ8X:f1+h<)lt#=BSg3>[:ZC?t!MSA7]@cBPD3sCi+'.E,fo>FEMbN""" b"""G^4U^I!pHnJ:W<)KS>/9Ll%"IN/`jYOHG]iPa.Q$R$jD4S=Q7DTV8*TU""" b"""nsrdW2ZetXKAY/Yd(L?['d?O\\@K2_]Y2%o^qmn*`5Ta:aN;TJbg"GZd""" b"""*^:jeCE.%f\\,!5gtgiEi8N\\UjQ5OekiqBum-X60nF?)@o_%qPq"ad`""" b"""r;HT""", b"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ" b"0123456789!@#0^&*();:<>,. []{}": b'@:E_WAS,RgBkhF"D/O92EH6,BF`qtRH$VbC6UX@47n?3D92&&T' b":Jand;cHat='/U/0JP==1c70M3&r-I,;<FN.OZ`-3]oSW/g+A(H[P", b"no padding..": b'DJpY:@:Wn_DJ(RS', b"zero compression\0\0\0\0": b'H=_,8+Cf>,E,oN2F(oQ1z', b"zero compression\0\0\0": b'H=_,8+Cf>,E,oN2F(oQ1!!!!', b"Boundary:\0\0\0\0": b'6>q!aA79M(3WK-[!!', b"Space compr: ": b';fH/TAKYK$D/aMV+<VdL', b'\xff': b'rr', b'\xff'*2: b's8N', b'\xff'*3: b's8W*', b'\xff'*4: b's8W-!', } for data, res in tests.items(): eq(base64.a85encode(data), res, data) eq(base64.a85encode(data, adobe=False), res, data) eq(base64.a85encode(data, adobe=True), b'<~' + res + b'~>', data) self.check_other_types(base64.a85encode, b"www.python.org", b'GB\\6`E-ZP=Df.1GEb>') self.assertRaises(TypeError, base64.a85encode, "") eq(base64.a85encode(b"www.python.org", wrapcol=7, adobe=False), b'GB\\6`E-\nZP=Df.1\nGEb>') eq(base64.a85encode(b"\0\0\0\0www.python.org", wrapcol=7, adobe=False), b'zGB\\6`E\n-ZP=Df.\n1GEb>') eq(base64.a85encode(b"www.python.org", wrapcol=7, adobe=True), b'<~GB\\6`\nE-ZP=Df\n.1GEb>\n~>') eq(base64.a85encode(b' '*8, foldspaces=True, adobe=False), b'yy') eq(base64.a85encode(b' '*7, foldspaces=True, adobe=False), b'y+<Vd') eq(base64.a85encode(b' '*6, foldspaces=True, adobe=False), b'y+<U') eq(base64.a85encode(b' '*5, foldspaces=True, adobe=False), b'y+9') def test_b85encode(self): eq = self.assertEqual tests = { b'': b'', b'www.python.org': b'cXxL#aCvlSZ*DGca%T', bytes(range(255)): b"""009C61O)~M2nh-c3=Iws5D^j+6crX17#SKH9337X""" b"""AR!_nBqb&%C@Cr{EG;fCFflSSG&MFiI5|2yJUu=?KtV!7L`6nNNJ&ad""" b"""OifNtP*GA-R8>}2SXo+ITwPvYU}0ioWMyV&XlZI|Y;A6DaB*^Tbai%j""" b"""czJqze0_d@fPsR8goTEOh>41ejE#<ukdcy;l$Dm3n3<ZJoSmMZprN9p""" b"""q@|{(sHv)}tgWuEu(7hUw6(UkxVgH!yuH4^z`?@9#Kp$P$jQpf%+1cv""" b"""(9zP<)YaD4*xB0K+}+;a;Njxq<mKk)=;`X~?CtLF@bU8V^!4`l`1$(#""" b"""{Qdp""", b"""abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ""" b"""0123456789!@#0^&*();:<>,. []{}""": b"""VPa!sWoBn+X=-b1ZEkOHadLBXb#`}nd3r%YLqtVJM@UIZOH55pPf$@(""" b"""Q&d$}S6EqEFflSSG&MFiI5{CeBQRbjDkv#CIy^osE+AW7dwl""", b'no padding..': b'Zf_uPVPs@!Zf7no', b'zero compression\x00\x00\x00\x00': b'dS!BNAY*TBaB^jHb7^mG00000', b'zero compression\x00\x00\x00': b'dS!BNAY*TBaB^jHb7^mG0000', b"""Boundary:\x00\x00\x00\x00""": b"""LT`0$WMOi7IsgCw00""", b'Space compr: ': b'Q*dEpWgug3ZE$irARr(h', b'\xff': b'{{', b'\xff'*2: b'|Nj', b'\xff'*3: b'|Ns9', b'\xff'*4: b'|NsC0', } for data, res in tests.items(): eq(base64.b85encode(data), res) self.check_other_types(base64.b85encode, b"www.python.org", b'cXxL#aCvlSZ*DGca%T') def test_a85decode(self): eq = self.assertEqual tests = { b'': b'', b'GB\\6`E-ZP=Df.1GEb>': b'www.python.org', b"""! ! * -'"\n\t\t9eu\r\n7# RL\vhG$k3[W&.oNg'GVB"(`=52*$$""" b"""(B+<_pR,UFcb-n-Vr/1iJ-0JP==1c70M3&s#]4?Ykm5X@_(6q'R884cE""" b"""H9MJ8X:f1+h<)lt#=BSg3>[:ZC?t!MSA7]@cBPD3sCi+'.E,fo>FEMbN""" b"""G^4U^I!pHnJ:W<)KS>/9Ll%"IN/`jYOHG]iPa.Q$R$jD4S=Q7DTV8*TU""" b"""nsrdW2ZetXKAY/Yd(L?['d?O\\@K2_]Y2%o^qmn*`5Ta:aN;TJbg"GZd""" b"""*^:jeCE.%f\\,!5gtgiEi8N\\UjQ5OekiqBum-X60nF?)@o_%qPq"ad`""" b"""r;HT""": bytes(range(255)), b"""@:E_WAS,RgBkhF"D/O92EH6,BF`qtRH$VbC6UX@47n?3D92&&T:Jand;c""" b"""Hat='/U/0JP==1c70M3&r-I,;<FN.OZ`-3]oSW/g+A(H[P""": b'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ01234' b'56789!@#0^&*();:<>,. []{}', b'DJpY:@:Wn_DJ(RS': b'no padding..', b'H=_,8+Cf>,E,oN2F(oQ1z': b'zero compression\x00\x00\x00\x00', b'H=_,8+Cf>,E,oN2F(oQ1!!!!': b'zero compression\x00\x00\x00', b'6>q!aA79M(3WK-[!!': b"Boundary:\x00\x00\x00\x00", b';fH/TAKYK$D/aMV+<VdL': b'Space compr: ', b'rr': b'\xff', b's8N': b'\xff'*2, b's8W*': b'\xff'*3, b's8W-!': b'\xff'*4, } for data, res in tests.items(): eq(base64.a85decode(data), res, data) eq(base64.a85decode(data, adobe=False), res, data) eq(base64.a85decode(data.decode("ascii"), adobe=False), res, data) eq(base64.a85decode(b'<~' + data + b'~>', adobe=True), res, data) eq(base64.a85decode(data + b'~>', adobe=True), res, data) eq(base64.a85decode('<~%s~>' % data.decode("ascii"), adobe=True), res, data) eq(base64.a85decode(b'yy', foldspaces=True, adobe=False), b' '*8) eq(base64.a85decode(b'y+<Vd', foldspaces=True, adobe=False), b' '*7) eq(base64.a85decode(b'y+<U', foldspaces=True, adobe=False), b' '*6) eq(base64.a85decode(b'y+9', foldspaces=True, adobe=False), b' '*5) self.check_other_types(base64.a85decode, b'GB\\6`E-ZP=Df.1GEb>', b"www.python.org") def test_b85decode(self): eq = self.assertEqual tests = { b'': b'', b'cXxL#aCvlSZ*DGca%T': b'www.python.org', b"""009C61O)~M2nh-c3=Iws5D^j+6crX17#SKH9337X""" b"""AR!_nBqb&%C@Cr{EG;fCFflSSG&MFiI5|2yJUu=?KtV!7L`6nNNJ&ad""" b"""OifNtP*GA-R8>}2SXo+ITwPvYU}0ioWMyV&XlZI|Y;A6DaB*^Tbai%j""" b"""czJqze0_d@fPsR8goTEOh>41ejE#<ukdcy;l$Dm3n3<ZJoSmMZprN9p""" b"""q@|{(sHv)}tgWuEu(7hUw6(UkxVgH!yuH4^z`?@9#Kp$P$jQpf%+1cv""" b"""(9zP<)YaD4*xB0K+}+;a;Njxq<mKk)=;`X~?CtLF@bU8V^!4`l`1$(#""" b"""{Qdp""": bytes(range(255)), b"""VPa!sWoBn+X=-b1ZEkOHadLBXb#`}nd3r%YLqtVJM@UIZOH55pPf$@(""" b"""Q&d$}S6EqEFflSSG&MFiI5{CeBQRbjDkv#CIy^osE+AW7dwl""": b"""abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ""" b"""0123456789!@#0^&*();:<>,. []{}""", b'Zf_uPVPs@!Zf7no': b'no padding..', b'dS!BNAY*TBaB^jHb7^mG00000': b'zero compression\x00\x00\x00\x00', b'dS!BNAY*TBaB^jHb7^mG0000': b'zero compression\x00\x00\x00', b"""LT`0$WMOi7IsgCw00""": b"""Boundary:\x00\x00\x00\x00""", b'Q*dEpWgug3ZE$irARr(h': b'Space compr: ', b'{{': b'\xff', b'|Nj': b'\xff'*2, b'|Ns9': b'\xff'*3, b'|NsC0': b'\xff'*4, } for data, res in tests.items(): eq(base64.b85decode(data), res) eq(base64.b85decode(data.decode("ascii")), res) self.check_other_types(base64.b85decode, b'cXxL#aCvlSZ*DGca%T', b"www.python.org") def test_a85_padding(self): eq = self.assertEqual eq(base64.a85encode(b"x", pad=True), b'GQ7^D') eq(base64.a85encode(b"xx", pad=True), b"G^'2g") eq(base64.a85encode(b"xxx", pad=True), b'G^+H5') eq(base64.a85encode(b"xxxx", pad=True), b'G^+IX') eq(base64.a85encode(b"xxxxx", pad=True), b'G^+IXGQ7^D') eq(base64.a85decode(b'GQ7^D'), b"x\x00\x00\x00") eq(base64.a85decode(b"G^'2g"), b"xx\x00\x00") eq(base64.a85decode(b'G^+H5'), b"xxx\x00") eq(base64.a85decode(b'G^+IX'), b"xxxx") eq(base64.a85decode(b'G^+IXGQ7^D'), b"xxxxx\x00\x00\x00") def test_b85_padding(self): eq = self.assertEqual eq(base64.b85encode(b"x", pad=True), b'cmMzZ') eq(base64.b85encode(b"xx", pad=True), b'cz6H+') eq(base64.b85encode(b"xxx", pad=True), b'czAdK') eq(base64.b85encode(b"xxxx", pad=True), b'czAet') eq(base64.b85encode(b"xxxxx", pad=True), b'czAetcmMzZ') eq(base64.b85decode(b'cmMzZ'), b"x\x00\x00\x00") eq(base64.b85decode(b'cz6H+'), b"xx\x00\x00") eq(base64.b85decode(b'czAdK'), b"xxx\x00") eq(base64.b85decode(b'czAet'), b"xxxx") eq(base64.b85decode(b'czAetcmMzZ'), b"xxxxx\x00\x00\x00") def test_a85decode_errors(self): illegal = (set(range(32)) | set(range(118, 256))) - set(b' \t\n\r\v') for c in illegal: with self.assertRaises(ValueError, msg=bytes([c])): base64.a85decode(b'!!!!' + bytes([c])) with self.assertRaises(ValueError, msg=bytes([c])): base64.a85decode(b'!!!!' + bytes([c]), adobe=False) with self.assertRaises(ValueError, msg=bytes([c])): base64.a85decode(b'<~!!!!' + bytes([c]) + b'~>', adobe=True) self.assertRaises(ValueError, base64.a85decode, b"malformed", adobe=True) self.assertRaises(ValueError, base64.a85decode, b"<~still malformed", adobe=True) # With adobe=False (the default), Adobe framing markers are disallowed self.assertRaises(ValueError, base64.a85decode, b"<~~>") self.assertRaises(ValueError, base64.a85decode, b"<~~>", adobe=False) base64.a85decode(b"<~~>", adobe=True) # sanity check self.assertRaises(ValueError, base64.a85decode, b"abcx", adobe=False) self.assertRaises(ValueError, base64.a85decode, b"abcdey", adobe=False) self.assertRaises(ValueError, base64.a85decode, b"a b\nc", adobe=False, ignorechars=b"") self.assertRaises(ValueError, base64.a85decode, b's', adobe=False) self.assertRaises(ValueError, base64.a85decode, b's8', adobe=False) self.assertRaises(ValueError, base64.a85decode, b's8W', adobe=False) self.assertRaises(ValueError, base64.a85decode, b's8W-', adobe=False) self.assertRaises(ValueError, base64.a85decode, b's8W-"', adobe=False) def test_b85decode_errors(self): illegal = list(range(33)) + \ list(b'"\',./:[\\]') + \ list(range(128, 256)) for c in illegal: with self.assertRaises(ValueError, msg=bytes([c])): base64.b85decode(b'0000' + bytes([c])) self.assertRaises(ValueError, base64.b85decode, b'|') self.assertRaises(ValueError, base64.b85decode, b'|N') self.assertRaises(ValueError, base64.b85decode, b'|Ns') self.assertRaises(ValueError, base64.b85decode, b'|NsC') self.assertRaises(ValueError, base64.b85decode, b'|NsC1') def test_decode_nonascii_str(self): decode_funcs = (base64.b64decode, base64.standard_b64decode, base64.urlsafe_b64decode, base64.b32decode, base64.b16decode, base64.b85decode, base64.a85decode) for f in decode_funcs: self.assertRaises(ValueError, f, 'with non-ascii \xcb') def test_ErrorHeritage(self): self.assertTrue(issubclass(binascii.Error, ValueError)) class TestMain(unittest.TestCase): def tearDown(self): if os.path.exists(support.TESTFN): os.unlink(support.TESTFN) def get_output(self, *args): return script_helper.assert_python_ok('-m', 'base64', *args).out def test_encode_decode(self): output = self.get_output('-t') self.assertSequenceEqual(output.splitlines(), ( b"b'Aladdin:open sesame'", br"b'QWxhZGRpbjpvcGVuIHNlc2FtZQ==\n'", b"b'Aladdin:open sesame'", )) def test_encode_file(self): with open(support.TESTFN, 'wb') as fp: fp.write(b'a\xffb\n') output = self.get_output('-e', support.TESTFN) self.assertEqual(output.rstrip(), b'Yf9iCg==') def test_encode_from_stdin(self): with script_helper.spawn_python('-m', 'base64', '-e') as proc: out, err = proc.communicate(b'a\xffb\n') self.assertEqual(out.rstrip(), b'Yf9iCg==') self.assertIsNone(err) def test_decode(self): with open(support.TESTFN, 'wb') as fp: fp.write(b'Yf9iCg==') output = self.get_output('-d', support.TESTFN) self.assertEqual(output.rstrip(), b'a\xffb') if __name__ == '__main__': unittest.main()