[WordPress] 外掛分享: Easy Basic Authentication – Add basic auth to site or admin area

首頁 › 外掛目錄 › Easy Basic Authentication – Add basic auth to site or admin area
WordPress 外掛 Easy Basic Authentication – Add basic auth to site or admin area 的封面圖片
800+
安裝啟用
★★★★★
5/5 分(3 則評價)
31 天前
最後更新
—
問題解決
WordPress 5.0+ PHP 7.2.5+ v4.2.0 上架:2023-09-28

內容簡介

Easy Basic Authentication 外掛提供簡單的方法為您的 WordPress 網站添加基本身份驗證。您可以為整個網站或僅管理區域啟用身份驗證,確保只有授權用戶能夠訪問,從而增強網站的安全性。

【主要功能】
• 簡單配置:輕鬆設置網站或管理區域的基本身份驗證
• 管理區域保護:快速有效地限制對管理區域的訪問
• 整個網站保護:可選擇對整個網站啟用身份驗證
• 登錄失敗記錄:追蹤未授權訪問嘗試
• 訪問日誌:記錄成功登錄的活動
• 電子郵件警報:通知未授權訪問嘗試

外掛標籤

開發者團隊

⬇ 下載最新版 (v4.2.0) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「Easy Basic Authentication – Add basic auth to site or admin area」→ 直接安裝(推薦)
📦 歷史版本下載

原文外掛簡介

The Easy Basic Authentication plugin provides a simple method to add basic authentication to your WordPress site. You can enable basic authentication for the entire site or only for the admin area by setting a custom username and password. Secure your site by restricting access only to authorized users.
Try it on a free mock site: click here
Key Features

Simple Configuration: With Easy Basic Authentication, you can easily set up basic authentication for your entire website or specifically for the admin area. Set a custom username and password to ensure secure access.

Admin Area Protection: If you wish to restrict access to your WordPress admin area, Easy Basic Authentication allows you to do so quickly and effectively. Only users with the correct credentials will be able to access this critical part of your site.

Entire site protection: If you wish, there is an option to extend the access limitation to the entire site and not just for your WordPress admin area, Easy Basic authentication allows you to do this quickly and effectively. Only users with the correct credentials will be able to access this critical part of your site.

Failed Access Logging: The plugin keeps track of failed login attempts, helping you identify unauthorized access attempts. This is particularly useful for monitoring your site’s security.

Access Log: If you choose to enable this feature, Easy Basic Authentication allows you to log successful logins, providing a comprehensive overview of login activities on your site.

Easy Management: The plugin’s intuitive interface makes it simple to manage basic authentication settings. You can easily enable or disable basic authentication and adjust credentials to suit your needs.

Email Alert Functionality: Easy Basic Authentication includes an email alert feature to notify you of unauthorized access attempts. You can receive email alerts when someone tries to access your site without proper credentials.

White List Functionality: Easy Basic Authentication now includes a White List feature, allowing you to specify trusted IP addresses exempt from basic authentication. Configure this list to grant immediate access to known users or systems without requiring credentials, enhancing convenience while maintaining security.

Access Token for Crawlers: Some visitors cannot type a username and password: a search engine crawler, an uptime check, a headless front end. Generate an access token in the settings and let them through with an X-Basic-Auth-Token header, or an Authorization: Bearer one. The token opens the site only, never the admin area or the login page, and it exists only if you generate it.

Protect your WordPress site with basic authentication quickly and reliably. Easy Basic Authentication gives you control to ensure that only authorized users can access your online resources. Maintain your site’s security and prevent unwanted access today with Easy Basic Authentication.
Usage

Visit the plugin settings page to configure your desired basic authentication options.
Choose whether to enable basic authentication for the entire site or just the admin area.
Set a custom username and password for secure access.
Monitor failed access attempts and access logs for added security.

Letting a crawler in with a token
Go to the plugin settings, tick Generate a token when saving next to Access token for crawlers, and save. The token appears in the field; copy it and give it to the service that needs to reach the site.
That service must send it as a header, one of these two:
X-Basic-Auth-Token: your-token-here
Authorization: Bearer your-token-here
A request carrying the right token is served normally. The admin area and the login page stay behind the username and password, so the token cannot be used to reach the dashboard. A wrong token is refused like wrong credentials, and it is recorded among the failed attempts.
The token is a password: anyone holding it can read the whole site. Send it over HTTPS, and tick Delete the token and close this door when it is no longer needed. Tick Replace this token with a new one when saving to rotate it; the old one stops working immediately.
The basic_auth_token_access_granted action fires whenever a request comes in on the token, if you want to log or count those separately.
Troubleshooting: Resetting Basic Authentication
If you’re having trouble logging in due to the basic authentication, you can reset it and regain access by following these steps:
1 Connect to your website via FTP.
2 Navigate to the plugin directory:
wp-content/plugins/easy-basic-authentication/class/
3 Locate the file:
easy-basic-authentication-class.php
4 Find the following line:
add_action( 'init', array($this,'basic_auth_admin') );
5 Comment out that line by adding a # at the beginning:
#add_action( 'init', array($this,'basic_auth_admin') );
6 Save the file and re-upload it to your server.
This will disable the basic authentication temporarily, allowing you to log in. Once logged in, you can adjust the plugin settings as needed.
If you need further assistance, feel free to reach out.
GitHub Repository
You can find the source code and contribute to the project on GitHub: Easy Basic Authentication on GitHub

延伸相關外掛

文章
Filter
Mastodon