Skip to main content

TURN Ephemeral Credentials - v1.0.1

Generate time limited, i.e. ephemeral, long term credentials to authenticate against a TURN server. The default duration for the validity of the credentials is set to one day as recommended in A REST API For Access To TURN Services. The same document describes how to generate the username and password here.

Stack

  • Python 3.8.10 on Ubuntu 20.04.2 LTS

Installation

From PyPI

(venv) $ pip install turn-ephemeral-credentials

From GitHub

(venv) $ pip install git+https://github.com/p4irin/turn_ephemeral_credentials.git

Usage

from turn_ephemeral_credentials import generate


# Generate a username and use the default ttl of one day
credentials = generate(shared_secret='A shared secret with a TURN server')

# Pass a username and use the default ttl
credentials = generate(username='username', shared_secret='A shared secret with a TURN server')

# Generate a username and use a ttl of half a day
credentials = generate(shared_secret='A shared secret with a TURN server', ttl=43200)

Reference

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

turn_ephemeral_credentials-1.0.1.tar.gz (4.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

turn_ephemeral_credentials-1.0.1-py3-none-any.whl (4.7 kB view details)

Uploaded Python 3

File details

Details for the file turn_ephemeral_credentials-1.0.1.tar.gz.

File metadata

File hashes

Hashes for turn_ephemeral_credentials-1.0.1.tar.gz
Algorithm Hash digest
SHA256 845ad661230da7b56ab8bcb1f26790b1ecab55079ad2c03fb025728e0b268abb
MD5 6a62b5fab9d11793d483b54ae258bfeb
BLAKE2b-256 d3ee38716611f798a485fb1be00ed57a33605355468d886cf2b6c0fab843a849

See more details on using hashes here.

File details

Details for the file turn_ephemeral_credentials-1.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for turn_ephemeral_credentials-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a404f4dcb40a00e14da3c0082dd16707415881b2f2f372457952cf9e79fe29fd
MD5 009982b5a5ad7d88fe48d4f949c4e2f9
BLAKE2b-256 ad9afdeaac0a27c783b74e554d8a3dfd07a69a4d9c19836167b6a46998b4c507

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page