Skip to main content

kpass is a simple password generator based on full name, age, and birthdate.

Project description

kpass

kpass is a Python library that:

  1. Generates hundreds (or thousands) of password combinations based on a person’s full name, age, and date of birth.
  2. Applies “leet”-style substitutions (e.g., A → 4, S → $, E → 3).
  3. Calculates password strength according to length, digit presence, special characters, mixed case, and absence of simple numeric sequences.
  4. Automatically saves generated passwords to a .txt file with progress bars powered by the rich library.

📦 Installation

pip install kpass-gen

🚀 Example Usage

1. Generating Passwords

from kpass import generator

# Generate hundreds of password combinations based on personal data
generator(
    name="Johnny Silverhand",
    age="34",
    birth_date="16/11/1988"
)

This will create a file named pass_generated.txt (in the default or specified folder) containing all valid passwords between 6 and 18 characters, with a progress bar shown during generation.


2. Applying Leet-Style Substitutions

from kpass import aplly_ciphers

original = "SecurePass"
leet = aplly_ciphers(original)
print(leet)  # → "$3cur3P4$$" (example)

3. Saving Passwords Manually

If you already have a list of passwords and only want to save them:

from kpass import save_to_txt

passwords = ["abc123!", "Johnny34@", "4bcc!23"]
save_to_txt(passwords, file_name="my_passwords.txt")

4. Checking Password Strength

from kpass import verify

# Returns a numeric score (0–6)
score = verify(password="Luc@s683", want_verdict=False)
print(score)        # → 6

# Returns a hashtag verdict
label = verify(password="Luc@s683", want_verdict=True)
print(label)        # → "#very_strong"
Score Verdict Description
0 #very_weak Very weak
1–2 #weak Weak
3 #mean Average
4 #good Good
5 #strong Strong
6 #very_strong Very strong

🔧 API Reference

generator(
    name: str,
    age: str,
    birth_date: str
) -> None
  • Generates and saves password combinations automatically to pass_generated.txt.
aplly_ciphers(
    text: str
) -> str
  • Transforms the input text using leet-style substitutions defined in the internal dictionary.
save_to_txt(
    passwords: list[str],
    file_name: str = "pass_generated.txt"
) -> None
  • Saves the list of passwords to a text file, displaying a progress bar in the terminal.
verify(
    password: str,
    want_verdict: bool = True
) -> int | str
  • Evaluates the strength of a password: returns a numeric score (0–6) or, if want_verdict=True, the corresponding hashtag verdict.

✅ Requirements

  • Python 3.6 or higher
  • rich

📄 License

This project is licensed under the MIT License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kpass_gen-0.2.0.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

kpass_gen-0.2.0-py3-none-any.whl (7.1 kB view details)

Uploaded Python 3

File details

Details for the file kpass_gen-0.2.0.tar.gz.

File metadata

  • Download URL: kpass_gen-0.2.0.tar.gz
  • Upload date:
  • Size: 6.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.3

File hashes

Hashes for kpass_gen-0.2.0.tar.gz
Algorithm Hash digest
SHA256 09d2991072b0c904ddcd06f34b718c69cb8bfba6b487e06a3f0f16d559bf3bb7
MD5 134b33246e676226b9584d4357331548
BLAKE2b-256 135557d1305a27b33ee8ec8a9ea828a5170dcc6cee3e05c6ff099a547d93a12a

See more details on using hashes here.

File details

Details for the file kpass_gen-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: kpass_gen-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 7.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.3

File hashes

Hashes for kpass_gen-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 aca8c37c32c1507d4443e7ab9e36c81abe238713f72fc804f5659435ea89b6cd
MD5 9f62b7cde90af20ef7d1f1bce96b11d8
BLAKE2b-256 4f0acf90ac012ebec2c88bf12ede23ce6502917faa375051f6a18561f80d6172

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page