[ Avaa Bypassed ]




Upload:

Command:

www-data@13.58.67.129: ~ $
# secrets-lib.pl
# Common functions for editing a PPP users file

# list_secrets()
sub list_secrets
{
local(@rv, $line, $_);
open(SEC, "<".$config{'pap_file'});
$line = 0;
while(<SEC>) {
	chop;
	s/^#.*$//g;
	@w = &split_words($_);
	if (@w >= 3) {
		local(%sec, @ips);
		$sec{'client'} = $w[0];
		$sec{'server'} = $w[1];
		$sec{'secret'} = $w[2];
		@ips = @w[3..$#w];
		$sec{'ips'} = \@ips;
		$sec{'line'} = $line;
		$sec{'index'} = scalar(@rv);
		push(@rv, \%sec);
		}
	$line++;
	}
close(SEC);
return @rv;
}

# create_secret(&secret)
sub create_secret
{
&open_tempfile(SEC, ">>$config{'pap_file'}");
&print_tempfile(SEC, &join_words($_[0]->{'client'}, $_[0]->{'server'},
		      $_[0]->{'secret'}, @{$_[0]->{'ips'}}),"\n");
&close_tempfile(SEC);
}

# change_secret(&secret)
sub change_secret
{
&replace_file_line($config{'pap_file'}, $_[0]->{'line'},
		   &join_words($_[0]->{'client'}, $_[0]->{'server'},
			       $_[0]->{'secret'}, @{$_[0]->{'ips'}})."\n");
}

# delete_secret(&secret)
sub delete_secret
{
&replace_file_line($config{'pap_file'}, $_[0]->{'line'});
}

# split_words(string)
sub split_words
{
local($s, @w);
$s = $_[0];
while($s =~ /^\s*([^"\s]+|"([^"]*)")(.*)$/) {
	push(@w, defined($2) ? $2 : $1);
	$s = $3;
	}
return @w;
}

sub join_words
{
local(@w, $w);
foreach $w (@_) {
	if ($w =~ /^[a-zA-Z0-9\.\-]+$/) { push(@w, $w); }
	else { push(@w, "\"$w\""); }
	}
return join("  ", @w);
}

# opt_crypt(password)
# Returns the given password, crypted if the user has configured it
sub opt_crypt
{
if ($config{'encrypt_pass'}) {
	local($salt);
	srand(time());
	$salt = chr(int(rand(26))+65).chr(int(rand(26))+65);
	return &unix_crypt($_[0], $salt);
	}
return $_[0];
}



Filemanager

Name Type Size Permission Actions
help Folder 0755
images Folder 0755
lang Folder 0755
CHANGELOG File 118 B 0644
adsl-client-lib.pl File 1.8 KB 0755
backup_config.pl File 922 B 0755
bootup.cgi File 382 B 0755
config File 153 B 0644
config-coherent-linux File 175 B 0644
config-openmamba-linux File 175 B 0644
config-redhat-linux-7.2-ALL File 175 B 0644
config-syno-linux File 153 B 0644
config-trustix-linux File 177 B 0644
config.info File 382 B 0644
config.info.ar File 0 B 0644
config.info.bg File 597 B 0644
config.info.ca File 426 B 0644
config.info.de File 376 B 0644
config.info.es File 420 B 0644
config.info.fr File 445 B 0644
config.info.hr File 0 B 0644
config.info.it File 443 B 0644
config.info.ja File 404 B 0644
config.info.ms File 386 B 0644
config.info.nl File 421 B 0644
config.info.no File 395 B 0644
config.info.pl File 416 B 0644
config.info.pt_BR File 448 B 0644
config.info.sv File 0 B 0644
config.info.tr File 408 B 0644
config.info.zh_TW File 303 B 0644
ifcfg-ppp File 347 B 0644
index.cgi File 6.66 KB 0755
install_check.pl File 421 B 0755
log_parser.pl File 336 B 0755
module.info File 147 B 0644
module.info.af File 0 B 0644
module.info.af.auto File 94 B 0644
module.info.ar File 27 B 0644
module.info.ar.auto File 92 B 0644
module.info.be File 0 B 0644
module.info.be.auto File 134 B 0644
module.info.bg File 26 B 0644
module.info.bg.auto File 87 B 0644
module.info.ca File 80 B 0644
module.info.ca.auto File 13 B 0644
module.info.cs File 20 B 0644
module.info.cs.auto File 74 B 0644
module.info.da File 0 B 0644
module.info.da.auto File 86 B 0644
module.info.de File 83 B 0644
module.info.de.auto File 13 B 0644
module.info.el File 0 B 0644
module.info.el.auto File 144 B 0644
module.info.es File 21 B 0644
module.info.es.auto File 75 B 0644
module.info.eu File 0 B 0644
module.info.eu.auto File 91 B 0644
module.info.fa File 0 B 0644
module.info.fa.auto File 118 B 0644
module.info.fi File 0 B 0644
module.info.fi.auto File 90 B 0644
module.info.fr File 0 B 0644
module.info.fr.auto File 96 B 0644
module.info.he File 0 B 0644
module.info.he.auto File 105 B 0644
module.info.hr File 0 B 0644
module.info.hr.auto File 92 B 0644
module.info.hu File 0 B 0644
module.info.hu.auto File 96 B 0644
module.info.it File 20 B 0644
module.info.it.auto File 78 B 0644
module.info.ja File 32 B 0644
module.info.ja.auto File 118 B 0644
module.info.ko File 0 B 0644
module.info.ko.auto File 132 B 0644
module.info.lt File 0 B 0644
module.info.lt.auto File 102 B 0644
module.info.lv File 0 B 0644
module.info.lv.auto File 88 B 0644
module.info.ms File 73 B 0644
module.info.ms.auto File 13 B 0644
module.info.mt File 0 B 0644
module.info.mt.auto File 88 B 0644
module.info.nl File 20 B 0644
module.info.nl.auto File 73 B 0644
module.info.no File 20 B 0644
module.info.no.auto File 69 B 0644
module.info.pl File 81 B 0644
module.info.pl.auto File 13 B 0644
module.info.pt File 0 B 0644
module.info.pt.auto File 94 B 0644
module.info.pt_BR File 24 B 0644
module.info.pt_BR.auto File 79 B 0644
module.info.ro File 0 B 0644
module.info.ro.auto File 94 B 0644
module.info.ru File 0 B 0644
module.info.ru.auto File 115 B 0644
module.info.sk File 0 B 0644
module.info.sk.auto File 92 B 0644
module.info.sl File 0 B 0644
module.info.sl.auto File 90 B 0644
module.info.sv File 0 B 0644
module.info.sv.auto File 91 B 0644
module.info.th File 0 B 0644
module.info.th.auto File 156 B 0644
module.info.tr File 24 B 0644
module.info.tr.auto File 70 B 0644
module.info.uk File 0 B 0644
module.info.uk.auto File 142 B 0644
module.info.ur File 0 B 0644
module.info.ur.auto File 133 B 0644
module.info.vi File 0 B 0644
module.info.vi.auto File 109 B 0644
module.info.zh File 0 B 0644
module.info.zh.auto File 92 B 0644
module.info.zh_TW File 25 B 0644
module.info.zh_TW.auto File 76 B 0644
rbootup.cgi File 429 B 0755
save.cgi File 1.95 KB 0755
secrets-lib.pl File 1.64 KB 0755
setup.cgi File 429 B 0755
start.cgi File 925 B 0755
stop.cgi File 581 B 0755