py2docfx 0.1.16.dev2064350__py3-none-any.whl → 0.1.17__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- py2docfx/convert_prepare/environment.py +1 -3
- py2docfx/convert_prepare/get_source.py +1 -6
- py2docfx/convert_prepare/package_info.py +1 -1
- py2docfx/docfx_yaml/miss_reference.py +1 -1
- py2docfx/docfx_yaml/parameter_utils.py +58 -6
- py2docfx/docfx_yaml/tests/roots/test-translator-typing/code_with_typing.py +14 -0
- py2docfx/docfx_yaml/tests/roots/test-translator-typing/conf.py +18 -0
- py2docfx/docfx_yaml/tests/test_translator_typing.py +39 -0
- py2docfx/docfx_yaml/utils.py +2 -2
- py2docfx/venv/basevenv/Lib/site-packages/certifi/__init__.py +1 -1
- py2docfx/venv/basevenv/Lib/site-packages/certifi/core.py +1 -32
- py2docfx/venv/basevenv/Lib/site-packages/charset_normalizer/cli/__main__.py +62 -2
- py2docfx/venv/basevenv/Lib/site-packages/charset_normalizer/constant.py +17 -0
- py2docfx/venv/basevenv/Lib/site-packages/charset_normalizer/legacy.py +1 -3
- py2docfx/venv/basevenv/Lib/site-packages/charset_normalizer/md.py +19 -14
- py2docfx/venv/basevenv/Lib/site-packages/charset_normalizer/utils.py +6 -0
- py2docfx/venv/basevenv/Lib/site-packages/charset_normalizer/version.py +1 -1
- py2docfx/venv/basevenv/Lib/site-packages/packaging/__init__.py +1 -1
- py2docfx/venv/basevenv/Lib/site-packages/packaging/_elffile.py +1 -2
- py2docfx/venv/basevenv/Lib/site-packages/packaging/_manylinux.py +1 -2
- py2docfx/venv/basevenv/Lib/site-packages/packaging/_parser.py +1 -2
- py2docfx/venv/basevenv/Lib/site-packages/packaging/_tokenizer.py +5 -4
- py2docfx/venv/basevenv/Lib/site-packages/packaging/licenses/__init__.py +1 -1
- py2docfx/venv/basevenv/Lib/site-packages/packaging/markers.py +53 -22
- py2docfx/venv/basevenv/Lib/site-packages/packaging/metadata.py +1 -2
- py2docfx/venv/basevenv/Lib/site-packages/packaging/specifiers.py +1 -2
- py2docfx/venv/basevenv/Lib/site-packages/packaging/tags.py +39 -0
- py2docfx/venv/basevenv/Lib/site-packages/pkg_resources/__init__.py +6 -7
- py2docfx/venv/basevenv/Lib/site-packages/pygments/__init__.py +1 -1
- py2docfx/venv/basevenv/Lib/site-packages/pygments/lexers/_sql_builtins.py +106 -0
- py2docfx/venv/basevenv/Lib/site-packages/pygments/lexers/scripting.py +5 -3
- py2docfx/venv/basevenv/Lib/site-packages/pygments/lexers/sql.py +24 -118
- py2docfx/venv/basevenv/Lib/site-packages/requests/__version__.py +2 -2
- py2docfx/venv/basevenv/Lib/site-packages/requests/compat.py +12 -0
- py2docfx/venv/basevenv/Lib/site-packages/requests/models.py +3 -1
- py2docfx/venv/basevenv/Lib/site-packages/requests/utils.py +6 -16
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/__init__.py +0 -38
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/_discovery.py +33 -0
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/_distutils/command/build_scripts.py +1 -1
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/_distutils/command/config.py +0 -2
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/_distutils/compilers/C/tests/test_unix.py +63 -0
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/_distutils/compilers/C/unix.py +5 -6
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/_entry_points.py +4 -0
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/_normalization.py +0 -2
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/_path.py +12 -3
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/_reqs.py +1 -1
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/_scripts.py +361 -0
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/_shutil.py +6 -0
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/build_meta.py +25 -37
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/command/bdist_egg.py +9 -11
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/command/bdist_wheel.py +1 -1
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/command/build_ext.py +29 -28
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/command/develop.py +39 -179
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/command/easy_install.py +17 -2352
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/command/editable_wheel.py +14 -31
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/command/egg_info.py +0 -2
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/command/install.py +3 -55
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/command/install_scripts.py +5 -11
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/command/sdist.py +1 -1
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/compat/py310.py +11 -0
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/dist.py +10 -12
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/installer.py +34 -29
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/contexts.py +0 -14
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/fixtures.py +235 -0
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/integration/test_pbr.py +20 -0
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/test_build_meta.py +0 -24
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/test_develop.py +1 -64
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/test_dist.py +2 -2
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/test_dist_info.py +0 -63
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/test_editable_install.py +15 -41
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/test_egg_info.py +3 -2
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/test_scripts.py +12 -0
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/test_wheel.py +12 -36
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/test_windows_wrappers.py +3 -4
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/wheel.py +49 -24
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/__init__.py +6 -0
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/arabic_stemmer.py +798 -797
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/armenian_stemmer.py +212 -213
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/basestemmer.py +20 -54
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/basque_stemmer.py +202 -228
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/catalan_stemmer.py +370 -375
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/danish_stemmer.py +63 -61
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/dutch_porter_stemmer.py +466 -0
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/dutch_stemmer.py +1217 -343
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/english_stemmer.py +295 -264
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/esperanto_stemmer.py +588 -0
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/estonian_stemmer.py +850 -0
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/finnish_stemmer.py +144 -143
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/french_stemmer.py +308 -246
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/german_stemmer.py +224 -167
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/greek_stemmer.py +1314 -1313
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/hindi_stemmer.py +39 -38
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/hungarian_stemmer.py +231 -256
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/indonesian_stemmer.py +61 -64
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/irish_stemmer.py +101 -106
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/italian_stemmer.py +272 -272
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/lithuanian_stemmer.py +233 -240
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/nepali_stemmer.py +108 -134
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/norwegian_stemmer.py +108 -63
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/porter_stemmer.py +101 -108
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/portuguese_stemmer.py +241 -250
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/romanian_stemmer.py +332 -296
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/russian_stemmer.py +178 -179
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/serbian_stemmer.py +2331 -2332
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/spanish_stemmer.py +254 -259
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/swedish_stemmer.py +143 -70
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/tamil_stemmer.py +638 -1491
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/turkish_stemmer.py +326 -292
- py2docfx/venv/basevenv/Lib/site-packages/snowballstemmer/yiddish_stemmer.py +245 -246
- py2docfx/venv/basevenv/Lib/site-packages/urllib3/_version.py +2 -2
- py2docfx/venv/basevenv/Lib/site-packages/urllib3/connection.py +87 -38
- py2docfx/venv/basevenv/Lib/site-packages/urllib3/contrib/emscripten/fetch.py +20 -0
- py2docfx/venv/basevenv/Lib/site-packages/urllib3/poolmanager.py +17 -1
- py2docfx/venv/basevenv/Lib/site-packages/urllib3/response.py +53 -24
- py2docfx/venv/basevenv/Lib/site-packages/urllib3/util/request.py +12 -4
- py2docfx/venv/basevenv/Lib/site-packages/urllib3/util/ssl_.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/core/_version.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/core/pipeline/_base_async.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/core/pipeline/transport/_aiohttp.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/core/pipeline/transport/_base_async.py +2 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/core/pipeline/transport/_requests_asyncio.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/core/rest/_aiohttp.py +2 -2
- py2docfx/venv/venv1/Lib/site-packages/azure/core/rest/_requests_asyncio.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/core/tracing/opentelemetry.py +13 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/core/utils/_pipeline_transport_rest_shared_async.py +2 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/core/utils/_utils.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/_constants.py +1 -0
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/_credentials/default.py +23 -2
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/_credentials/environment.py +12 -16
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/_credentials/service_fabric.py +22 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/_credentials/user_password.py +10 -6
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/_credentials/vscode.py +13 -4
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/_internal/auth_code_redirect_handler.py +3 -5
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/_internal/msal_client.py +2 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/_persistent_cache.py +3 -2
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/_version.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/aio/_credentials/azd_cli.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/aio/_credentials/azure_cli.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/aio/_credentials/azure_powershell.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/aio/_credentials/chained.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/aio/_credentials/default.py +22 -2
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/aio/_credentials/environment.py +2 -2
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/aio/_credentials/service_fabric.py +17 -1
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/aio/_credentials/vscode.py +4 -4
- py2docfx/venv/venv1/Lib/site-packages/certifi/__init__.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/certifi/core.py +1 -32
- py2docfx/venv/venv1/Lib/site-packages/charset_normalizer/cli/__main__.py +62 -2
- py2docfx/venv/venv1/Lib/site-packages/charset_normalizer/constant.py +17 -0
- py2docfx/venv/venv1/Lib/site-packages/charset_normalizer/legacy.py +1 -3
- py2docfx/venv/venv1/Lib/site-packages/charset_normalizer/md.py +19 -14
- py2docfx/venv/venv1/Lib/site-packages/charset_normalizer/utils.py +6 -0
- py2docfx/venv/venv1/Lib/site-packages/charset_normalizer/version.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/__about__.py +2 -2
- py2docfx/venv/venv1/Lib/site-packages/cryptography/__init__.py +2 -2
- py2docfx/venv/venv1/Lib/site-packages/cryptography/fernet.py +2 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/_oid.py +35 -2
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/backends/openssl/backend.py +33 -10
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/__init__.pyi +14 -5
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/ocsp.pyi +2 -2
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/openssl/__init__.pyi +3 -0
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/openssl/aead.pyi +49 -45
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/openssl/ciphers.pyi +2 -2
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/openssl/ed25519.pyi +2 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/openssl/ed448.pyi +2 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/openssl/hashes.pyi +10 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/openssl/hmac.pyi +3 -2
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/openssl/kdf.pyi +8 -2
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/openssl/keys.pyi +3 -2
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/openssl/poly1305.pyi +6 -4
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/openssl/x25519.pyi +2 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/openssl/x448.pyi +2 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/pkcs12.pyi +9 -3
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/pkcs7.pyi +7 -6
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/test_support.pyi +2 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/_rust/x509.pyi +79 -12
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/openssl/_conditional.py +9 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/bindings/openssl/binding.py +2 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/decrepit/ciphers/algorithms.py +5 -0
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/_cipheralgorithm.py +4 -2
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/_serialization.py +1 -2
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/asymmetric/dh.py +12 -0
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/asymmetric/dsa.py +16 -3
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/asymmetric/ec.py +47 -3
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/asymmetric/ed25519.py +16 -3
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/asymmetric/ed448.py +16 -3
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/asymmetric/rsa.py +14 -0
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/asymmetric/x25519.py +14 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/asymmetric/x448.py +14 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/ciphers/algorithms.py +6 -6
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/ciphers/base.py +5 -4
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/ciphers/modes.py +18 -18
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/hashes.py +5 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/kdf/concatkdf.py +5 -4
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/kdf/hkdf.py +4 -4
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/kdf/kbkdf.py +7 -4
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/kdf/pbkdf2.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/kdf/x963kdf.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/padding.py +7 -121
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/serialization/__init__.py +2 -0
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/serialization/pkcs12.py +21 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/serialization/pkcs7.py +48 -6
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/serialization/ssh.py +68 -18
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/twofactor/hotp.py +3 -2
- py2docfx/venv/venv1/Lib/site-packages/cryptography/hazmat/primitives/twofactor/totp.py +2 -1
- py2docfx/venv/venv1/Lib/site-packages/cryptography/utils.py +15 -3
- py2docfx/venv/venv1/Lib/site-packages/cryptography/x509/__init__.py +3 -0
- py2docfx/venv/venv1/Lib/site-packages/cryptography/x509/base.py +39 -6
- py2docfx/venv/venv1/Lib/site-packages/cryptography/x509/extensions.py +100 -49
- py2docfx/venv/venv1/Lib/site-packages/cryptography/x509/name.py +27 -15
- py2docfx/venv/venv1/Lib/site-packages/cryptography/x509/ocsp.py +60 -25
- py2docfx/venv/venv1/Lib/site-packages/cryptography/x509/oid.py +2 -0
- py2docfx/venv/venv1/Lib/site-packages/cryptography/x509/verification.py +6 -0
- py2docfx/venv/venv1/Lib/site-packages/google/api_core/bidi.py +17 -4
- py2docfx/venv/venv1/Lib/site-packages/google/api_core/client_info.py +6 -0
- py2docfx/venv/venv1/Lib/site-packages/google/api_core/gapic_v1/client_info.py +1 -0
- py2docfx/venv/venv1/Lib/site-packages/google/api_core/retry/retry_base.py +13 -4
- py2docfx/venv/venv1/Lib/site-packages/google/api_core/retry/retry_streaming.py +7 -6
- py2docfx/venv/venv1/Lib/site-packages/google/api_core/retry/retry_streaming_async.py +8 -5
- py2docfx/venv/venv1/Lib/site-packages/google/api_core/retry/retry_unary.py +7 -6
- py2docfx/venv/venv1/Lib/site-packages/google/api_core/retry/retry_unary_async.py +7 -6
- py2docfx/venv/venv1/Lib/site-packages/google/api_core/version.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/google/auth/_default.py +2 -36
- py2docfx/venv/venv1/Lib/site-packages/google/auth/_helpers.py +240 -0
- py2docfx/venv/venv1/Lib/site-packages/google/auth/aio/_helpers.py +62 -0
- py2docfx/venv/venv1/Lib/site-packages/google/auth/aio/transport/aiohttp.py +6 -0
- py2docfx/venv/venv1/Lib/site-packages/google/auth/compute_engine/_metadata.py +5 -1
- py2docfx/venv/venv1/Lib/site-packages/google/auth/compute_engine/credentials.py +2 -1
- py2docfx/venv/venv1/Lib/site-packages/google/auth/identity_pool.py +91 -2
- py2docfx/venv/venv1/Lib/site-packages/google/auth/impersonated_credentials.py +75 -0
- py2docfx/venv/venv1/Lib/site-packages/google/auth/transport/__init__.py +1 -0
- py2docfx/venv/venv1/Lib/site-packages/google/auth/transport/_aiohttp_requests.py +8 -1
- py2docfx/venv/venv1/Lib/site-packages/google/auth/transport/_http_client.py +3 -1
- py2docfx/venv/venv1/Lib/site-packages/google/auth/transport/requests.py +4 -1
- py2docfx/venv/venv1/Lib/site-packages/google/auth/transport/urllib3.py +15 -5
- py2docfx/venv/venv1/Lib/site-packages/google/auth/version.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/google/oauth2/id_token.py +12 -0
- py2docfx/venv/venv1/Lib/site-packages/google/oauth2/webauthn_types.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/__init__.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/any.py +15 -1
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/any_pb2.py +3 -3
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/api_pb2.py +3 -3
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/compiler/plugin_pb2.py +3 -3
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/descriptor.py +15 -2
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/descriptor_pb2.py +258 -113
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/descriptor_pool.py +22 -8
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/duration_pb2.py +3 -3
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/empty_pb2.py +3 -3
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/field_mask_pb2.py +3 -3
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/internal/decoder.py +106 -23
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/internal/field_mask.py +3 -1
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/internal/python_edition_defaults.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/internal/python_message.py +21 -18
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/internal/testing_refleaks.py +8 -2
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/internal/well_known_types.py +60 -43
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/json_format.py +4 -5
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/message_factory.py +16 -0
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/runtime_version.py +2 -2
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/source_context_pb2.py +3 -3
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/struct_pb2.py +3 -3
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/text_format.py +11 -7
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/timestamp_pb2.py +3 -3
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/type_pb2.py +3 -3
- py2docfx/venv/venv1/Lib/site-packages/google/protobuf/wrappers_pb2.py +3 -3
- py2docfx/venv/venv1/Lib/site-packages/google/rpc/error_details_pb2.py +29 -23
- py2docfx/venv/venv1/Lib/site-packages/google/rpc/error_details_pb2.pyi +41 -2
- py2docfx/venv/venv1/Lib/site-packages/msal/application.py +1 -0
- py2docfx/venv/venv1/Lib/site-packages/msal/individual_cache.py +9 -5
- py2docfx/venv/venv1/Lib/site-packages/msal/managed_identity.py +4 -5
- py2docfx/venv/venv1/Lib/site-packages/msal/sku.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/msal/throttled_http_client.py +58 -30
- py2docfx/venv/venv1/Lib/site-packages/opencensus/__init__.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/__init__.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/__init__.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/common/__init__.py +138 -138
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/common/exporter.py +93 -93
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/common/processor.py +63 -63
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/common/protocol.py +206 -206
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/common/storage.py +205 -205
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/common/transport.py +355 -355
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/common/utils.py +79 -79
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/common/version.py +15 -15
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/log_exporter/__init__.py +314 -314
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/metrics_exporter/__init__.py +190 -190
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/metrics_exporter/standard_metrics/__init__.py +62 -62
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/metrics_exporter/standard_metrics/cpu.py +50 -50
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/metrics_exporter/standard_metrics/http_requests.py +176 -176
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/metrics_exporter/standard_metrics/memory.py +42 -42
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/metrics_exporter/standard_metrics/process.py +87 -87
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/statsbeat/__init__.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/statsbeat/state.py +50 -50
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/statsbeat/statsbeat.py +100 -100
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/statsbeat/statsbeat_metrics.py +480 -480
- py2docfx/venv/venv1/Lib/site-packages/opencensus/ext/azure/trace_exporter/__init__.py +236 -236
- py2docfx/venv/venv1/Lib/site-packages/packaging/__init__.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/packaging/_elffile.py +1 -2
- py2docfx/venv/venv1/Lib/site-packages/packaging/_manylinux.py +1 -2
- py2docfx/venv/venv1/Lib/site-packages/packaging/_parser.py +1 -2
- py2docfx/venv/venv1/Lib/site-packages/packaging/_tokenizer.py +5 -4
- py2docfx/venv/venv1/Lib/site-packages/packaging/licenses/__init__.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/packaging/markers.py +53 -22
- py2docfx/venv/venv1/Lib/site-packages/packaging/metadata.py +1 -2
- py2docfx/venv/venv1/Lib/site-packages/packaging/specifiers.py +1 -2
- py2docfx/venv/venv1/Lib/site-packages/packaging/tags.py +39 -0
- py2docfx/venv/venv1/Lib/site-packages/pkg_resources/__init__.py +6 -7
- py2docfx/venv/venv1/Lib/site-packages/requests/__version__.py +2 -2
- py2docfx/venv/venv1/Lib/site-packages/requests/compat.py +12 -0
- py2docfx/venv/venv1/Lib/site-packages/requests/models.py +3 -1
- py2docfx/venv/venv1/Lib/site-packages/requests/utils.py +6 -16
- py2docfx/venv/venv1/Lib/site-packages/rsa/__init__.py +2 -2
- py2docfx/venv/venv1/Lib/site-packages/rsa/asn1.py +52 -52
- py2docfx/venv/venv1/Lib/site-packages/rsa/cli.py +321 -321
- py2docfx/venv/venv1/Lib/site-packages/rsa/common.py +184 -184
- py2docfx/venv/venv1/Lib/site-packages/rsa/core.py +53 -53
- py2docfx/venv/venv1/Lib/site-packages/rsa/key.py +858 -858
- py2docfx/venv/venv1/Lib/site-packages/rsa/parallel.py +96 -96
- py2docfx/venv/venv1/Lib/site-packages/rsa/pem.py +134 -134
- py2docfx/venv/venv1/Lib/site-packages/rsa/pkcs1.py +485 -485
- py2docfx/venv/venv1/Lib/site-packages/rsa/pkcs1_v2.py +100 -100
- py2docfx/venv/venv1/Lib/site-packages/rsa/prime.py +198 -198
- py2docfx/venv/venv1/Lib/site-packages/rsa/py.typed +1 -1
- py2docfx/venv/venv1/Lib/site-packages/rsa/randnum.py +95 -95
- py2docfx/venv/venv1/Lib/site-packages/rsa/transform.py +72 -72
- py2docfx/venv/venv1/Lib/site-packages/rsa/util.py +97 -97
- py2docfx/venv/venv1/Lib/site-packages/setuptools/__init__.py +0 -38
- py2docfx/venv/venv1/Lib/site-packages/setuptools/_discovery.py +33 -0
- py2docfx/venv/venv1/Lib/site-packages/setuptools/_distutils/command/build_scripts.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/setuptools/_distutils/command/config.py +0 -2
- py2docfx/venv/venv1/Lib/site-packages/setuptools/_distutils/compilers/C/tests/test_unix.py +63 -0
- py2docfx/venv/venv1/Lib/site-packages/setuptools/_distutils/compilers/C/unix.py +5 -6
- py2docfx/venv/venv1/Lib/site-packages/setuptools/_entry_points.py +4 -0
- py2docfx/venv/venv1/Lib/site-packages/setuptools/_normalization.py +0 -2
- py2docfx/venv/venv1/Lib/site-packages/setuptools/_path.py +12 -3
- py2docfx/venv/venv1/Lib/site-packages/setuptools/_reqs.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/setuptools/_scripts.py +361 -0
- py2docfx/venv/venv1/Lib/site-packages/setuptools/_shutil.py +6 -0
- py2docfx/venv/venv1/Lib/site-packages/setuptools/build_meta.py +25 -37
- py2docfx/venv/venv1/Lib/site-packages/setuptools/command/bdist_egg.py +9 -11
- py2docfx/venv/venv1/Lib/site-packages/setuptools/command/bdist_wheel.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/setuptools/command/build_ext.py +29 -28
- py2docfx/venv/venv1/Lib/site-packages/setuptools/command/develop.py +39 -179
- py2docfx/venv/venv1/Lib/site-packages/setuptools/command/easy_install.py +17 -2352
- py2docfx/venv/venv1/Lib/site-packages/setuptools/command/editable_wheel.py +14 -31
- py2docfx/venv/venv1/Lib/site-packages/setuptools/command/egg_info.py +0 -2
- py2docfx/venv/venv1/Lib/site-packages/setuptools/command/install.py +3 -55
- py2docfx/venv/venv1/Lib/site-packages/setuptools/command/install_scripts.py +5 -11
- py2docfx/venv/venv1/Lib/site-packages/setuptools/command/sdist.py +1 -1
- py2docfx/venv/venv1/Lib/site-packages/setuptools/compat/py310.py +11 -0
- py2docfx/venv/venv1/Lib/site-packages/setuptools/dist.py +10 -12
- py2docfx/venv/venv1/Lib/site-packages/setuptools/installer.py +34 -29
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/contexts.py +0 -14
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/fixtures.py +235 -0
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/integration/test_pbr.py +20 -0
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/test_build_meta.py +0 -24
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/test_develop.py +1 -64
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/test_dist.py +2 -2
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/test_dist_info.py +0 -63
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/test_editable_install.py +15 -41
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/test_egg_info.py +3 -2
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/test_scripts.py +12 -0
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/test_wheel.py +12 -36
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/test_windows_wrappers.py +3 -4
- py2docfx/venv/venv1/Lib/site-packages/setuptools/wheel.py +49 -24
- py2docfx/venv/venv1/Lib/site-packages/typing_extensions.py +357 -703
- py2docfx/venv/venv1/Lib/site-packages/urllib3/_version.py +2 -2
- py2docfx/venv/venv1/Lib/site-packages/urllib3/connection.py +87 -38
- py2docfx/venv/venv1/Lib/site-packages/urllib3/contrib/emscripten/fetch.py +20 -0
- py2docfx/venv/venv1/Lib/site-packages/urllib3/poolmanager.py +17 -1
- py2docfx/venv/venv1/Lib/site-packages/urllib3/response.py +53 -24
- py2docfx/venv/venv1/Lib/site-packages/urllib3/util/request.py +12 -4
- py2docfx/venv/venv1/Lib/site-packages/urllib3/util/ssl_.py +1 -1
- {py2docfx-0.1.16.dev2064350.dist-info → py2docfx-0.1.17.dist-info}/METADATA +1 -1
- {py2docfx-0.1.16.dev2064350.dist-info → py2docfx-0.1.17.dist-info}/RECORD +374 -372
- {py2docfx-0.1.16.dev2064350.dist-info → py2docfx-0.1.17.dist-info}/WHEEL +1 -1
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/package_index.py +0 -1137
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/sandbox.py +0 -536
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/server.py +0 -86
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/test_easy_install.py +0 -1476
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/test_packageindex.py +0 -267
- py2docfx/venv/basevenv/Lib/site-packages/setuptools/tests/test_sandbox.py +0 -134
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/_credentials/application.py +0 -119
- py2docfx/venv/venv1/Lib/site-packages/azure/identity/aio/_credentials/application.py +0 -121
- py2docfx/venv/venv1/Lib/site-packages/setuptools/package_index.py +0 -1137
- py2docfx/venv/venv1/Lib/site-packages/setuptools/sandbox.py +0 -536
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/server.py +0 -86
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/test_easy_install.py +0 -1476
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/test_packageindex.py +0 -267
- py2docfx/venv/venv1/Lib/site-packages/setuptools/tests/test_sandbox.py +0 -134
- {py2docfx-0.1.16.dev2064350.dist-info → py2docfx-0.1.17.dist-info}/top_level.txt +0 -0
@@ -6,16 +6,37 @@ import functools
|
|
6
6
|
import os
|
7
7
|
from typing import Dict, Optional, Any
|
8
8
|
|
9
|
+
from azure.core.credentials import AccessToken, AccessTokenInfo, TokenRequestOptions
|
10
|
+
from azure.core.exceptions import ClientAuthenticationError
|
9
11
|
from azure.core.pipeline.transport import HttpRequest
|
10
12
|
|
11
13
|
from .._constants import EnvironmentVariables
|
12
14
|
from .._internal.msal_managed_identity_client import MsalManagedIdentityClient
|
13
15
|
|
14
16
|
|
17
|
+
SERVICE_FABRIC_ERROR_MESSAGE = (
|
18
|
+
"Specifying a client_id or identity_config is not supported by the Service Fabric managed identity environment. "
|
19
|
+
"The managed identity configuration is determined by the Service Fabric cluster resource configuration. "
|
20
|
+
"See https://aka.ms/servicefabricmi for more information."
|
21
|
+
)
|
22
|
+
|
23
|
+
|
15
24
|
class ServiceFabricCredential(MsalManagedIdentityClient):
|
16
25
|
def get_unavailable_message(self, desc: str = "") -> str:
|
17
26
|
return f"Service Fabric managed identity configuration not found in environment. {desc}"
|
18
27
|
|
28
|
+
def get_token(
|
29
|
+
self, *scopes: str, claims: Optional[str] = None, tenant_id: Optional[str] = None, **kwargs: Any
|
30
|
+
) -> AccessToken:
|
31
|
+
if self._settings.get("client_id") or self._settings.get("identity_config"):
|
32
|
+
raise ClientAuthenticationError(message=SERVICE_FABRIC_ERROR_MESSAGE)
|
33
|
+
return super().get_token(*scopes, claims=claims, tenant_id=tenant_id, **kwargs)
|
34
|
+
|
35
|
+
def get_token_info(self, *scopes: str, options: Optional[TokenRequestOptions] = None) -> AccessTokenInfo:
|
36
|
+
if self._settings.get("client_id") or self._settings.get("identity_config"):
|
37
|
+
raise ClientAuthenticationError(message=SERVICE_FABRIC_ERROR_MESSAGE)
|
38
|
+
return super().get_token_info(*scopes, options=options)
|
39
|
+
|
19
40
|
|
20
41
|
def _get_client_args(**kwargs: Any) -> Optional[Dict]:
|
21
42
|
url = os.environ.get(EnvironmentVariables.IDENTITY_ENDPOINT)
|
@@ -28,7 +49,7 @@ def _get_client_args(**kwargs: Any) -> Optional[Dict]:
|
|
28
49
|
return dict(
|
29
50
|
kwargs,
|
30
51
|
base_headers={"Secret": secret},
|
31
|
-
connection_verify=False,
|
52
|
+
connection_verify=False, # pylint: disable=do-not-hardcode-connection-verify
|
32
53
|
request_factory=functools.partial(_get_request, url),
|
33
54
|
)
|
34
55
|
|
@@ -63,12 +63,16 @@ class UsernamePasswordCredential(InteractiveCredential):
|
|
63
63
|
"""
|
64
64
|
|
65
65
|
def __init__(self, client_id: str, username: str, password: str, **kwargs: Any) -> None:
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
66
|
+
if not kwargs.pop("_silence_deprecation_warning", False):
|
67
|
+
# Only emit the deprecation warning if the credential was constructed directly and not via
|
68
|
+
# EnvironmentCredential since EnvironmentCredential will emit its own deprecation
|
69
|
+
# warning if it is used to create a UsernamePasswordCredential.
|
70
|
+
warnings.warn(
|
71
|
+
f"{self.__class__.__name__} is deprecated, as it doesn't support multifactor "
|
72
|
+
"authentication (MFA). For more details, see https://aka.ms/azsdk/identity/mfa.",
|
73
|
+
category=DeprecationWarning,
|
74
|
+
stacklevel=2,
|
75
|
+
)
|
72
76
|
# The base class will accept an AuthenticationRecord, allowing this credential to authenticate silently the
|
73
77
|
# first time it's asked for a token. However, we want to ensure this first authentication is not silent, to
|
74
78
|
# validate the given password. This class therefore doesn't document the authentication_record argument, and we
|
@@ -6,6 +6,7 @@ import abc
|
|
6
6
|
import os
|
7
7
|
import sys
|
8
8
|
from typing import cast, Any, Dict, Optional
|
9
|
+
import warnings
|
9
10
|
|
10
11
|
from azure.core.credentials import AccessToken, TokenRequestOptions, AccessTokenInfo
|
11
12
|
from azure.core.exceptions import ClientAuthenticationError
|
@@ -26,6 +27,14 @@ else:
|
|
26
27
|
|
27
28
|
class _VSCodeCredentialBase(abc.ABC):
|
28
29
|
def __init__(self, **kwargs: Any) -> None:
|
30
|
+
warnings.warn(
|
31
|
+
"This credential is deprecated because the Azure Account extension for Visual Studio Code, which this "
|
32
|
+
"credential relies on, has been deprecated. See the Azure Account extension deprecation notice here: "
|
33
|
+
"https://github.com/microsoft/vscode-azure-account/issues/964. Consider using other developer credentials "
|
34
|
+
"such as AzureCliCredential, AzureDeveloperCliCredential, or AzurePowerShellCredential.",
|
35
|
+
DeprecationWarning,
|
36
|
+
stacklevel=2,
|
37
|
+
)
|
29
38
|
super(_VSCodeCredentialBase, self).__init__()
|
30
39
|
|
31
40
|
user_settings = get_user_settings()
|
@@ -107,10 +116,10 @@ class _VSCodeCredentialBase(abc.ABC):
|
|
107
116
|
class VisualStudioCodeCredential(_VSCodeCredentialBase, GetTokenMixin):
|
108
117
|
"""Authenticates as the Azure user signed in to Visual Studio Code via the 'Azure Account' extension.
|
109
118
|
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
119
|
+
**Deprecated**: This credential is deprecated because the Azure Account extension for Visual Studio Code, which
|
120
|
+
this credential relies on, has been deprecated. See the Azure Account extension deprecation notice here:
|
121
|
+
https://github.com/microsoft/vscode-azure-account/issues/964. Consider using other developer credentials such as
|
122
|
+
AzureCliCredential, AzureDeveloperCliCredential, or AzurePowerShellCredential.
|
114
123
|
|
115
124
|
:keyword str authority: Authority of a Microsoft Entra endpoint, for example "login.microsoftonline.com".
|
116
125
|
This argument is required for a custom cloud and usually unnecessary otherwise. Defaults to the authority
|
py2docfx/venv/venv1/Lib/site-packages/azure/identity/_internal/auth_code_redirect_handler.py
CHANGED
@@ -35,15 +35,13 @@ class AuthCodeRedirectHandler(BaseHTTPRequestHandler):
|
|
35
35
|
class AuthCodeRedirectServer(HTTPServer):
|
36
36
|
"""HTTP server that listens for the redirect request following an authorization code authentication"""
|
37
37
|
|
38
|
-
query_params
|
38
|
+
query_params: Mapping[str, Any] = {}
|
39
39
|
|
40
|
-
def __init__(self, hostname, port, timeout):
|
41
|
-
# type: (str, int, int) -> None
|
40
|
+
def __init__(self, hostname: str, port: int, timeout: int) -> None:
|
42
41
|
HTTPServer.__init__(self, (hostname, port), AuthCodeRedirectHandler)
|
43
42
|
self.timeout = timeout
|
44
43
|
|
45
|
-
def wait_for_redirect(self):
|
46
|
-
# type: () -> Mapping[str, Any]
|
44
|
+
def wait_for_redirect(self) -> Mapping[str, Any]:
|
47
45
|
while not self.query_params:
|
48
46
|
try:
|
49
47
|
self.handle_request()
|
@@ -131,7 +131,8 @@ class MsalClient: # pylint:disable=client-accepts-api-version-keyword
|
|
131
131
|
# response to an auth request, so no credential will want to include it with an exception
|
132
132
|
content = response.context.get(ContentDecodePolicy.CONTEXT_NAME)
|
133
133
|
if content and "error" in content:
|
134
|
-
|
134
|
+
error_code = content["error"] if isinstance(content, dict) else "oauth_error"
|
135
|
+
self._local.error = (error_code, response.http_response)
|
135
136
|
|
136
137
|
def __getstate__(self) -> Dict[str, Any]: # pylint:disable=client-method-name-no-double-underscore
|
137
138
|
state = self.__dict__.copy()
|
@@ -67,8 +67,9 @@ def _load_persistent_cache(
|
|
67
67
|
return msal_extensions.PersistedTokenCache(persistence)
|
68
68
|
|
69
69
|
|
70
|
-
def _get_persistence(
|
71
|
-
|
70
|
+
def _get_persistence(
|
71
|
+
allow_unencrypted: bool, account_name: str, cache_name: str
|
72
|
+
) -> "msal_extensions.persistence.BasePersistence":
|
72
73
|
"""Get an msal_extensions persistence instance for the current platform.
|
73
74
|
|
74
75
|
On Windows the cache is a file protected by the Data Protection API. On Linux and macOS the cache is stored by
|
@@ -2,7 +2,7 @@
|
|
2
2
|
# Copyright (c) Microsoft Corporation.
|
3
3
|
# Licensed under the MIT License.
|
4
4
|
# ------------------------------------
|
5
|
-
import asyncio
|
5
|
+
import asyncio # pylint: disable=do-not-import-asyncio
|
6
6
|
import sys
|
7
7
|
from typing import Any, cast, List, Optional
|
8
8
|
from azure.core.credentials import AccessToken, AccessTokenInfo, TokenRequestOptions
|
@@ -125,6 +125,7 @@ class DefaultAzureCredential(ChainedTokenCredential):
|
|
125
125
|
|
126
126
|
process_timeout = kwargs.pop("process_timeout", 10)
|
127
127
|
|
128
|
+
token_credentials_env = os.environ.get(EnvironmentVariables.AZURE_TOKEN_CREDENTIALS, "").strip().lower()
|
128
129
|
exclude_workload_identity_credential = kwargs.pop("exclude_workload_identity_credential", False)
|
129
130
|
exclude_visual_studio_code_credential = kwargs.pop("exclude_visual_studio_code_credential", True)
|
130
131
|
exclude_developer_cli_credential = kwargs.pop("exclude_developer_cli_credential", False)
|
@@ -134,6 +135,25 @@ class DefaultAzureCredential(ChainedTokenCredential):
|
|
134
135
|
exclude_shared_token_cache_credential = kwargs.pop("exclude_shared_token_cache_credential", False)
|
135
136
|
exclude_powershell_credential = kwargs.pop("exclude_powershell_credential", False)
|
136
137
|
|
138
|
+
if token_credentials_env == "dev":
|
139
|
+
# In dev mode, use only developer credentials
|
140
|
+
exclude_environment_credential = True
|
141
|
+
exclude_managed_identity_credential = True
|
142
|
+
exclude_workload_identity_credential = True
|
143
|
+
elif token_credentials_env == "prod":
|
144
|
+
# In prod mode, use only production credentials
|
145
|
+
exclude_shared_token_cache_credential = True
|
146
|
+
exclude_visual_studio_code_credential = True
|
147
|
+
exclude_cli_credential = True
|
148
|
+
exclude_developer_cli_credential = True
|
149
|
+
exclude_powershell_credential = True
|
150
|
+
elif token_credentials_env != "":
|
151
|
+
# If the environment variable is set to something other than dev or prod, raise an error
|
152
|
+
raise ValueError(
|
153
|
+
f"Invalid value for {EnvironmentVariables.AZURE_TOKEN_CREDENTIALS}: {token_credentials_env}. "
|
154
|
+
"Valid values are 'dev' or 'prod'."
|
155
|
+
)
|
156
|
+
|
137
157
|
credentials: List[AsyncSupportsTokenInfo] = []
|
138
158
|
within_dac.set(True)
|
139
159
|
if not exclude_environment_credential:
|
@@ -146,7 +166,7 @@ class DefaultAzureCredential(ChainedTokenCredential):
|
|
146
166
|
client_id=cast(str, client_id),
|
147
167
|
tenant_id=workload_identity_tenant_id,
|
148
168
|
token_file_path=os.environ[EnvironmentVariables.AZURE_FEDERATED_TOKEN_FILE],
|
149
|
-
**kwargs
|
169
|
+
**kwargs,
|
150
170
|
)
|
151
171
|
)
|
152
172
|
if not exclude_managed_identity_credential:
|
@@ -154,7 +174,7 @@ class DefaultAzureCredential(ChainedTokenCredential):
|
|
154
174
|
ManagedIdentityCredential(
|
155
175
|
client_id=managed_identity_client_id,
|
156
176
|
_exclude_workload_identity_credential=exclude_workload_identity_credential,
|
157
|
-
**kwargs
|
177
|
+
**kwargs,
|
158
178
|
)
|
159
179
|
)
|
160
180
|
if not exclude_shared_token_cache_credential and SharedTokenCacheCredential.supported():
|
@@ -21,8 +21,8 @@ _LOGGER = logging.getLogger(__name__)
|
|
21
21
|
class EnvironmentCredential(AsyncContextManager):
|
22
22
|
"""A credential configured by environment variables.
|
23
23
|
|
24
|
-
This credential is capable of authenticating as a service principal using a client secret or a certificate
|
25
|
-
|
24
|
+
This credential is capable of authenticating as a service principal using a client secret or a certificate.
|
25
|
+
Configuration is attempted in this order, using these environment variables:
|
26
26
|
|
27
27
|
Service principal with secret:
|
28
28
|
- **AZURE_TENANT_ID**: ID of the service principal's tenant. Also called its 'directory' ID.
|
@@ -4,9 +4,12 @@
|
|
4
4
|
# ------------------------------------
|
5
5
|
from typing import Optional, Any
|
6
6
|
|
7
|
+
from azure.core.credentials import AccessToken, AccessTokenInfo, TokenRequestOptions
|
8
|
+
from azure.core.exceptions import ClientAuthenticationError
|
9
|
+
|
7
10
|
from .._internal.managed_identity_base import AsyncManagedIdentityBase
|
8
11
|
from .._internal.managed_identity_client import AsyncManagedIdentityClient
|
9
|
-
from ..._credentials.service_fabric import _get_client_args
|
12
|
+
from ..._credentials.service_fabric import _get_client_args, SERVICE_FABRIC_ERROR_MESSAGE
|
10
13
|
|
11
14
|
|
12
15
|
class ServiceFabricCredential(AsyncManagedIdentityBase):
|
@@ -18,3 +21,16 @@ class ServiceFabricCredential(AsyncManagedIdentityBase):
|
|
18
21
|
|
19
22
|
def get_unavailable_message(self, desc: str = "") -> str:
|
20
23
|
return f"Service Fabric managed identity configuration not found in environment. {desc}"
|
24
|
+
|
25
|
+
async def get_token(
|
26
|
+
self, *scopes: str, claims: Optional[str] = None, tenant_id: Optional[str] = None, **kwargs: Any
|
27
|
+
) -> AccessToken:
|
28
|
+
if self._client and self._client._identity_config: # pylint:disable=protected-access
|
29
|
+
raise ClientAuthenticationError(message=SERVICE_FABRIC_ERROR_MESSAGE)
|
30
|
+
return await super().get_token(*scopes, claims=claims, tenant_id=tenant_id, **kwargs)
|
31
|
+
|
32
|
+
async def get_token_info(self, *scopes: str, options: Optional[TokenRequestOptions] = None) -> AccessTokenInfo:
|
33
|
+
|
34
|
+
if self._client and self._client._identity_config: # pylint:disable=protected-access
|
35
|
+
raise ClientAuthenticationError(message=SERVICE_FABRIC_ERROR_MESSAGE)
|
36
|
+
return await super().get_token_info(*scopes, options=options)
|
@@ -18,10 +18,10 @@ from ..._internal import within_dac
|
|
18
18
|
class VisualStudioCodeCredential(_VSCodeCredentialBase, AsyncContextManager, GetTokenMixin):
|
19
19
|
"""Authenticates as the Azure user signed in to Visual Studio Code via the 'Azure Account' extension.
|
20
20
|
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
21
|
+
**Deprecated**: This credential is deprecated because the Azure Account extension for Visual Studio Code, which
|
22
|
+
this credential relies on, has been deprecated. See the Azure Account extension deprecation notice here:
|
23
|
+
https://github.com/microsoft/vscode-azure-account/issues/964. Consider using other developer credentials such as
|
24
|
+
AzureCliCredential, AzureDeveloperCliCredential, or AzurePowerShellCredential.
|
25
25
|
|
26
26
|
:keyword str authority: Authority of a Microsoft Entra endpoint, for example "login.microsoftonline.com".
|
27
27
|
This argument is required for a custom cloud and usually unnecessary otherwise. Defaults to the authority
|
@@ -46,7 +46,7 @@ if sys.version_info >= (3, 11):
|
|
46
46
|
def contents() -> str:
|
47
47
|
return files("certifi").joinpath("cacert.pem").read_text(encoding="ascii")
|
48
48
|
|
49
|
-
|
49
|
+
else:
|
50
50
|
|
51
51
|
from importlib.resources import path as get_path, read_text
|
52
52
|
|
@@ -81,34 +81,3 @@ elif sys.version_info >= (3, 7):
|
|
81
81
|
|
82
82
|
def contents() -> str:
|
83
83
|
return read_text("certifi", "cacert.pem", encoding="ascii")
|
84
|
-
|
85
|
-
else:
|
86
|
-
import os
|
87
|
-
import types
|
88
|
-
from typing import Union
|
89
|
-
|
90
|
-
Package = Union[types.ModuleType, str]
|
91
|
-
Resource = Union[str, "os.PathLike"]
|
92
|
-
|
93
|
-
# This fallback will work for Python versions prior to 3.7 that lack the
|
94
|
-
# importlib.resources module but relies on the existing `where` function
|
95
|
-
# so won't address issues with environments like PyOxidizer that don't set
|
96
|
-
# __file__ on modules.
|
97
|
-
def read_text(
|
98
|
-
package: Package,
|
99
|
-
resource: Resource,
|
100
|
-
encoding: str = 'utf-8',
|
101
|
-
errors: str = 'strict'
|
102
|
-
) -> str:
|
103
|
-
with open(where(), encoding=encoding) as data:
|
104
|
-
return data.read()
|
105
|
-
|
106
|
-
# If we don't have importlib.resources, then we will just do the old logic
|
107
|
-
# of assuming we're on the filesystem and munge the path directly.
|
108
|
-
def where() -> str:
|
109
|
-
f = os.path.dirname(__file__)
|
110
|
-
|
111
|
-
return os.path.join(f, "cacert.pem")
|
112
|
-
|
113
|
-
def contents() -> str:
|
114
|
-
return read_text("certifi", "cacert.pem", encoding="ascii")
|
@@ -2,6 +2,7 @@ from __future__ import annotations
|
|
2
2
|
|
3
3
|
import argparse
|
4
4
|
import sys
|
5
|
+
import typing
|
5
6
|
from json import dumps
|
6
7
|
from os.path import abspath, basename, dirname, join, realpath
|
7
8
|
from platform import python_version
|
@@ -43,7 +44,66 @@ def query_yes_no(question: str, default: str = "yes") -> bool:
|
|
43
44
|
elif choice in valid:
|
44
45
|
return valid[choice]
|
45
46
|
else:
|
46
|
-
sys.stdout.write("Please respond with 'yes' or 'no'
|
47
|
+
sys.stdout.write("Please respond with 'yes' or 'no' (or 'y' or 'n').\n")
|
48
|
+
|
49
|
+
|
50
|
+
class FileType:
|
51
|
+
"""Factory for creating file object types
|
52
|
+
|
53
|
+
Instances of FileType are typically passed as type= arguments to the
|
54
|
+
ArgumentParser add_argument() method.
|
55
|
+
|
56
|
+
Keyword Arguments:
|
57
|
+
- mode -- A string indicating how the file is to be opened. Accepts the
|
58
|
+
same values as the builtin open() function.
|
59
|
+
- bufsize -- The file's desired buffer size. Accepts the same values as
|
60
|
+
the builtin open() function.
|
61
|
+
- encoding -- The file's encoding. Accepts the same values as the
|
62
|
+
builtin open() function.
|
63
|
+
- errors -- A string indicating how encoding and decoding errors are to
|
64
|
+
be handled. Accepts the same value as the builtin open() function.
|
65
|
+
|
66
|
+
Backported from CPython 3.12
|
67
|
+
"""
|
68
|
+
|
69
|
+
def __init__(
|
70
|
+
self,
|
71
|
+
mode: str = "r",
|
72
|
+
bufsize: int = -1,
|
73
|
+
encoding: str | None = None,
|
74
|
+
errors: str | None = None,
|
75
|
+
):
|
76
|
+
self._mode = mode
|
77
|
+
self._bufsize = bufsize
|
78
|
+
self._encoding = encoding
|
79
|
+
self._errors = errors
|
80
|
+
|
81
|
+
def __call__(self, string: str) -> typing.IO: # type: ignore[type-arg]
|
82
|
+
# the special argument "-" means sys.std{in,out}
|
83
|
+
if string == "-":
|
84
|
+
if "r" in self._mode:
|
85
|
+
return sys.stdin.buffer if "b" in self._mode else sys.stdin
|
86
|
+
elif any(c in self._mode for c in "wax"):
|
87
|
+
return sys.stdout.buffer if "b" in self._mode else sys.stdout
|
88
|
+
else:
|
89
|
+
msg = f'argument "-" with mode {self._mode}'
|
90
|
+
raise ValueError(msg)
|
91
|
+
|
92
|
+
# all other arguments are used as file names
|
93
|
+
try:
|
94
|
+
return open(string, self._mode, self._bufsize, self._encoding, self._errors)
|
95
|
+
except OSError as e:
|
96
|
+
message = f"can't open '{string}': {e}"
|
97
|
+
raise argparse.ArgumentTypeError(message)
|
98
|
+
|
99
|
+
def __repr__(self) -> str:
|
100
|
+
args = self._mode, self._bufsize
|
101
|
+
kwargs = [("encoding", self._encoding), ("errors", self._errors)]
|
102
|
+
args_str = ", ".join(
|
103
|
+
[repr(arg) for arg in args if arg != -1]
|
104
|
+
+ [f"{kw}={arg!r}" for kw, arg in kwargs if arg is not None]
|
105
|
+
)
|
106
|
+
return f"{type(self).__name__}({args_str})"
|
47
107
|
|
48
108
|
|
49
109
|
def cli_detect(argv: list[str] | None = None) -> int:
|
@@ -59,7 +119,7 @@ def cli_detect(argv: list[str] | None = None) -> int:
|
|
59
119
|
)
|
60
120
|
|
61
121
|
parser.add_argument(
|
62
|
-
"files", type=
|
122
|
+
"files", type=FileType("rb"), nargs="+", help="File(s) to be analysed"
|
63
123
|
)
|
64
124
|
parser.add_argument(
|
65
125
|
"-v",
|
@@ -549,6 +549,23 @@ COMMON_SAFE_ASCII_CHARACTERS: set[str] = {
|
|
549
549
|
")",
|
550
550
|
}
|
551
551
|
|
552
|
+
# Sample character sets — replace with full lists if needed
|
553
|
+
COMMON_CHINESE_CHARACTERS = "的一是在不了有和人这中大为上个国我以要他时来用们生到作地于出就分对成会可主发年动同工也能下过子说产种面而方后多定行学法所民得经十三之进着等部度家电力里如水化高自二理起小物现实加量都两体制机当使点从业本去把性好应开它合还因由其些然前外天政四日那社义事平形相全表间样与关各重新线内数正心反你明看原又么利比或但质气第向道命此变条只没结解问意建月公无系军很情者最立代想已通并提直题党程展五果料象员革位入常文总次品式活设及管特件长求老头基资边流路级少图山统接知较将组见计别她手角期根论运农指几九区强放决西被干做必战先回则任取据处队南给色光门即保治北造百规热领七海口东导器压志世金增争济阶油思术极交受联什认六共权收证改清己美再采转更单风切打白教速花带安场身车例真务具万每目至达走积示议声报斗完类八离华名确才科张信马节话米整空元况今集温传土许步群广石记需段研界拉林律叫且究观越织装影算低持音众书布复容儿须际商非验连断深难近矿千周委素技备半办青省列习响约支般史感劳便团往酸历市克何除消构府太准精值号率族维划选标写存候毛亲快效斯院查江型眼王按格养易置派层片始却专状育厂京识适属圆包火住调满县局照参红细引听该铁价严龙飞"
|
554
|
+
|
555
|
+
COMMON_JAPANESE_CHARACTERS = "日一国年大十二本中長出三時行見月分後前生五間上東四今金九入学高円子外八六下来気小七山話女北午百書先名川千水半男西電校語土木聞食車何南万毎白天母火右読友左休父雨"
|
556
|
+
|
557
|
+
COMMON_KOREAN_CHARACTERS = "一二三四五六七八九十百千萬上下左右中人女子大小山川日月火水木金土父母天地國名年時文校學生"
|
558
|
+
|
559
|
+
# Combine all into a set
|
560
|
+
COMMON_CJK_CHARACTERS = set(
|
561
|
+
"".join(
|
562
|
+
[
|
563
|
+
COMMON_CHINESE_CHARACTERS,
|
564
|
+
COMMON_JAPANESE_CHARACTERS,
|
565
|
+
COMMON_KOREAN_CHARACTERS,
|
566
|
+
]
|
567
|
+
)
|
568
|
+
)
|
552
569
|
|
553
570
|
KO_NAMES: set[str] = {"johab", "cp949", "euc_kr"}
|
554
571
|
ZH_NAMES: set[str] = {"big5", "cp950", "big5hkscs", "hz"}
|
@@ -37,9 +37,7 @@ def detect(
|
|
37
37
|
|
38
38
|
if not isinstance(byte_str, (bytearray, bytes)):
|
39
39
|
raise TypeError( # pragma: nocover
|
40
|
-
"Expected object of type bytes or bytearray, got:
|
41
|
-
type(byte_str)
|
42
|
-
)
|
40
|
+
f"Expected object of type bytes or bytearray, got: {type(byte_str)}"
|
43
41
|
)
|
44
42
|
|
45
43
|
if isinstance(byte_str, bytearray):
|
@@ -26,6 +26,7 @@ from .utils import (
|
|
26
26
|
is_unprintable,
|
27
27
|
remove_accent,
|
28
28
|
unicode_range,
|
29
|
+
is_cjk_uncommon,
|
29
30
|
)
|
30
31
|
|
31
32
|
|
@@ -365,35 +366,39 @@ class SuperWeirdWordPlugin(MessDetectorPlugin):
|
|
365
366
|
return self._bad_character_count / self._character_count
|
366
367
|
|
367
368
|
|
368
|
-
class
|
369
|
+
class CjkUncommonPlugin(MessDetectorPlugin):
|
369
370
|
"""
|
370
|
-
|
371
|
-
can be easily detected. Searching for the overuse of '丅' and '丄'.
|
371
|
+
Detect messy CJK text that probably means nothing.
|
372
372
|
"""
|
373
373
|
|
374
374
|
def __init__(self) -> None:
|
375
|
-
self.
|
376
|
-
self.
|
375
|
+
self._character_count: int = 0
|
376
|
+
self._uncommon_count: int = 0
|
377
377
|
|
378
378
|
def eligible(self, character: str) -> bool:
|
379
|
-
return
|
379
|
+
return is_cjk(character)
|
380
380
|
|
381
381
|
def feed(self, character: str) -> None:
|
382
|
-
|
383
|
-
|
382
|
+
self._character_count += 1
|
383
|
+
|
384
|
+
if is_cjk_uncommon(character):
|
385
|
+
self._uncommon_count += 1
|
384
386
|
return
|
385
|
-
if is_cjk(character):
|
386
|
-
self._cjk_character_count += 1
|
387
387
|
|
388
388
|
def reset(self) -> None: # Abstract
|
389
|
-
self.
|
390
|
-
self.
|
389
|
+
self._character_count = 0
|
390
|
+
self._uncommon_count = 0
|
391
391
|
|
392
392
|
@property
|
393
393
|
def ratio(self) -> float:
|
394
|
-
if self.
|
394
|
+
if self._character_count < 8:
|
395
395
|
return 0.0
|
396
|
-
|
396
|
+
|
397
|
+
uncommon_form_usage: float = self._uncommon_count / self._character_count
|
398
|
+
|
399
|
+
# we can be pretty sure it's garbage when uncommon characters are widely
|
400
|
+
# used. otherwise it could just be traditional chinese for example.
|
401
|
+
return uncommon_form_usage / 10 if uncommon_form_usage > 0.5 else 0.0
|
397
402
|
|
398
403
|
|
399
404
|
class ArchaicUpperLowerPlugin(MessDetectorPlugin):
|
@@ -20,6 +20,7 @@ from .constant import (
|
|
20
20
|
UNICODE_RANGES_COMBINED,
|
21
21
|
UNICODE_SECONDARY_RANGE_KEYWORD,
|
22
22
|
UTF8_MAXIMAL_ALLOCATION,
|
23
|
+
COMMON_CJK_CHARACTERS,
|
23
24
|
)
|
24
25
|
|
25
26
|
|
@@ -200,6 +201,11 @@ def is_arabic_isolated_form(character: str) -> bool:
|
|
200
201
|
return "ARABIC" in character_name and "ISOLATED FORM" in character_name
|
201
202
|
|
202
203
|
|
204
|
+
@lru_cache(maxsize=UTF8_MAXIMAL_ALLOCATION)
|
205
|
+
def is_cjk_uncommon(character: str) -> bool:
|
206
|
+
return character not in COMMON_CJK_CHARACTERS
|
207
|
+
|
208
|
+
|
203
209
|
@lru_cache(maxsize=len(UNICODE_RANGES_COMBINED))
|
204
210
|
def is_unicode_range_secondary(range_name: str) -> bool:
|
205
211
|
return any(keyword in range_name for keyword in UNICODE_SECONDARY_RANGE_KEYWORD)
|
@@ -10,8 +10,8 @@ __all__ = [
|
|
10
10
|
"__version__",
|
11
11
|
]
|
12
12
|
|
13
|
-
__version__ = "
|
13
|
+
__version__ = "45.0.4"
|
14
14
|
|
15
15
|
|
16
16
|
__author__ = "The Python Cryptographic Authority and individual contributors"
|
17
|
-
__copyright__ = f"Copyright 2013-
|
17
|
+
__copyright__ = f"Copyright 2013-2025 {__author__}"
|
@@ -19,8 +19,8 @@ __all__ = [
|
|
19
19
|
if sys.version_info[:2] == (3, 7):
|
20
20
|
warnings.warn(
|
21
21
|
"Python 3.7 is no longer supported by the Python core team "
|
22
|
-
"and support for it is deprecated in cryptography.
|
23
|
-
"
|
22
|
+
"and support for it is deprecated in cryptography. The next release "
|
23
|
+
"of cryptography will remove support for Python 3.7.",
|
24
24
|
utils.CryptographyDeprecationWarning,
|
25
25
|
stacklevel=2,
|
26
26
|
)
|
@@ -9,6 +9,7 @@ import binascii
|
|
9
9
|
import os
|
10
10
|
import time
|
11
11
|
import typing
|
12
|
+
from collections.abc import Iterable
|
12
13
|
|
13
14
|
from cryptography import utils
|
14
15
|
from cryptography.exceptions import InvalidSignature
|
@@ -168,7 +169,7 @@ class Fernet:
|
|
168
169
|
|
169
170
|
|
170
171
|
class MultiFernet:
|
171
|
-
def __init__(self, fernets:
|
172
|
+
def __init__(self, fernets: Iterable[Fernet]):
|
172
173
|
fernets = list(fernets)
|
173
174
|
if not fernets:
|
174
175
|
raise ValueError(
|