{"id":31710157,"url":"https://github.com/emqx/emqx-auth-jwt","last_synced_at":"2025-10-09T00:11:23.862Z","repository":{"id":49942803,"uuid":"96733737","full_name":"emqx/emqx-auth-jwt","owner":"emqx","description":"EMQX JWT Authentication Plugin","archived":false,"fork":false,"pushed_at":"2023-12-27T07:35:36.000Z","size":191,"stargazers_count":28,"open_issues_count":13,"forks_count":24,"subscribers_count":22,"default_branch":"master","last_synced_at":"2025-09-29T22:58:33.267Z","etag":null,"topics":["authentication","emqx","emqx-plugin","jwt","jwt-authentication"],"latest_commit_sha":null,"homepage":"https://www.emqx.com","language":"Erlang","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/emqx.png","metadata":{"files":{"readme":"README.md","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":"2017-07-10T03:52:02.000Z","updated_at":"2024-12-10T06:36:01.000Z","dependencies_parsed_at":"2022-08-30T11:00:17.646Z","dependency_job_id":null,"html_url":"https://github.com/emqx/emqx-auth-jwt","commit_stats":null,"previous_names":[],"tags_count":100,"template":false,"template_full_name":null,"purl":"pkg:github/emqx/emqx-auth-jwt","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emqx%2Femqx-auth-jwt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emqx%2Femqx-auth-jwt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emqx%2Femqx-auth-jwt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emqx%2Femqx-auth-jwt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/emqx","download_url":"https://codeload.github.com/emqx/emqx-auth-jwt/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emqx%2Femqx-auth-jwt/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279000745,"owners_count":26082879,"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-10-08T02:00:06.501Z","response_time":56,"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":["authentication","emqx","emqx-plugin","jwt","jwt-authentication"],"created_at":"2025-10-09T00:10:31.648Z","updated_at":"2025-10-09T00:11:23.857Z","avatar_url":"https://github.com/emqx.png","language":"Erlang","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# emqx-auth-jwt\n\nEMQX JWT Authentication Plugin\n\nBuild\n-----\n\n```\nmake \u0026\u0026 make tests\n```\n\nConfigure the Plugin\n--------------------\n\nFile: etc/plugins/emqx_auth_jwt.conf\n\n```\n## HMAC Hash Secret.\n##\n## Value: String\nauth.jwt.secret = emqxsecret\n\n## From where the JWT string can be got\n##\n## Value: username | password\n## Default: password\nauth.jwt.from = password\n\n## RSA or ECDSA public key file.\n##\n## Value: File\n## auth.jwt.pubkey = etc/certs/jwt_public_key.pem\n\n## Enable to verify claims fields\n##\n## Value: on | off\nauth.jwt.verify_claims = off\n\n## The checklist of claims to validate\n##\n## Value: String\n## auth.jwt.verify_claims.$name = expected\n##\n## Variables:\n##  - %u: username\n##  - %c: clientid\n# auth.jwt.verify_claims.username = %u\n```\n\nLoad the Plugin\n---------------\n\n```\n./bin/emqx_ctl plugins load emqx_auth_jwt\n```\n\nExample\n-------\n\n```\nmosquitto_pub -t 'pub' -m 'hello' -i test -u test -P eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJuYW1lIjoiYm9iIiwiYWdlIjoyOX0.bIV_ZQ8D5nQi0LT8AVkpM4Pd6wmlbpR9S8nOLJAsA8o\n```\n\nAlgorithms\n----------\n\nThe JWT spec supports several algorithms for cryptographic signing. This plugin currently supports:\n\n* HS256 - HMAC using SHA-256 hash algorithm\n* HS384 - HMAC using SHA-384 hash algorithm\n* HS512 - HMAC using SHA-512 hash algorithm\n\n* RS256 - RSA with the SHA-256 hash algorithm\n* RS384 - RSA with the SHA-384 hash algorithm\n* RS512 - RSA with the SHA-512 hash algorithm\n\n* ES256 - ECDSA using the P-256 curve\n* ES384 - ECDSA using the P-384 curve\n* ES512 - ECDSA using the P-512 curve\n\nLicense\n-------\n\nApache License Version 2.0\n\nAuthor\n------\n\nEMQX Team.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Femqx%2Femqx-auth-jwt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Femqx%2Femqx-auth-jwt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Femqx%2Femqx-auth-jwt/lists"}