SQL-Ledger Redirect Function Arbitrary Code Execution Vulnerability

Solution:
The vendor released an updated version of LedgerSMB to address this issue. Please see the references for more information.

The following unofficial patch is available for SQL-Ledger. Symantec has not tested or verified the integrity of this patch. Users are advised to use caution when applying patches from third-party sources.

diff -C3 -r sql-ledger-orig/SL/Form.pm sql-ledger/SL/Form.pm
*** sql-ledger-orig/SL/Form.pm 2007-02-05 18:20:34.000000000 -0800
--- sql-ledger/SL/Form.pm 2007-02-05 18:23:06.000000000 -0800
***************
*** 311,318 ****

if ($self->{callback}) {

! my ($script, $argv) = split(/\?/, $self->{callback});
! exec ("perl", $script, $argv);

} else {

--- 311,327 ----

if ($self->{callback}) {

! my ($script, $argv) = split(/\?/, $self->{callback});
! foreach (qw/admin.pl login.pl am.pl ap.pl ar.pl bp.pl ca.pl
! cp.pl ct.pl menu.pl gl.pl hr.pl ic.pl ir.pl
! is.pl jc.pl oe.pl pe.pl ps.pl rc.pl rp.pl/) {
! if ($_ =~ /(?:custom_)?$script/) {
! exec ("perl", $script, $argv);
! }
! }
! # $script not in whitelist
! $self->error('Access Denied!')
!

} else {



 

Privacy Statement
Copyright 2010, SecurityFocus