Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Hash visualization tool inspired by beautiful ssh-keygen randomart.
How can something so soulless be so pretty?
From PyPI:
pip install hashime
From git:
pip install git+https://github.com/sakhezech/hashime
hashime ...
or python -m hashime ...
$ hashime -h
usage: hashime [-h] [-v] [-l] [-a ALGO] [-H HASH] [--frame FRAME | --no-frame]
[--top-text TOP_TEXT] [--bottom-text BOTTOM_TEXT]
[-d [DIGEST_FORM]] [-f FILE] [-o OUT]
hash visualization tool
options:
-h, --help show this help message and exit
-v, --version show program's version number and exit
-l, --list show visualization algorithms, hashing functions,
digest forms and exit
-a ALGO, --algorithm ALGO
visualization algorithm (defaults to drunken_bishop)
-H HASH, --hash-function HASH
hashing function (defaults to sha256)
--frame FRAME comma-separated frame characters in order of (top_line,
right_line, bottom_line, left_line, top_left_corner,
top_right_corner, bottom_right_corner,
bottom_left_corner, left_bracket, right_bracket)
--no-frame output visualization without a frame
--top-text TOP_TEXT text on the top frame line
--bottom-text BOTTOM_TEXT
text on the bottom frame line
-d [DIGEST_FORM], --digest [DIGEST_FORM]
show digest (defaults to base64)
-f FILE, --file FILE input file (defaults to stdin)
-o OUT, --output OUT output file (defaults to stdout)
$ hashime -H md5 -d -f LICENSE
+----[LICENSE]----+
| |
| . |
| . . o |
| . = o + |
| * * + S |
| o O + |
| * = + |
| . + = . |
| E . |
+------[MD5]------+
md5: lGqJe4ZYqSXluPYkZOH/oQ==
>>> import hashime
>>> bishop = hashime.DrunkenBishop()
>>> bishop.update_from_file_hash('./LICENSE')
>>> art = bishop.to_art(
... top_text='LICENSE',
... bottom_text='SHA256',
... brackets=('<', '>'),
... lines=('═', '│', '─', '║'),
... corners=('╔', '╕', '┘', '╙'),
... )
>>> print(art)
╔════<LICENSE>════╕
║ ..o + │
║ o E.= o │
║ o +.. o │
║ . o o.o │
║. o =.S. │
║.. o.+..+ │
║o. o.oo+..= │
║. . *+=..+o o . │
║ .=+O.++ . o.. │
╙─────<SHA256>────┘
Use ruff check --fix .
and ruff format .
to check and format your code.
To get started:
git clone https://github.com/sakhezech/hashime
cd hashime
python -m venv .venv
source .venv/bin/activate
pip install -e '.[dev]'
FAQs
hash visualization tool
We found that hashime demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.