Merge branch 'master' of ssh://git.ipfire.org/pub/git/ipfire-2.x

This commit is contained in:
Michael Tremer
2012-02-08 21:47:09 +01:00
52 changed files with 560 additions and 107 deletions

View File

@@ -20,6 +20,7 @@
###############################################################################
use CGI qw(param);
use Crypt::PasswdMD5;
$swroot = "/var/ipfire";
@@ -98,7 +99,10 @@ if ($cgiparams{'SUBMIT'} eq $tr{'advproxy chgwebpwd change password'})
$errormessage = $tr{'advproxy errmsg invalid user'};
goto ERROR;
}
if (!(crypt($cgiparams{'OLD_PASSWORD'}, $cryptpwd) eq $cryptpwd))
if (
!(crypt($cgiparams{'OLD_PASSWORD'}, $cryptpwd) eq $cryptpwd) &&
!(apache_md5_crypt($cgiparams{'OLD_PASSWORD'}, $cryptpwd) eq $cryptpwd)
)
{
$errormessage = $tr{'advproxy errmsg password incorrect'};
goto ERROR;

View File

@@ -67,7 +67,7 @@ if ( $querry[0] =~ "hwtemp"){
print "Content-type: image/png\n\n";
binmode(STDOUT);
&Graphs::updatethermaltempgraph($querry[1]);
}elsif ( $querry[0] =~ "sd?" || $querry[0] =~ "hd?" || $querry[0] =~ "xvd??" ){
}elsif ( $querry[0] =~ "sd?" ){
print "Content-type: image/png\n\n";
binmode(STDOUT);
&Graphs::updatehddgraph($querry[0],$querry[1]);
@@ -93,7 +93,7 @@ if ( $querry[0] =~ "hwtemp"){
&General::writehash("${General::swroot}/sensors/settings", \%sensorsettings);
}
my @disks = `find /sys/block/* -maxdepth 0 ! -name sr* ! -name loop* ! -name ram* -exec basename {} \\; | sort | uniq`;
my @disks = `ls -1 /sys/block | grep -E '^sd' | sort | uniq`;
foreach (@disks){
my $disk = $_;

View File

@@ -45,9 +45,9 @@ my @querry = split(/\?/,$ENV{'QUERY_STRING'});
$querry[0] = '' unless defined $querry[0];
$querry[1] = 'hour' unless defined $querry[1];
my @devices = `find /sys/block/* -maxdepth 0 ! -name sr* ! -name loop* ! -name ram* -exec basename {} \\; | sort | uniq`;
my @devices = `ls -1 /sys/block | grep -E '^sd|^xvd|^vd|^md' | sort | uniq`;
if ( $querry[0] =~ "sd?" || $querry[0] =~ "hd?" || $querry[0] =~ "xvd??"){
if ( $querry[0] =~ "sd?" || $querry[0] =~ "xvd??" || $querry[0] =~ "vd?" || $querry[0] =~ "md*" ){
print "Content-type: image/png\n\n";
binmode(STDOUT);