Commit Graph

42 Commits

Author SHA1 Message Date
Michael Klishin c15f19fe83 OAuth 2: CLI is a build time dependency, not a runtime one 2024-10-08 07:11:43 -04:00
Michael Klishin e7f82a53ba OAuth 2: add a missing dependency on rabbitmq_cli 2024-10-08 07:09:08 -04:00
David Ansari 0397035669 Add test for AMQP 1.0 clients using OAuth token 2024-07-31 12:05:22 +02:00
David Ansari 7fb78338c6 Disconnect MQTT client when its credential expires
Fixes https://github.com/rabbitmq/rabbitmq-server/discussions/11854
Fixes https://github.com/rabbitmq/rabbitmq-server/issues/11862

This commit uses the same approach as implemented for AMQP 1.0 and
Streams: When a token expires, RabbitMQ will close the connection.
2024-07-30 19:55:46 +02:00
Michal Kuratczyk 27f735f49e
Use emqx/emqtt instead of a fork (#11479)
* Use emqx/emqtt instead of a fork
* Specify SNI in test connections (otherwise OTP26 secure TLS defaults make some tests fail)
2024-06-19 14:03:30 +02:00
Loïc Hoguin bd06d8c90d
Fix duplicate dep in rabbitmq_auth_backend_oauth2 2024-06-10 09:42:33 +02:00
Michael Klishin ef3888220a
jose dependency belongs to rabbitmq-components.mk
and not oauth2_client or the OAuth 2 plugin.

Pair: Rin Kuryloski
2024-05-06 12:17:19 -04:00
Rin Kuryloski 6a9d668def Set PLT_APPS in a number of plugins where it was missing 2024-04-29 14:54:28 +02:00
Rin Kuryloski 070265d00c Add oauth2_client to rabbitmq_auth_backend_oauth2 make deps 2024-03-26 14:50:58 +01:00
Marcial Rosales d827b72ce1 Create Oauth2 client 2024-02-10 20:12:04 +01:00
David Ansari 2270a30af0 Point emqtt to rabbitmq/emqtt:master
emqtt repos:
emqx/emqtt PR #196 is based on rabbitmq:otp-26-compatibility
emqx/emqtt PR #198 is based on ansd:master
rabbitmq/master contains both of these 2 PRs cherry-picked.

rabbitmq-server repos:
main branch points emqtt to rabbitmq:otp-26-compatibility
mqtt5 branch points emqtt to rabbitmq:master

Therefore, the current mqtt5 branch is OTP 26 compatible and can support
multiple subscription identifiers.
2023-06-21 17:14:08 +01:00
Rin Kuryloski eb94a58bc9 Add a workflow to compare the bazel/erlang.mk output
To catch any drift between the builds
2023-05-15 13:54:14 +02:00
Michal Kuratczyk 858ed1bff6
Switch to an emqtt fork/branch for OTP26
This change should be reverted once emqx/emqtt is OTP26 compatible.
Our fork/branch isn't either at this point, but at least partially
works. Let's use this branch for now to uncover server-side OTP26
incompatibilities (and continue working on OTP26 support for emqtt of
course).
2023-04-26 11:06:23 +02:00
David Ansari bf2a97a20a Bump emqx/emqtt to 1.8.2 2023-02-21 17:25:19 +01:00
David Ansari 2d0826c335 Add OAuth 2.0 MQTT system test
Add a test that rabbitmq_auth_backend_oauth2 works with MQTT.

See https://github.com/rabbitmq/rabbitmq-oauth2-tutorial#mqtt-protocol
2023-02-03 14:08:51 +00:00
Michael Klishin a9b72877f5 Bump deps: michaelklishin/erlang-jose and Thoas 2022-08-29 15:28:37 +04:00
Loïc Hoguin dc70cbf281
Update Erlang.mk and switch to new xref code 2022-05-31 13:51:12 +02:00
Michael Klishin 604fbfac3a
Depend on erlang-jose ref with fix for potatosalad/erlang-jose#113 2021-06-10 15:49:39 +03:00
Philip Kuryloski 98e71c45d8 Perform xref checks on many tier-1 plugins 2021-05-21 12:03:22 +02:00
Philip Kuryloski a63f169fcb Remove duplicate rabbitmq-components.mk and erlang.mk files
Also adjust the references in rabbitmq-components.mk to account for
post monorepo locations
2021-03-22 15:40:19 +01:00
Michael Klishin 4aa149b1b2
Bump JOSE dependency to 1.11 2021-02-01 21:30:51 +03:00
Michael Klishin 2b2a7471f5 Bump jose to 1.10.1
Primarily to reduce confusion about its licensing.
jose has been MIT-licensed since Dec 2018.
2020-03-09 11:04:25 +03:00
Arnaud Cogoluègnes 29b9b9152c Add early plugin dependency to compile command
Otherwise make xref fails.
2019-07-10 15:42:03 +02:00
Luke Bakken 30490995d9 Add missing rabbitmq_ct_client_helpers dependency needed by system_SUITE.erl 2018-07-20 15:29:15 -07:00
Luke Bakken 613e35be64 Miscellaneous build and doc fixes
* Update erlang.mk to resolve S3 bucket issue
* Update README to indicate that tokens need to be in the password field when clients log in
2018-07-19 15:44:37 -07:00
Michael Klishin f0178d7729 rabbitmq_auth_backend_uaa => rabbitmq_auth_backend_oauth2
"OAuth 2" is many things but it's still more descriptive, open-ended and easier
to find than "uaa" (too tool-specific) or "jwt" (too narrow, not known widely enough).

Per discussion with @hairyhum @kjnilsson.
2018-07-19 22:20:57 +03:00
Michael Klishin 5b002c5eab Fold uaa_jwt into this plugin
Per discussion with @hairyhum.
2018-07-19 19:22:47 +03:00
Michael Klishin 085c7e6c71 Sync rabbitmq-components.mk, drop Elixir build system bits 2018-07-03 02:15:43 +03:00
Daniil Fedotov dbdf2c0e13 Use master branch of uaa_jwt 2018-06-25 10:35:35 +01:00
Daniil Fedotov 032be9763b Use erlang version of uaa_jwt and jose 2018-06-21 17:07:35 +01:00
Jean-Sébastien Pédron a3be807c50 Makefile: Use GNU Make functions to set `$(MIX_ERL_LIBS)`
This gives a consistent result, as opposed to the shell-based variant
which produces a value which depends on the existing dependencies.

This change plus the new Makefile in `uaa_jwt` make sure that `uaa_jwt`
is found by Erlang, in particular in the testsuite.
2017-02-21 18:02:06 +01:00
Daniil Fedotov 5fdfda0846 Improve tests 2017-02-17 11:33:08 +00:00
kjnilsson b90da412e9 Add cowlib to DEPS 2017-02-17 09:33:30 +00:00
Jean-Sébastien Pédron e7222ed218 Makefile: amqp_client is not needed, remove it from DEPS 2017-01-31 17:15:35 +01:00
Jean-Sébastien Pédron b7a4e4daec Makefile: Add rabbit_common to BUILD_DEPS
It's required for the Erlang.mk plugins.
2017-01-31 12:23:33 +01:00
Jean-Sébastien Pédron 16c3866d7a Makefile: Do not depend twice on `rabbit`
[#136341089]
2017-01-31 11:21:59 +01:00
Daniil Fedotov 759d66263b Decode and verify UAA JWT tokens without connecting to UAA server
Fixes #3
Uses rabbitmq/uaa_jwt library to decode a token and verify signature.
Signing keys should be predefined in the uaa_jwt application environment
2017-01-27 11:32:14 +00:00
Daniil Fedotov dfc61ec18f Change scope to permission mapping 2016-12-20 13:13:18 +00:00
Daniil Fedotov b5c47a75f6 Resource ID filtering 2016-02-16 12:22:49 +00:00
Daniil Fedotov 99279bd10f Tests 2016-01-20 14:04:14 +00:00
Daniil Fedotov db72e7d9e3 Tesing on working UAA 2016-01-18 18:05:45 +00:00
Daniil Fedotov 47da90b652 Init. Make request to /check_token 2016-01-15 14:50:21 +00:00