Edge currently supports 2 ip geographic information database providers, ipip.net and maxmind, with maxmind offering a free product: GeoLite2.
Then select MaxMind Lite on Edge Admin, paste the license key into the corresponding location, if the save fails, you may need to wait for one or two working days for the license key to take effect.
Edge supports Edge Captcha and HCaptcha, we will show an example of how to add hcaptcha checks to a website.
First refer to global waf rule, configure waf rules to trigger hcaptcha.
Then create a new application corresponding to the domain name(e.g. www.trump.com)
Configure the domain's waf rule to be the one just created, and choose hcaptcha as the interception action.
Configure forwarding after validation pass.
Finished configure above, let’s do some test: Modify the /etc/hosts file to point the domain name to the node, and note that browser caching should be disabled, otherwise the original URL may still be accessed directly.
Then visit the URL in your browser and you will see the hcaptcha page, and you can continue to visit the original website after the verification has passed.
First go to the hCaptcha website to register and login, where the site key is located as follows:
secret key is located as follows：
1616140331576: [2021-03-19 15:52:11] 127.0.0.1 (127.0.0.1) A www.openresty.com [US] [California] [Verizon] [A: 127.0.0.1]
Unix_timestamp: [local_time] remote_addr (client_subnet) DNS_query_type host [client_country] [client_province] [client_isp] [DNS_record]
Note that all error logs are in the same format
2021/03/19 16:30:56 [error] 3393524#3393524: *934186 stream [lua] dns.lua:29: go(): rewrite phase failed: nil, udp client: 127.0.0.1, server: 0.0.0.0:53
local_time [log_level] Process_id#Thread_id *Connection_id Module_name [language] file_name:line_number: function_name(): log_body, protocol client_address, server_address