Skip to main content

Macrostrat authentication system

This module contains tools to manipulate Macrostrat's user authentication system. It is divided into two submodules:

  • macrostrat.auth_system.legacy: A JWT-based authentication system relying on local storage of hashed passwords. This system was created as part of Sparrow and is being phased out in favor of a more modern system based on ORCID.

  • macrostrat.auth_system.core: An ORCID-based user authentication system. This system will become the primary authentication system for Macrostrat, but it is still in development.

  • macrostrat.auth_system.session: ORCID sign-in for any FastAPI service, extracted from Macrostrat's API v3. create_auth_router(settings, store) provides the login, callback, refresh, logout and me routes; the application supplies a UserStore that maps an ORCID iD to its own account and Postgres role. SessionReader is the matching request dependency. The access token is also a valid PostgREST JWT. First used by Mapboard.

We plan to gradually converge the functionality of both versions while phasing out the legacy system.

The system has tests that can be run with poetry run pytest auth-system (currently, only the legacy system is covered).

Key planned functionality

  • Allow many Macrostrat-hosted services to easily integrate with Macrostrat's login and token flow
  • Allow APIs to easily validate user credentials and tokens with minimum overhead
  • Allow access to be checked in multiple ways:
    • Cookies and headers
    • Limited-time JWT tokens and long-duration, cancelable API tokens
    • Verify against Macrostrat "user group" or application-specific criteria ( e.g., a list of authorized ORCID IDs)

Metadata

Release files for macrostrat.auth_system 1.2.0

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

Source distribution (sdist)

Source distribution for macrostrat.auth_system 1.2.0
File Size Uploaded Provenance Actions
macrostrat_auth_system-1.2.0.tar.gz 16.2 kB Without provenance Details for macrostrat_auth_system-1.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for macrostrat.auth_system 1.2.0
File Interpreter ABI Platform Actions
macrostrat_auth_system-1.2.0-py3-none-any.whl Python 3 none any Details for macrostrat_auth_system-1.2.0-py3-none-any.whl

Total release size: 38.8 kB

Release files / macrostrat_auth_system-1.2.0.tar.gz

Download URL macrostrat_auth_system-1.2.0.tar.gz
Size 16.2 kB
Tags Source
SHA-256 checksum
How to use checksums
a2b363d09cb3053fee3e9a892b1414e50a094ed6ac104b44f949ed54120c572f
BLAKE2b-256 checksum
How to use checksums
86436683dad7c131c6345796097a1c505d728e9575dde3970869cd265de25860
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.8 {"installer":{"name":"uv","version":"0.13.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / macrostrat_auth_system-1.2.0-py3-none-any.whl

Download URL macrostrat_auth_system-1.2.0-py3-none-any.whl
Size 22.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
062ae1a9a39d783b109e91ebe2215557eefbf604bf0a4db0dc84a49eb0217b45
BLAKE2b-256 checksum
How to use checksums
5b373fc20aa2950549475490c5c47514bda1ccd72002afe4d0c3e663780ec411
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.8 {"installer":{"name":"uv","version":"0.13.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for macrostrat.auth_system 1.2.0

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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