Search code examples
javascriptnode.jspm2

How to fix the problem of pm2 using netmask 1.0.6 causing an high level threat


I was working on my project and was using pm2-runtime command for the runtime environment but the problem coming in my terminal while running the command npm i gives 2 level warnings that are

  High            netmask npm package vulnerable to octal input data            

  Package         netmask                                                       
  Patched in      >=2.0.1                                                       

  Dependency of   pm2                                                           

  Path            pm2 > @pm2/agent > proxy-agent > pac-proxy-agent >            
                  pac-resolver > netmask                                        

  More info       https://npmjs.com/advisories/1658                             


  High            netmask npm package vulnerable to octal input data            

  Package         netmask                                                       

  Patched in      >=2.0.1                                                       

  Dependency of   pm2                                                           

  Path            pm2 > @pm2/io > @pm2/agent-node > proxy-agent >               
                  pac-proxy-agent > pac-resolver > netmask                      

  More info       https://npmjs.com/advisories/1658  

I am using this command in the place of npm start can anyone please suggest to me some alternative for the same command

"start": "cross-env NODE_ENV=production pm2-runtime start index.js"


Solution

  • Install latest PM2 version:

    npm install pm2@latest -g
    pm2 update