
Security News
/Research
Wallet-Draining npm Package Impersonates Nodemailer to Hijack Crypto Transactions
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
auto-deployment
Advanced tools
运行于nodejs环境的自动化部署插件,在gitee配置webhook后,push项目即可自动部署至服务器。
npm init
npm install auto-deployment
然后在目录中新建一个js文件写入以下内容
const deployment = require('auto-deployment');
deployment({
port:7777,
method:'POST',
url:'/webhook',
acceptToken:'Your token',
userAgnet:"git-oschina-hook",
cmd:[
'ping baidu.com',
'git -C f://phpcrm pull',
]
});
之后运行这个js
node yourjs.js
如果运行成功,控制台将会打印出成功的结果
设置好后保存,会请求一次,返回200就是配置好了
以上必须用ssh登陆服务器并运行yourjs.js才可以实现自动部署,你也可以将此命令加入到开机脚本中,让服务器自动启用服务,实现100%自动部署,如何修修改开机脚本请自行百度。
属性名 | 说明 | 类型 | 必填 | 可选值 |
---|---|---|---|---|
port | 端口 | Number | 是 | - |
method | 请求方法 | string | 是 | POST/GET |
url | 链接 | string | 是 | '/' |
acceptToken | 认证token | string | 是 | - |
userAgnet | ua | string | 是 | - |
type | 执行命令或脚本文件 | string | 是 | command/file |
executeFile | 执行脚本文件的全路径 | string | type='file'时必填 | - |
cmd | 要执行的命令 | arr | type='command'时必填 | [] |
async | 同步/异步(同步将在命令执行完毕后返回执行结果,异步直接返回成功) | Boole | 是 | true/false |
1.0.3
FAQs
auto deployment
We found that auto-deployment 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.
Security News
/Research
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
Security News
/Research
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.