Skip to content

Commit 8274514

Browse files
committed
Minor edits
1 parent c230cac commit 8274514

File tree

2 files changed

+30
-22
lines changed

2 files changed

+30
-22
lines changed

docs/oauth2-examples/index.md

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -702,20 +702,24 @@ make stop-perftest-consumer CONSUMER=consumer_with_roles
702702

703703
### Using variable expansion in scopes {#using-var-expansion}
704704

705-
There are times when it is convenient to define a scope which uses a variable
706-
in either the vhost part of the scope, or in the resource and/or in the routing
707-
key part. The variable name can be `vhost`, whose value matches the vhost you
708-
are accessing, or any single value claim in the token such as `user_name`.
705+
There are times when it is convenient to define a scope that uses a variable in either:
709706

710-
To demonstrate this feature, follow these steps:
707+
* The vhost part of the scope
708+
* The resource and/or in the routing key part
711709

712-
1. Start Keycloak Oauth provider and RabbitMQ following the steps explained in [Keycloak](./oauth2-examples-keycloak)
713-
2. Keycloak is already configured to issue tokens with the scope `rabbitmq.configure:*/q-{user_name}`
714-
3. Log in with the username `rabbit_admin` to the management ui at http://localhost:15672
715-
4. Try to create a queue with the name `test`. It should fail with an authorization error
716-
5. Create a queue with the name `q-rabbit_admin`. It should allow you.
710+
The variable name can be `vhost`, whose value matches the vhost you are accessing, or any single
711+
value claim in the token, such as `user_name`.
717712

718-
There is no configuration required in RabbitMQ. But at least it requires RabbitMQ 4.1.1.
713+
To demonstrate this feature:
714+
715+
1. Start Keycloak Oauth provider and RabbitMQ by following the steps in
716+
[Keycloak](./oauth2-examples-keycloak). Keycloak is already configured to issue tokens with the
717+
scope `rabbitmq.configure:*/q-{user_name}`.
718+
2. Log in to the management UI at `http://localhost:15672` with the user name `rabbit_admin`.
719+
3. Try to create a queue with the name `test`. Expect the effort to fail with an authorization error.
720+
4. Create a queue with the name `q-rabbit_admin`. Expect to be allowed to do this.
721+
722+
There is no configuration required in RabbitMQ, but RabbitMQ 4.1.1 is required.
719723

720724
### Preferred username claims {#preferred-username-claims}
721725

versioned_docs/version-4.1/oauth2-examples/index.md

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -702,20 +702,24 @@ make stop-perftest-consumer CONSUMER=consumer_with_roles
702702

703703
### Using variable expansion in scopes {#using-var-expansion}
704704

705-
There are times when it is convenient to define a scope which uses a variable
706-
in either the vhost part of the scope, or in the resource and/or in the routing
707-
key part. The variable name can be `vhost`, whose value matches the vhost you
708-
are accessing, or any single value claim in the token such as `user_name`.
705+
There are times when it is convenient to define a scope that uses a variable in either:
709706

710-
To demonstrate this feature, follow these steps:
707+
* The vhost part of the scope
708+
* The resource and/or in the routing key part
711709

712-
1. Start Keycloak Oauth provider and RabbitMQ following the steps explained in [Keycloak](./oauth2-examples-keycloak)
713-
2. Keycloak is already configured to issue tokens with the scope `rabbitmq.configure:*/q-{user_name}`
714-
3. Log in with the username `rabbit_admin` to the management ui at http://localhost:15672
715-
4. Try to create a queue with the name `test`. It should fail with an authorization error
716-
5. Create a queue with the name `q-rabbit_admin`. It should allow you.
710+
The variable name can be `vhost`, whose value matches the vhost you are accessing, or any single
711+
value claim in the token, such as `user_name`.
717712

718-
There is no configuration required in RabbitMQ. But at least it requires RabbitMQ 4.1.1.
713+
To demonstrate this feature:
714+
715+
1. Start Keycloak Oauth provider and RabbitMQ by following the steps in
716+
[Keycloak](./oauth2-examples-keycloak). Keycloak is already configured to issue tokens with the
717+
scope `rabbitmq.configure:*/q-{user_name}`.
718+
2. Log in to the management UI at `http://localhost:15672` with the user name `rabbit_admin`.
719+
3. Try to create a queue with the name `test`. Expect the effort to fail with an authorization error.
720+
4. Create a queue with the name `q-rabbit_admin`. Expect to be allowed to do this.
721+
722+
There is no configuration required in RabbitMQ, but RabbitMQ 4.1.1 is required.
719723

720724
### Preferred username claims {#preferred-username-claims}
721725

0 commit comments

Comments
 (0)