[wordpress插件] Disable REST API and Require JWT / OAuth Authentication禁用REST API并需要JWT / OAuth身份验证

wordpress 插件 文章 2020-04-18 10:40 522 0 全屏看文

AI助手支持GPT4.0

评分
0
描述

When you activate this plugin, all REST API endpoints will be disabled for non-authorized requests.

激活此插件时,所有REST API端点都将针对未授权的请求禁用。

Best used with any of these plugins:

最适合与以下任何一个插件一起使用:

    Blocks ALL REST API endpoints except for:

    阻止所有 REST API端点,除了:

      • /jwt-auth/v1/token/validate
      • / jwt-auth / v1 / token / validate

      • /jwt-auth/v1/token
      • / jwt-auth / v1 / token

      • /oauth/authorize
      • / oauth / authorize

      • /oauth/token
      • / oauth / token

      • /oauth/me
      • / oauth / me

      Allows all REST API endpoints if they come with a valid Bearer Token Authentication (authentication via GET URL variables are still blocked)

      如果所有REST API端点都带有有效的 Bearer Token身份验证(允许通过GET URL变量进行的身份验证仍然被阻止),则允许它们

      When used alone in your site, your REST API will essentially be disabled.

      在您的站点中单独使用时,您的REST API实际上将被禁用。

      Note that this plugin itself doesn’t provide JWT or OAuth authentication, it only whitelists them.

      请注意,此插件本身不提供JWT或OAuth身份验证,仅将其列入白名单。

      Features

      功能

        • No settings page
        • 无设置页面

        • You can whitelist other REST API endpoint via a filter hook (see FAQs below)
        • 您可以通过过滤器挂钩将其他REST API端点列入白名单(请参阅下面的常见问题解答)

        • Blocks all REST API endpoints.. but
        • 阻止所有REST API端点。.但是

        • Allows requests with Bearer Token Authentication.. and
        • 允许带有承载令牌身份验证的请求。和

        • Allows JWT Authentication for WP REST API & 针对WP REST API的JWT身份验证

          ://wordpress.org/plugins/oauth2-provider/">WP OAuth Server authentication endpoints

        • ://wordpress.org/plugins/oauth2-provider/“> WP OAuth服务器身份验证端点

安装步骤

    1. Head over to Plugins > Add New in the admin
    2. 转到插件>在管理员中添加新内容

    3. Search for “Disable REST API and Require Authentication”
    4. 搜索“禁用REST API并需要身份验证”

    5. Install & activate the plugin
    6. 安装并激活插件

    7. Now your REST API endpoints are disabled for non-authenticated requests.
    8. 现在,对于未经身份验证的请求,您的REST API端点已被禁用。

下载地址
https://downloads.wordpress.org/plugin/disable-rest-api-and-require-jwt-oauth-authentication.1.0.zip
-EOF-

AI助手支持GPT4.0