{"id":15683922,"url":"https://github.com/scrogson/no-way-jose","last_synced_at":"2026-02-05T23:06:36.213Z","repository":{"id":38330789,"uuid":"214701598","full_name":"scrogson/no-way-jose","owner":"scrogson","description":"Rust NIF for fast JWT signing","archived":false,"fork":false,"pushed_at":"2025-12-31T16:05:00.000Z","size":175,"stargazers_count":10,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-01-04T06:32:51.176Z","etag":null,"topics":["elixir","jwt","nif","rs512","rustler"],"latest_commit_sha":null,"homepage":"","language":"Elixir","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/scrogson.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2019-10-12T19:13:20.000Z","updated_at":"2025-12-31T16:05:03.000Z","dependencies_parsed_at":"2024-01-05T17:47:13.801Z","dependency_job_id":null,"html_url":"https://github.com/scrogson/no-way-jose","commit_stats":{"total_commits":30,"total_committers":1,"mean_commits":30.0,"dds":0.0,"last_synced_commit":"6bc2878eef8378f603e7c2ad629e321fad767d16"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/scrogson/no-way-jose","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scrogson%2Fno-way-jose","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scrogson%2Fno-way-jose/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scrogson%2Fno-way-jose/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scrogson%2Fno-way-jose/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/scrogson","download_url":"https://codeload.github.com/scrogson/no-way-jose/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scrogson%2Fno-way-jose/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29137758,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-05T23:02:30.544Z","status":"ssl_error","status_checked_at":"2026-02-05T23:02:24.945Z","response_time":65,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["elixir","jwt","nif","rs512","rustler"],"created_at":"2024-10-03T17:09:14.330Z","updated_at":"2026-02-05T23:06:36.208Z","avatar_url":"https://github.com/scrogson.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NoWayJose\n\n\u003e Rust NIF for JWT signing and verification\n\n![](https://github.com/scrogson/no-way-jose/workflows/CI/badge.svg)\n\n## Features\n\n- Sign and verify JWTs with RSA (RS256, RS384, RS512, PS256, PS384, PS512) and ECDSA (ES256, ES384)\n- Configurable claims validation (exp, nbf, iss, aud, sub)\n- JWKS fetcher with auto-refresh\n- Key store for managing multiple keys\n- Export keys as JWKS for `.well-known/jwks.json`\n\n## Installation\n\n```elixir\ndef deps do\n  [\n    {:no_way_jose, \"~\u003e 1.0\"}\n  ]\nend\n```\n\n## Quick Start\n\n```elixir\n# Generate a key\n{:ok, key} = NoWayJose.generate(:rs256, kid: \"my-key\")\n\n# Sign\nclaims = %{\"sub\" =\u003e \"user-123\", \"exp\" =\u003e System.system_time(:second) + 3600}\n{:ok, token} = NoWayJose.sign(key, claims)\n\n# Verify\n{:ok, claims} = NoWayJose.verify(key, token)\n```\n\n## Key Management\n\n### Generate Keys\n\n```elixir\n# RSA (2048-bit default)\n{:ok, key} = NoWayJose.generate(:rs256)\n{:ok, key} = NoWayJose.generate(:rs256, bits: 4096, kid: \"rsa-key\")\n\n# ECDSA\n{:ok, key} = NoWayJose.generate(:es256, kid: \"ec-key\")  # P-256\n{:ok, key} = NoWayJose.generate(:es384)                  # P-384\n```\n\n### Import Keys\n\n```elixir\n# From PEM\n{:ok, key} = NoWayJose.import(pem_data, :pem, alg: :rs256, kid: \"imported\")\n\n# From JWK (verification only)\n{:ok, key} = NoWayJose.import(jwk_json, :jwk)\n\n# From JWKS\n{:ok, keys} = NoWayJose.import(jwks_json, :jwks)\n```\n\n### Export Keys\n\n```elixir\n# Export public key as JWK\n{:ok, jwk_json} = NoWayJose.export(key, :jwk)\n```\n\n## Verification Options\n\n| Option | Description |\n|--------|-------------|\n| `validate_exp` | Validate expiration (default: true) |\n| `validate_nbf` | Validate not-before (default: true) |\n| `leeway` | Clock skew tolerance in seconds |\n| `iss` | Required issuer(s) |\n| `aud` | Required audience(s) |\n| `sub` | Required subject |\n| `required_claims` | List of required claim names |\n\n```elixir\n{:ok, claims} = NoWayJose.verify(key, token,\n  aud: \"my-app\",\n  iss: \"https://auth.example.com\",\n  leeway: 60\n)\n```\n\n## JWKS Fetcher\n\nAutomatically fetch and refresh keys from external identity providers:\n\n```elixir\n# Start a fetcher (keys refresh every 15 minutes)\n:ok = NoWayJose.start_jwks_fetcher(\"auth0\",\n  \"https://example.auth0.com/.well-known/jwks.json\"\n)\n\n# Verify tokens using stored keys\n{:ok, claims} = NoWayJose.verify_with_stored(token, \"auth0\", aud: \"my-app\")\n\n# Stop when done\n:ok = NoWayJose.stop_jwks_fetcher(\"auth0\")\n```\n\n## Serving JWKS\n\nExport your keys for clients:\n\n```elixir\n# Store keys\nNoWayJose.put_key(\"my-app\", key)\n\n# Serve at /.well-known/jwks.json\nget \"/.well-known/jwks.json\" do\n  send_resp(conn, 200, NoWayJose.export_jwks(\"my-app\"))\nend\n```\n\n## Documentation\n\nFull documentation at [https://hexdocs.pm/no_way_jose](https://hexdocs.pm/no_way_jose).\n\n## Etymology\n\nA rhyming play on words to indicate that this library does not depend on [JOSE](https://github.com/potatosalad/erlang-jose).\n\n## License\n\nApache 2.0\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscrogson%2Fno-way-jose","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fscrogson%2Fno-way-jose","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscrogson%2Fno-way-jose/lists"}