Please note, this is a STATIC archive of website hashcat.net from October 2020, cach3.com does not collect or store any user information, there is no "phishing" involved.

hashcat Forum

Full Version: Custom mask - brute force 12 length passwords with 1 capital letter, 1 number
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I need to use brute force to crack the password. I know about the password that it has exactly 1 capital letter (A-Z), exacly 1 number (1-9) and exacly 10 lowercase letters (from a to z).

I have Python script that generates this type of passwords, but I don't know how to turn it into a hashcat mask.
Code:
import random

random.seed(None)

lowers = 'qwertyuiopasdfghjklzxcvbnm'
uppers = 'QWERTYUIOPASDFGHJKLZXCVBNM'
number = '0123456789'

length = 12

while True:
  uprspot = random.randint(0, length-1)
  numspot = uprspot

  while uprspot == numspot:
    numspot = random.randint(0, length-1)

  strgen = ""

  for i in range (0, length):

    if i == uprspot:
      strgen += random.choice(uppers)

    elif i == numspot:
      strgen += random.choice(number)

    else:
      strgen += random.choice(lowers)

  print(strgen)
There's no single mask. You have to generate a *list of masks*.

You can do this with policygen from the PACK toolkit.

https://security.stackexchange.com/quest...k-properly
Still going to take a long time.