[BACK]Return to VPN.pm CVS log [TXT][DIR] Up to [local] / botnow

File: [local] / botnow / VPN.pm (download)

Revision 1.1, Sat May 15 15:12:32 2021 UTC (2 years, 11 months ago) by bountyht
Branch point for: MAIN

Initial revision

#!/usr/bin/perl

package VPN;

use strict;
use warnings;
use OpenBSD::Pledge;
use OpenBSD::Unveil;

sub init {
}
#	if ($reply =~ /^!vpn (.*) ([-_0-9a-zA-Z]+)$/i) {
#		my $ircnick = $1;
#		my $newnick = $2;
#		if ($staff !~ /$sender/) {
#			return;
#		}
#		my $password = newpass();
#		createvpn($password, $newnick);
#		sendmsg($bot, $sender, "vpn created for $newnick");
#my $msg = <<"EOF";
#Your vpn account has been created! Username: $newnick with password: $password
#Our official support channel is #vpn.  To connect, please follow these instructions: https://ircnow.org/kb/doku.php?id=vpn:vpn .
#EOF
#		sendmsg($bot, $ircnick, $msg);
#	}
#sub createvpn {
#	my ($password, $username) = @_;
#	`doas sh -c 'echo "user '$username' '$password'" >> /etc/iked.conf'`;
#	`doas rcctl reload iked`;
#}

1; # MUST BE LAST STATEMENT IN FILE