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.
This is a simple library and utility for generating word-search puzzles from vocabulary lists. The puzzles can be configured to allow words to be hidden in various ways (diagonal, backwards), as well as to include a message hidden in the unused squares. The puzzles are emitted as PDF documents.
Use RubyGems:
$ gem install wordsearch
The simplest way to use the tool is via the included command-line utility:
$ wordsearch -h
USAGE: bin/wordsearch [options] [words] [-]
-r, --rows ROWS
-c, --columns COLS
-b, --[no-]backward
-d, --[no-]diagonal
-o, --output FILENAME
-f, --font FONT
-s, --seed SEED
-v, --[no-]solve
-m, --message MESSAGE
-w, --word-file FILE
-t, --[no-]text
Specify words in any of three ways; on the command-line:
$ wordsearch nitwit blubber oddment tweak
Or in a separate file (each word on its own line):
$ wordsearch -w words.txt
Or via stdin
:
$ cat dict | wordsearch -
Program arguments are:
--rows
: the number of rows in the grid (defaults to 15)--columns
: the number of columns in the grid (defaults to 15)--backward
: allow words to be spelled backwards on the grid--diagonal
: allow words to be spelled diagonally on the grid--output
: the name of the file to save the puzzle to (defaults to puzzle.pdf
)--font
: the name of a font to use to render the puzzle (defaults to Helvetica
).
You can use any PDF font (Helvetica, Times-Roman, Courier) or any TTF font
by providing the full path name of the TTF file.--seed
: the number used to seed the random number generator. By providing
the same seed, you can (re)generate the same puzzle. This is particularly
useful for encoding a message in the unused squares of a puzzle (see below).--solve
: the generated PDF will consist of two pages, with the solution
on the second page.--message
: a message to encode in the unused squares of the puzzle. Non-letter
characters are discarded. The resulting message should be the same length
as the number of unused squares in the puzzle.--word-file
: a text file containing words to use in the puzzle.--text
: draw the puzzle to the terminal as text, instead of emitting a PDFTo encode a message in the unused squares of a puzzle, first generate a puzzle with the desired vocabulary list:
$ wordsearch -w words.txt -r 10 -c 10
seed: 1443047854
unused squares: 15 (of 100)
Repeat until the desired number of unused squares are found (you want a number of unused squares that matches the message you want to encode in the puzzle). If we wanted to encode the message "Puzzles are fun!", we would need 13 unused squares (spaces and punctuation are ignored).
Once you get a puzzle with the appropriate number of unused squares, note the seed value:
$ wordsearch -w words.txt -r 10 -c 10
seed: 1443047875
unused squares: 13 (of 100)
Then, generate it again, passing the -m
(message) and -s
(seed)
options:
$ wordsearch -w words.txt -r 10 -c 10 -s 1443047875 -m "puzzles are fun"
seed: 1443047875
unused squares: 13 (of 100)
The resulting puzzle will spell out "puzzles are fun" with the squares that are left after finding all the words!
(Note that if your message is longer than the number of unused squares, it will be truncated, and if it is shorter, it will be padded with random letters.)
No word may be too large to fit on the grid, or an error will result. Also, trying to fit too many words into too small of a grid may take a very long time, and will probably fail. If you get an error, or if the utility is taking too long to generate the puzzle, try using a larger grid size.
WordSearch Puzzle Generator by Jamis Buck is licensed under a Creative Commons Attribution 4.0 International License.
Based on a work at http://github.com/jamis/wordsearch.
FAQs
Unknown package
We found that wordsearch-puzzle demonstrated a not healthy version release cadence and project activity because the last version was released 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.