WGmeta::Wrapper::Bridge - Interface with shell using IPC::Open3
Runs the wg genkey command and returns a private and the corresponding public-key
wg genkey
Returns
Two strings: private-key and public-key
Runs wg pubkey on $priv_key.
wg pubkey
$priv_key
Parameters
$priv_key A valid private key
A string containing the derived publickey.
Runs wg show dump and captures the output into str_out and str_err.
wg show dump
Raises
Please refer to "run_external($command_line [, $input, $soft_fail])"
First array of STD_OUT
Runs an external program and throws an exception (or a warning if $soft_fail is true) if the return code is != 0
$soft_fail
$command_line Complete commandline for the external program to execute.
$command_line
[$input = undef] If defined, this is feed into STD_IN of $command_line.
[$input = undef]
[$soft_fail = FALSE] If set to true, a warning is thrown instead of an exception
[$soft_fail = FALSE]
Exception if return code is not 0 (if $soft_fail is set to true, just a warning)
Returns two lists with all lines of STDout and STDerr
To install Wireguard::WGmeta, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Wireguard::WGmeta
CPAN shell
perl -MCPAN -e shell install Wireguard::WGmeta
For more information on module installation, please visit the detailed CPAN module installation guide.