From 704980d4f83f3c21a2bf9062fc774ca1fb0a4c1e Mon Sep 17 00:00:00 2001 From: Toby Chui Date: Tue, 18 Jun 2024 16:37:58 +0800 Subject: [PATCH] Added cf-style error templates --- example/README.md | 8 + .../templates_cf/blacklist.html | 185 ++++++++++++++++++ .../templates_cf/notfound.html | 154 +++++++++++++++ .../templates_cf/whitelist.html | 185 ++++++++++++++++++ .../templates_uwu/blacklist.html | 52 +++++ .../templates_uwu/notfound.html | 42 ++++ .../templates_uwu/whitelist.html | 52 +++++ 7 files changed, 678 insertions(+) create mode 100644 example/other-templates/templates_cf/blacklist.html create mode 100644 example/other-templates/templates_cf/notfound.html create mode 100644 example/other-templates/templates_cf/whitelist.html create mode 100644 example/other-templates/templates_uwu/blacklist.html create mode 100644 example/other-templates/templates_uwu/notfound.html create mode 100644 example/other-templates/templates_uwu/whitelist.html diff --git a/example/README.md b/example/README.md index a14ee27..80d232e 100644 --- a/example/README.md +++ b/example/README.md @@ -15,4 +15,12 @@ The templates folder contains the template for overriding the build in error or To use the template, copy and paste the `wwww` folder to the same directory as zoraxy executable (aka the src/ file if you `go build` with the current folder tree). + + +### Other Templates + +There are a few pre-built templates that works with Zoraxy where you can find in the `other-templates` folder. Copy the folder into `www` and rename the folder to `templates` to active them. + + + It is worth mentioning that the uwu icons for not-found and access-denied are created by @SAWARATSUKI diff --git a/example/other-templates/templates_cf/blacklist.html b/example/other-templates/templates_cf/blacklist.html new file mode 100644 index 0000000..3381b28 --- /dev/null +++ b/example/other-templates/templates_cf/blacklist.html @@ -0,0 +1,185 @@ + + Access denied | website used Zoraxy to restrict access + + + + + + + + + + + + + + + + +
+ +
+
+

+ Error + 1006 + Ray ID: +

+

Access denied

+
+ +
+ +
+
+
+

What happened?

+

The owner of this website has banned your IP address ().

+
+ + +
+
+ + + + +
+
+ + + + \ No newline at end of file diff --git a/example/other-templates/templates_cf/notfound.html b/example/other-templates/templates_cf/notfound.html new file mode 100644 index 0000000..0325ac0 --- /dev/null +++ b/example/other-templates/templates_cf/notfound.html @@ -0,0 +1,154 @@ + + + + + + + + + + + + + + + 404 - Host Not Found + + + +
+

+
+

Error 404

+

Target Host Not Found

+ +
+

+
+
+
+
+
+ + + + + + + + + + You +

Browser

+

Working

+
+
+ +
+
+ + + + + + + + + + + Gateway Node +

Reverse Proxy

+

Working

+
+
+ +
+
+ + + + + + + + + +

Host

+

Not Found

+
+
+
+
+
+
+
+
+
+

What happend?

+

The reverse proxy target domain is not found.
For more information, see the error message on the reverse proxy terminal.

+
+
+

What can I do?

+
If you are a visitor of this website:
+

Please try again in a few minutes

+
If you are the owner of this website:
+
+
Check if the proxy rules that match this hostname exists
+
Visit the Reverse Proxy management interface to correct any setting errors
+
+
+
+
+
+
+
+
+

Powered by Zoraxy

+
+

+ + + + diff --git a/example/other-templates/templates_cf/whitelist.html b/example/other-templates/templates_cf/whitelist.html new file mode 100644 index 0000000..9fdf707 --- /dev/null +++ b/example/other-templates/templates_cf/whitelist.html @@ -0,0 +1,185 @@ + + Access denied | website used Zoraxy to restrict access + + + + + + + + + + + + + + + + +
+ +
+
+

+ Error + 1006 + Ray ID: +

+

Access denied

+
+ +
+ +
+
+
+

What happened?

+

Your IP address () do not have access permission to this website.

+
+ + +
+
+ + + + +
+
+ + + + \ No newline at end of file diff --git a/example/other-templates/templates_uwu/blacklist.html b/example/other-templates/templates_uwu/blacklist.html new file mode 100644 index 0000000..1e30ad0 --- /dev/null +++ b/example/other-templates/templates_uwu/blacklist.html @@ -0,0 +1,52 @@ + + + + Access Denied (。ŏ_ŏ) + + + + + + +
+ +

Oh nyo, uwu have bewn bwackwisted! (。ŏ_ŏ)

+
+ + \ No newline at end of file diff --git a/example/other-templates/templates_uwu/notfound.html b/example/other-templates/templates_uwu/notfound.html new file mode 100644 index 0000000..1f0202a --- /dev/null +++ b/example/other-templates/templates_uwu/notfound.html @@ -0,0 +1,42 @@ + + + + Not Found Σ(*゚д゚ノ)ノ + + + + + + +
+ +

The page uwu awe wooking fow does nowt exists own thiws sewvew Σ(*゚д゚ノ)ノ

+
+ + \ No newline at end of file diff --git a/example/other-templates/templates_uwu/whitelist.html b/example/other-templates/templates_uwu/whitelist.html new file mode 100644 index 0000000..1227289 --- /dev/null +++ b/example/other-templates/templates_uwu/whitelist.html @@ -0,0 +1,52 @@ + + + + Not Whitelisted (´・ω・`) + + + + + + +
+ +

Oh nyo, youw ip iws nowt incwuded in the whitewist of thiws website (´・ω・`)

+
+ + \ No newline at end of file