Security News
The Dark Side of Open Source
At Node Congress, Socket CEO Feross Aboukhadijeh uncovers the darker aspects of open source, where applications that rely heavily on third-party dependencies can be exploited in supply chain attacks.
wireguard-wrapper
Advanced tools
Readme
This project is a nodejs wrapper for the wireguard commands wg
and wg-quick
.
Features:
Limitations:
wg set
, wg setconf
, wg addconf
, wg syncconf
npm i --save wireguard-wrapper
wg
or wg show
const { Wg } = require('wireguard-wrapper');
Wg.show().then(function(interfaces){
console.log('all interfaces:', interfaces);
});
Wg.show('wg0').then(function(interfaces){
console.log('wg0:', interfaces);
});
wg showconf
const { Wg } = require('wireguard-wrapper');
Wg.showconf('wg0').then(function(config){
console.log('wg0 configuration:', config);
console.log('generated configuration file:', config.toString());
});
wg genkey
const { Wg } = require('wireguard-wrapper');
Wg.genkey().then(function(key){
console.log('private key:', key);
});
wg genpsk
const { Wg } = require('wireguard-wrapper');
Wg.genpsk().then(function(psk){
console.log('preshared key:', psk);
});
wg pubkey
const { Wg } = require('wireguard-wrapper');
Wg.genkey().then(function(privateKey){
console.log('private key:', privateKey);
Wg.pubkey(privateKey).then(function(publicKey){
console.log('public key:', publicKey);
});
});
Commands:
Wg.show([string device])
- Returns an Statistics-Interface-Object with the current status.
The parameter is optionalWg.showconf(string device)
- Returns an Config-Interface-Object with the current configuration.
The parameter is required.Wg.genkey()
- Generates a new private key.Wg.genpsk()
- Generates a new preshared key.Wg.pubkey(string privateKey)
- Generates a public key from the given private Key.
The paramter is required.FAQs
A wrapper for the commands wg and wg-quick
The npm package wireguard-wrapper receives a total of 22 weekly downloads. As such, wireguard-wrapper popularity was classified as not popular.
We found that wireguard-wrapper 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
At Node Congress, Socket CEO Feross Aboukhadijeh uncovers the darker aspects of open source, where applications that rely heavily on third-party dependencies can be exploited in supply chain attacks.
Research
Security News
The Socket Research team found this npm package includes code for collecting sensitive developer information, including your operating system username, Git username, and Git email.
Security News
OpenJS is warning of social engineering takeovers targeting open source projects after receiving a credible attempt on the foundation.