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.
「 get path dir/+child all file path 」
npm install files-list
yarn add files-list
const filesList = require('files-list');
(async () => {
let results = await filesList('./test.js')
// ['.editorconfig',
// '.gitattributes',
// '.gitignore',
// '.npmrc',
// '.travis.yml',
// '.yo-rc.json',
// 'files-list.js',
// 'license',
// 'package.json',
// 'readme.md',
// 'test.js',
// 'yarn.lock' ]
});)
filesList.sync()
is sync
name: | path |
---|---|
Type: | string |
Desc: | path file/dir |
name: | deep |
---|---|
Type: | number | string {'all'} |
Default: | 1 |
Desc: | how deep you want |
name: | ignore |
---|---|
Type: | Array |
Default: | ['.git', 'node_modules'] |
Desc: | ignore Dir name you want |
split the code to files-list-sync
MIT © chinanf-boy
FAQs
get path dir/child all file path
We found that files-list 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.