适用于 RabbitMQ 的亚马逊 MQ 的 HTTP 身份验证和授权 - Amazon MQ
Amazon Web Services 文档中描述的 Amazon Web Services 服务或功能可能因区域而异。要查看适用于中国区域的差异,请参阅 中国的 Amazon Web Services 服务入门 (PDF)

本文属于机器翻译版本。若本译文内容与英语原文存在差异,则一律以英文原文为准。

适用于 RabbitMQ 的亚马逊 MQ 的 HTTP 身份验证和授权

适用于 RabbitMQ 的 Amazon MQ 支持使用外部 HTTP 服务器对代理用户进行身份验证和授权。有关其他支持的方法,请参阅适用于 RabbitMQ 代理的 Amazon MQ 身份验证和授权

注意

HTTP 身份验证插件仅适用于适用于 RabbitMQ 版本 4 及更高版本的亚马逊 MQ。

重要注意事项
  • HTTP 服务器需要可通过公共互联网访问。适用于 RabbitMQ 的 Amazon MQ 可以配置为使用双向 TLS 向 HTTP 服务器进行身份验证。

  • 适用于 RabbitMQ 的 Amazon MQ 强制使用需要访问本地文件系统的设置。 Amazon ARNs 有关更多详细信息,请参阅 RabbitMQ 配置中的 ARN 支持

  • 您必须包含 IAM 权限mq:UpdateBrokerAccessConfiguration,才能对现有代理启用 HTTP 身份验证。

  • Amazon MQ 会自动创建一个名为 monitoring-AWS-OWNED-DO-NOT-DELETE 的系统用户,该用户仅具有监控权限。即使在支持 HTTP 的代理上,该用户也使用 RabbitMQ 的内部身份验证系统,并且只能访问环回接口。Amazon MQ 通过添加受保护的用户标签来防止删除该用户

有关如何为您的 Amazon MQ for RabbitMQ 代理配置 HTTP 身份验证的信息,请参阅。使用 HTTP 身份验证和授权

支持的 HTTP 配置

适用于 RabbitMQ 的 Amazon MQ 支持 Rabb itMQ HTTP 身份验证插件中的所有可配置变量,但以下需要的例外情况除外。 Amazon ARNs有关 ARN 支持的详细信息,请参阅 RabbitMQ 配置中的 ARN 支持。

需要的配置 ARNs

auth_http.ssl_options.cacertfile

请改用 aws.arns.auth_http.ssl_options.cacertfile

auth_http.ssl_options.certfile

请改用 aws.arns.auth_http.ssl_options.certfile

auth_http.ssl_options.keyfile

请改用 aws.arns.auth_http.ssl_options.keyfile

不支持的 SSL 选项

也不支持以下 SSL 配置选项:

  • auth_http.ssl_options.cert

  • auth_http.ssl_options.client_renegotiation

  • auth_http.ssl_options.dh

  • auth_http.ssl_options.dhfile

  • auth_http.ssl_options.honor_cipher_order

  • auth_http.ssl_options.honor_ecc_order

  • auth_http.ssl_options.key.RSAPrivateKey

  • auth_http.ssl_options.key.DSAPrivateKey

  • auth_http.ssl_options.key.PrivateKeyInfo

  • auth_http.ssl_options.log_alert

  • auth_http.ssl_options.password

  • auth_http.ssl_options.psk_identity

  • auth_http.ssl_options.reuse_sessions

  • auth_http.ssl_options.secure_renegotiate

  • auth_http.ssl_options.versions.$version

  • auth_http.ssl_options.sni

  • auth_http.ssl_options.crl_check

亚马逊 MQ 中 HTTP 配置的其他验证

Amazon MQ 还对 HTTP 身份验证和授权强制执行以下额外验证:

  • auth_http.http_method必须是getpost

  • 以下路径配置必须使用 HTTPS URLs:

    • auth_http.user_path

    • auth_http.vhost_path

    • auth_http.resource_path

    • auth_http.topic_path

  • 如果有任何设置需要使用 Amazon ARN,则aws.arns.assume_role_arn必须提供。