
Research
/Security News
Malicious npm Packages Target WhatsApp Developers with Remote Kill Switch
Two npm packages masquerading as WhatsApp developer libraries include a kill switch that deletes all files if the phone number isn’t whitelisted.
@zooadmincomponent/zoo-admin-component
Advanced tools
tsconfig.json文件中替换以下配置
"target": "ES2020",
"module": "ESNext",
"moduleResolution": "bundler",
"noEmit": true,
"emitDeclarationOnly": false,
在本地打包后推到npm官方
tsconfig.json文件中替换以下配置
"target": "ESNext",
"module": "NodeNext",
"moduleResolution": "nodenext",
"emitDeclarationOnly": true,
"noEmit": true,
vite.config.ts文件将以下配置添加进build对象中
build: {
lib: {
entry: resolve(__dirname, 'src/plugins/index.ts'), // 插件的入口文件
name: 'ZooAdminComponent', // 插件的全局变量名
fileName: (format) => `zoo-admin-component.${format}.ts`, // 输出的文件名
formats: ["es", "umd", "cjs"],
},
rollupOptions: {
external: ['vue'],
output: {
globals: {
vue: 'Vue', // 将 Vue 映射到全局变量
}
},
},
},
打包命令
npm run build
登陆npm账号
npm login
执行命令后出现以下提示 打开地址后 将邮件中的获取验证码进行验证登陆
Login at:
https://www.npmjs.com/login?next=/login/cli/f7360887-833a-4e9b-927f-a31ba5a12cba
Press ENTER to open in the browser...
将包推送到npm中
npm publish --access public
FAQs
Unknown package
The npm package @zooadmincomponent/zoo-admin-component receives a total of 0 weekly downloads. As such, @zooadmincomponent/zoo-admin-component popularity was classified as not popular.
We found that @zooadmincomponent/zoo-admin-component demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers 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
Two npm packages masquerading as WhatsApp developer libraries include a kill switch that deletes all files if the phone number isn’t whitelisted.
Research
/Security News
Socket uncovered 11 malicious Go packages using obfuscated loaders to fetch and execute second-stage payloads via C2 domains.
Security News
TC39 advances 11 JavaScript proposals, with two moving to Stage 4, bringing better math, binary APIs, and more features one step closer to the ECMAScript spec.