GithubHelp home page GithubHelp logo

amiralipoor20072007 / cfscanner Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mortezabashsiz/cfscanner

0.0 0.0 0.0 13.9 MB

Cloud Flare scanner

License: GNU General Public License v3.0

Shell 98.88% Dockerfile 1.12%

cfscanner's Introduction

CloudFlare Scanner

This script scans Millions of Cloudflare IP addresses and generates a result file containing the IPs which are work with CDN.

This script uses v2ray+vmess+websocket+tls by default and if you want to use it behind your Cloudflare proxy then you have to set up a vmess account, otherwise, it will use the default configuration.

Requirements

You have to install the following packages:

git
tput
bc
curl
parallel (version > 20220515)

How to run

1. clone

[~]>$ git clone https://github.com/MortezaBashsiz/CFScanner.git

2. Change directory and make them executable

[~]>$ cd CFScanner/bash
[~/CFScanner/bash]> chmod +x ../bin/*

3. Get config.real

[~/CFScanner/bash]>$ curl -s http://bot.sudoer.net/config.real -o ./config.real

In the config file the variables are

id:         User's UUID
Host:       Host address which is behind Cloudflare
Port:       Port which you are using behind Cloudflare on your origin server
path:       Websocket endpoint like api20
serverName: SNI

4. Execute it

At following command pay attention to the numbers threads, speed and Custom Subnet File.

Threads: This is an integer number that defines the parallel threads count

Speed: This is the filter that you can define to list the IPs based on download speed. The values must be one of [25 50 100 150 200 250 500], and all values are in KBPS (Kilo Bytes Per Second). For example, if you set it to 50, it means that you will only list the IPs which have a download speed of more than 50 KB/S.

Custom Subnet File: This is an optional argument which is a file address if you want to execute only some specific subnets. Then put your subnets in a file and pass the file as an argument to the command.

[~/CFScanner/bash]>$ bash cfScanner.sh SUBNET threads ./config.real speed [Custome Subnet File]

EXAMPLE: without custom subnet

[~/CFScanner/bash]>$ bash cfScanner.sh SUBNET 8 ./config.real 100

EXAMPLE: with custom subnet

[~/CFScanner/bash]>$ bash cfScanner.sh SUBNET 8 ./config.real 100 ./custom.subnets

Which the custom.subnets is like as follows. You can edit this file and add your subnets in each line.

[~/CFScanner/bash]>$ cat custom.subnets 
5.226.179.0/24
203.89.5.0/24
[~/CFScanner/bash]>$

EXAMPLE: with custom ip file

[~/CFScanner/bash]>$ bash cfScanner.sh IP 8 ./config.real 100 ./ip.list

Which the custom.subnets is like as follows. You can edit this file and add your subnets in each line.

[~/CFScanner/bash]>$ cat ip.list
23.227.37.250 
23.227.37.252 
23.227.37.253 
23.227.37.254 
23.227.37.255 
23.227.38.1 
23.227.38.8 
23.227.38.2 
23.227.38.3 
23.227.38.6 
23.227.38.14 
23.227.38.11 
23.227.38.9 
23.227.38.4 
23.227.38.10 
23.227.38.7 
[~/CFScanner/bash]>$

5. Result

It will generate a file in datetime format in the result directory.

[~/CFScanner]>$ ls result/
20230120-203358-result.cf
[~/CFScanner]>$

Docker

This script also exists in docker, find out here.

Video Guide

You can find a video guide for this script on youtube.

cfscanner's People

Contributors

ali-frh avatar alirezaaraby avatar amini8 avatar armgham avatar beh-rouz avatar hiiirad avatar majnikool avatar mortezabashsiz avatar thehxdev avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.