Skip to main content

aiohttp-ntlm

Python 3.11+ License: MIT

NTLM authentication middleware for aiohttp (client support middleware since v3.12.0).

Installation

Using pip:

pip install aiohttp-ntlm

Usage Example

import asyncio
import aiohttp
from aiohttp_ntlm import HttpNtlmAuthMiddleware

async def test_ntlm_auth_middleware() -> None:
    request_url: str = "<your_request_url>" 
    user_name: str = "<your_user_name>"
    password: str = "<your_password>"

    async with aiohttp.ClientSession() as session:
        try:
            async with session.get(
                request_url, 
                headers={}, 
                middlewares=[HttpNtlmAuthMiddleware(user_name, password)]
            ) as response:
                if response.status == 200:
                    print("success:", await response.text())
        except Exception as e:
            raise Exception("error: " + str(e)) from e

if __name__ == "__main__":
    asyncio.run(test_ntlm_auth_middleware())

Implementation Notes

This middleware is inspired by requests_ntlm and implemented for aiohttp.

Metadata

Release files for aiohttp-ntlm 0.1.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for aiohttp-ntlm 0.1.4
File Size Uploaded Provenance Actions
aiohttp_ntlm-0.1.4.tar.gz 2.2 kB With provenance Details for aiohttp_ntlm-0.1.4.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for aiohttp-ntlm 0.1.4
File Interpreter ABI Platform Actions
aiohttp_ntlm-0.1.4-py3-none-any.whl Python 3 none any Details for aiohttp_ntlm-0.1.4-py3-none-any.whl

Total release size: 4.7 kB

Release files / aiohttp_ntlm-0.1.4.tar.gz

Download URL aiohttp_ntlm-0.1.4.tar.gz
Size 2.2 kB
Tags Source
SHA-256 checksum
How to use checksums
b286374c3f878f54a3c3cb923c7708c263d290be75f6df1cde802410e34c8695
BLAKE2b-256 checksum
How to use checksums
1fdb86548abe3c2a1b302307eaf9f95d05679cb97f44a68ecbd7cca7eff884ac
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 2, 2025.

Transparency log

Release files / aiohttp_ntlm-0.1.4-py3-none-any.whl

Download URL aiohttp_ntlm-0.1.4-py3-none-any.whl
Size 2.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
040ff493878c33f5559e9db2551d80761a620b86f49bccea3ea805ed08f21831
BLAKE2b-256 checksum
How to use checksums
c1a40421b8118e5e9431ef69979fadaf548c96e90758fd655c7f74434a1bbbda
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 2, 2025.

Transparency log

Security for aiohttp-ntlm 0.1.4

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for aiohttp_ntlm-0.1.4.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 2, 2025.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page