File: README.md

package info (click to toggle)
pwndck 0.5-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 144 kB
  • sloc: python: 295; makefile: 10
file content (58 lines) | stat: -rw-r--r-- 1,925 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# pwndck

Check the the HaveIBeenPwned password database to see if a particular password
has been compromised.

It uses the [haveibeenpwned API](https://haveibeenpwned.com/API/v3#PwnedPasswords)
for the check:
  * This use does not require an API key. Anyone can run it.
  * This is more secure than the [web page tool](https://haveibeenpwned.com/Passwords).
    your password is
    [not exposed](https://blog.cloudflare.com/validating-leaked-passwords-with-k-anonymity/)
    beyond your local machine.
  * It returns the number of times the password occurs in the database.

# Install
Install from [PyPi](https://pypi.org/project/pwndck/)

# Usage

    $ pwndck -h
    usage: pwndck [-h] [-q] [-i [INPUT] | passwords ...]
    
    Report # of password hits in HaveIBeenPwned
    
    positional arguments:
      passwords            The password(s) to check
    
    options:
      -h, --help           show this help message and exit
      -q, --quiet          Suppress output
      -i, --input [INPUT]  File containing passwords, one per line
                           ('-' for stdin)
    
    Evaluate one or more passwords against the HaveIBeenPwned
    password database, and return the number of accounts for which
    they have been reported as compromised.
     
    The number of entries found in the database is returned. if
    multiple passwords are being checked, the password name is also
    returned.
     
    If the password is not specified on the command line, the user
    will be prompted.
     
    The command returns with an error code if the password is found
    in the database.
     
    See https://haveibeenpwned.com/API/v3#PwnedPasswords

# Module

    $ python3
    Python 3.13.11 (main, Dec  8 2025, 11:43:54) [GCC 15.2.0] on linux
    Type "help", "copyright", "credits" or "license" for more information.
    >>> import pwndck
    >>> pwndck.process_pw("password")
    52256179
    >>>