{"id":15971472,"url":"https://github.com/dolph/keyless-fernet","last_synced_at":"2025-09-10T17:48:04.377Z","repository":{"id":27797392,"uuid":"31286482","full_name":"dolph/keyless-fernet","owner":"dolph","description":"A Python library to parse Fernet tokens as much as possible without using a key.","archived":false,"fork":false,"pushed_at":"2016-03-03T17:16:54.000Z","size":12,"stargazers_count":1,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-28T18:39:08.482Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dolph.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-02-24T23:01:23.000Z","updated_at":"2016-07-01T17:36:59.000Z","dependencies_parsed_at":"2022-08-29T08:40:37.328Z","dependency_job_id":null,"html_url":"https://github.com/dolph/keyless-fernet","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/dolph/keyless-fernet","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dolph%2Fkeyless-fernet","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dolph%2Fkeyless-fernet/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dolph%2Fkeyless-fernet/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dolph%2Fkeyless-fernet/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dolph","download_url":"https://codeload.github.com/dolph/keyless-fernet/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dolph%2Fkeyless-fernet/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272917651,"owners_count":25014950,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-30T02:00:09.474Z","response_time":77,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-07T20:21:42.066Z","updated_at":"2025-09-01T07:33:21.838Z","avatar_url":"https://github.com/dolph.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"==============\nkeyless-fernet\n==============\n\n.. image:: https://img.shields.io/pypi/v/keyless-fernet.svg\n   :target: https://pypi.python.org/pypi/keyless-fernet\n\nA Python library to parse `Fernet tokens \u003chttps://github.com/fernet\u003e`_ as much\nas possible without using a key. This is useful for doing limited,\nnon-cryptographic validation or introspection of Fernet tokens.\n\nIf you have the Fernet key and need to validate or decrypt a Fernet token\nfurther, I recommend using `pypi/cryptography\n\u003chttps://cryptography.io/en/latest/fernet/\u003e`_.\n\nUsage\n-----\n\n.. code:: python\n\n    \u003e\u003e\u003e token = 'gAAAAAAdwJ6wAAECAwQFBgcICQoLDA0ODy021cpGVWKZ_eEwCGM4BLLF_5CV9dOPmrhuVUPgJobwOz7JcbmrR64jVmpU4IwqDA=='\n    \u003e\u003e\u003e import keyless_fernet\n    \u003e\u003e\u003e t = keyless_fernet.Token(token)  # tokens are validated on init\n    \u003e\u003e\u003e t.validate(ttl=60)  # but you can also validate a token against any TTL\n    Traceback (most recent call last):\n      [...]\n    keyless_fernet.core.ExpiredToken: Token expired [...] seconds ago.\n    \u003e\u003e\u003e t.version  # retrieve the token's version, as an integer\n    128\n    \u003e\u003e\u003e t.timestamp  # retrieve the token's timestamp, as a datetime\n    datetime.datetime(1985, 10, 26, 8, 20)\n    \u003e\u003e\u003e t.iv  # and see the hex representations of the other attributes\n    '000102030405060708090a0b0c0d0e0f'\n    \u003e\u003e\u003e t.ciphertext\n    '2d36d5ca46556299fde13008633804b2'\n    \u003e\u003e\u003e t.hmac\n    'c5ff9095f5d38f9ab86e5543e02686f03b3ec971b9ab47ae23566a54e08c2a0c'\n\nTesting\n-------\n\n.. image:: https://travis-ci.org/dolph/keyless-fernet.svg?branch=master\n    :target: https://travis-ci.org/dolph/keyless-fernet\n\nNo external testing dependencies are required:\n\n.. code:: bash\n\n    $ python -m unittest discover\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdolph%2Fkeyless-fernet","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdolph%2Fkeyless-fernet","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdolph%2Fkeyless-fernet/lists"}