Skip to content

MrLuit/CensorRadar

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

95 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CensorRadar

GitHub release contributors

This repository is the open-source project for a website that scans your local network for any blocked websites.

How to use

Online

Go to the website and click 'Start scan'. You will see all blocked domains (if there are any). If a website is blocked, you can click the little info icon to find the full path that the client couldn't access. The image is path is helpful for troubleshooting why the request can't reach the server.

Offline

If you want to use the website locally, just download the website and open the index.html in one of the compatible browsers. Keep in mind that by default browsers won't let you access files with files so you have to enable that or find another way to access your domains.json, for example hosting domain.json online or launching chrome with --allow-file-access-from-files.

How does it work

Javascript creates a new image with an image on the domain we want to check as source. This will prevent CORS errors and works without too much trouble for the user. A disadvantage is that some popular domains host images on a different server and therefore it's hard to check if the domain is blocked or the image server of the domain. To solve this we try to request favicon.ico from the primary server and that works in most cases because even in the worst scenario the server would probably still redirect you to the right favicon URL.

Compatibility

Google Chrome Mozilla Firefox Safari Opera Internet Explorer Microsoft Edge

Libraries

API

Making an official API on Github Pages is hard because this project is written in Javascript and a simple curl request can't render Javascript. A solution would be to create your own project using the data from this repository. If you make your program fetch data from https://raw.githubusercontent.com/MrLuit/CensorRadar/master/domains.json (we will try to keep this list updated) you can use the data to ping all the websites on the list. Let me know about projects you've created :)

Contributing

When adding a new domain to domains.json, please follow this checklist:

  • The website is a popular international website and has an accesible image on the primary domain (not a different CDN server)
  • Don't put http:// or https:// in the domain and only put the path to the image in img without leading /
  • Make sure the image provided is accessible from not only your computer. A favicon works best but if the server stores favicon on another server and doesn't automatically redirect just use another image URL from the website.
  • If you don't want to append www. to the domain, put a ~ in front of the domain. This is required for subdomains like assets.github.com.

You can then proceed to make a pull request.

Report issue

Create an issue with as many details as possible regarding the problem. Useful information could be the image URL, your OS, your browser, your ISP or country, and steps to reproduce the issue.