增加防盗链拦截时默认提示文字

This commit is contained in:
GoEdgeLab
2022-09-22 17:52:57 +08:00
parent 393e2f9878
commit efe6cbc881
4 changed files with 20 additions and 10 deletions

View File

@@ -173,7 +173,7 @@ func (this *HTTPRequest) checkWAFRequest(firewallPolicy *firewallconfigs.HTTPFir
if countryId > 0 && lists.ContainsInt64(regionConfig.DenyCountryIds, countryId) {
this.firewallPolicyId = firewallPolicy.Id
this.writeCode(http.StatusForbidden)
this.writeCode(http.StatusForbidden, "", "")
this.writer.Flush()
this.writer.Close()
@@ -192,7 +192,7 @@ func (this *HTTPRequest) checkWAFRequest(firewallPolicy *firewallconfigs.HTTPFir
if provinceId > 0 && lists.ContainsInt64(regionConfig.DenyProvinceIds, provinceId) {
this.firewallPolicyId = firewallPolicy.Id
this.writeCode(http.StatusForbidden)
this.writeCode(http.StatusForbidden, "", "")
this.writer.Flush()
this.writer.Close()