Skip to main content

This is a Pyramid authenitcation plugin for Hawk Access Authentication:

https://npmjs.org/package/hawk

To access resources using Hawk Access Authentication, the client must have obtained a set of Hawk credentials including an id and secret key. They use these credentials to make signed requests to the server.

When accessing a protected resource, the server will generate a 401 challenge response with the scheme “Hawk” as follows:

> GET /protected_resource HTTP/1.1
> Host: example.com

< HTTP/1.1 401 Unauthorized
< WWW-Authenticate: Hawk

The client will use their Hawk credentials to build a request signature and include it in the Authorization header like so:

> GET /protected_resource HTTP/1.1
> Host: example.com
> Authorization: Hawk id="h480djs93hd8",
>                     ts="1336363200",
>                     nonce="dj83hs9s",
>                     mac="bhCQXTVyfj5cmA9uKkPFx1zeOXM="

< HTTP/1.1 200 OK
< Content-Type: text/plain
<
< For your eyes only:  secret data!

This plugin uses the tokenlib library for verifying Hawk credentials:

https://github.com/mozilla-services/tokenlib

If this library does not meet your needs, you can provide a custom callback function to decode the Hawk id token.

2.0.0 - 2018-01-10

  • Update use of tokenlib API for v0.3 and later.

  • Py27, Py35 compatible; thanks @return42!

v0.1.0 - 2014-13-01

  • Initial release, based on pyramid_macauth codebase.

Release files for pyramid_hawkauth 2.0.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 pyramid_hawkauth 2.0.0
File Size Uploaded
pyramid_hawkauth-2.0.0.tar.gz 10.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pyramid_hawkauth 2.0.0
File Interpreter ABI Platform
pyramid_hawkauth-2.0.0-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 32.4 kB

Release files / pyramid_hawkauth-2.0.0.tar.gz

Download URL pyramid_hawkauth-2.0.0.tar.gz
Size 10.8 kB
Tags Source
SHA-256 checksum
How to use checksums
d1467c3155ba96ebfd194d851f8000749239e3a57ee92e75e7f8ef7e5193b424
BLAKE2b-256 checksum
How to use checksums
ac4fc393f0dc1f8e6c41f7588cde7bcceffcb505d1e09b39545e59db92b45504
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / pyramid_hawkauth-2.0.0-py2.py3-none-any.whl

Download URL pyramid_hawkauth-2.0.0-py2.py3-none-any.whl
Size 21.6 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
4261029ce0246477423bfcbfad31ff84b46d2ada2d1e6cc4eed98be77e9390aa
BLAKE2b-256 checksum
How to use checksums
ac988a786fa8d2e1bdd1db4b11abd7e1b0298a7be2aa34c4a50e86cc26a06123
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

2.0.0 This release

2 release files

0.1.0

1 release file

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