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.
words.js is an addition to my strings.js library, and operates primarily on single word-strings instead of individual characters.
This is in a very early stage of development, things will change for sure, use with care.
This manual is still incomplete, will try to complete soon.
Words are seperated by spaces.
Words.prototype.constructor
<object>constructor( <string>/<number> string= '', <string>/<number> delimiter= ' ' )
Initializes the contextual object.
Words.prototype.set
<string> set( <string>/<number> index, [index1, ..., indexN] )
Words.prototype.get
<string> get( <string>/<number> index, [index1, ..., indexN] )
Returns the word(s) found at index(es).
Words.prototype.find
<array> find( <string>/<number> substring, <boolean> addPositions= false )
Returns an array containing all indices(numbers) in this.words where substring is found. If addPositions is set true, also the position within the found word is returned, and the result will be an array of arrays with indices.
Words.prototype.upper
<string> upper( <string>/<number> index, <string>/<number> position )
Words.prototype.lower
<string> lower( <string>/<number> index, <string>/<number> position )
Words.prototype.reverse
<array> reverse( <string>/<number> index, [index1, ..., indexN] )
Reverses the word on index if index is given. If index is 0, every word is reversed, but will remain on it's current index, every following index will not be reversed. Without arguments, all words and all indices are reversed.
Words.prototype.shuffle
<array> shuffle( <string>/<number> index, [index1, ..., indexN] )
Shuffles the word on index, if index is given. If index is/are strings, the matching words will be shuffled. If index is 0, every word is shuffled, but will remain on it's current index, following arguments are ignored. Without arguments, all indices are shuffled.
FAQs
A library/toolbox for working with words and strings.
The npm package words.js receives a total of 4 weekly downloads. As such, words.js popularity was classified as not popular.
We found that words.js 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.