bruteforce.py

Created by systeme-eratz

Created on January 06, 2025

1.1 KB

Brute Force pour tester ses mots de passe.

Kojiverse Productions


## Brute Force Lite Algorithm - Kojiverse Productions
from math import *
from random import *
import time

#[print(chr(i)) for i in range(32,127)]

class ForceEngine:
  def __init__(self,limit=(123,32)):
    self.is_active = True
    self.limit = limit
    self.time_is = time.monotonic()

  def check_limit(self,liste):
    liste = liste[::-1]
    for i,number in enumerate(liste):
      if number>self.limit[0]:
        liste[i]=self.limit[1]
        if i<len(liste)-1:
          liste[i+1]+=1
        else:
          liste.insert(0,self.limit[1])
    return liste[::-1]
    
  def Force(self,txt:str):
    txt = [ord(char) for char in txt]
    essay = [self.limit[1]]
    while essay!=txt:
      for i in range(self.limit[1],self.limit[0]+1):
#        print("".join([chr(j) for j in essay]))
        essay[-1]=i+1
        
        if essay==txt:
          break
    
      essay = self.check_limit(essay)
    
    print("SUCCESS! \ncracked password : %s\nin %s s."%("".join([chr(j) for j in essay]),(time.monotonic()-self.time_is)%60))
    
bruteForce = ForceEngine([122,97])
bruteForce.Force("hello")

During your visit to our site, NumWorks needs to install "cookies" or use other technologies to collect data about you in order to:

With the exception of Cookies essential to the operation of the site, NumWorks leaves you the choice: you can accept Cookies for audience measurement by clicking on the "Accept and continue" button, or refuse these Cookies by clicking on the "Continue without accepting" button or by continuing your browsing. You can update your choice at any time by clicking on the link "Manage my cookies" at the bottom of the page. For more information, please consult our cookies policy.