StevenBlack / hosts

🔒 Consolidating and extending hosts files from several well-curated sources. Optionally pick extensions for porn, social media, and other categories.
MIT License
26.51k stars 2.2k forks source link

please block this site #2156

Closed superislam closed 1 year ago

superislam commented 1 year ago

hello please may you block this site https://نسوانجى.net

welcome[bot] commented 1 year ago

Hello! Thank you for opening your first issue in this repo. It’s people like you who make these host files better!

StevenBlack commented 1 year ago

Hello @superislam now why would we do that? Please explain.

superislam commented 1 year ago

Hello @superislam now why would we do that? Please explain.

Oh ok it's a porn forum and site

StevenBlack commented 1 year ago

Thanks @superislam. Ping @sinfonietta for inclusion.

Sinfonietta commented 1 year ago

Yes @StevenBlack this site is porn and I have added it.

StevenBlack commented 1 year ago

Thank you @Sinfonietta. Closing.

thomasmerz commented 1 year ago

My Pi-hole says 😞

  [i] Target: https://raw.githubusercontent.com/Sinfonietta/hostfiles/master/pornography-hosts
  [✓] Status: Retrieval successful
  [i] Analyzed 19516 domains, 1 domains invalid!
      Sample of invalid domains:
      - نسوانجى.net
  [i] List stayed unchanged
StevenBlack commented 1 year ago

Hi Thomas @thomasmerz.

Ping @Sinfonietta!

thomasmerz commented 1 year ago

My comment/point-of-view: No IDN-/punycode-domain can be used with Pi-hole. I don't know, if AdGuard or other DNS-based adblocker can do? 🤔 Therefore, no such domains at all should ever be added.

From my Howto or Whyto:

I’m also blacklisting: (^|\.)xn--.*$ which blocks all punycode domains because they’re often/mostly used for phishing

ler762 commented 1 year ago

if AdGuard or other DNS-based adblocker can do?

It looks like bind can do both idn (xn--.*) as well as UTF-8

$ tail -6 $RPZ

; test for ??international domain?? names
; xn--xxw-jgq.adj.st    CNAME   .
xxwᏚ.adj.st             CNAME   .

; --- end ---

$ dig xn--xxw-jgq.adj.st

results in

(xn--xxw-jgq.adj.st): query: xn--xxw-jgq.adj.st IN A +E(0)K (127.0.0.1)
(xn--xxw-jgq.adj.st): rpz QNAME NXDOMAIN rewrite xn--xxw-jgq.adj.st/A/IN via xn--xxw-jgq.adj.st.rpz.zone

as does

$ dig xxwᏚ.adj.st

(xn--xxw-jgq.adj.st): query: xn--xxw-jgq.adj.st IN A +E(0)K (127.0.0.1)
(xn--xxw-jgq.adj.st): rpz QNAME NXDOMAIN rewrite xn--xxw-jgq.adj.st/A/IN via xn--xxw-jgq.adj.st.rpz.zone
thomasmerz commented 1 year ago

@ler762 , sure, both can handle it:

$ dig نسوانجي.net

; <<>> DiG 9.16.33 <<>> نسوانجي.net
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 41866
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;نسوانجي.net.       IN  A

;; ANSWER SECTION:
نسوانجي.net.    300 IN  A   0.0.0.0

;; Query time: 3 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Sun Dec 11 15:05:31 CET 2022
;; MSG SIZE  rcvd: 63

But Pi-hole doesn't "like" it and says it's an invalid domainname:

image

thomasmerz commented 1 year ago

@yubiuser, can you (or other Pi-hole core-devs) explain us why some domains with punycode are "invalid" for Pi-hole? I didn't figured out by searching in source code… Thanks 😘

yubiuser commented 1 year ago

Because no browser or app should request those IDNs, but will convert them to punycode first. Therefore the punycode representation should be blocked. __

I didn't figured out by searching in source code

You need to look for the issues. https://github.com/pi-hole/pi-hole/issues?q=is%3Aissue+punycode+is%3Aclosed

thomasmerz commented 1 year ago

Regarding https://github.com/StevenBlack/hosts/issues/2156#issuecomment-1339669140 … @Sinfonietta , can you please take care of this? As @yubiuser wrote, you should add the punycode-domain and not the IDN.

Sinfonietta commented 1 year ago

@StevenBlack this is fixed, I am sorry for the long delay.

StevenBlack commented 1 year ago

Thank you everybody. Closing.