UNPKG

netshell

Version:

readme

37 lines (32 loc) 696 B
Installation ============= ~~~ npm install --save netshell ~~~ Usage ============= Code use example: ~~~javascript var netsh = require('netshell'); netsh.createRule({ name:'https', dir:'out', action:'block', protocol: 'tcp', remoteport:443 }).then((data) => { console.log(data); // undefined }); netsh.readRule({name:'https'}) .then((data) => { console.log(data); // rule }); netsh.updateRule({name:'https'}, {action:'allow'}) .then((data) => { console.log(data); }); netsh.deleteRule({name:'https'}) .then((data) => { console.log(data); }); ~~~