Author: danydb
Date: 2011-12-11 23:15:10 +0100 (Sun, 11 Dec 2011)
New Revision: 4599
Modified:
phpcompta/trunk/include/compta_ach.inc.php
phpcompta/trunk/include/compta_fin.inc.php
phpcompta/trunk/include/compta_ven.inc.php
Log:
Security ; bug can't access VEN & ACH when global admin
Modified: phpcompta/trunk/include/compta_ach.inc.php
===================================================================
--- phpcompta/trunk/include/compta_ach.inc.php 2011-12-11 20:54:08 UTC (rev
4598)
+++ phpcompta/trunk/include/compta_ach.inc.php 2011-12-11 22:15:10 UTC (rev
4599)
@@ -164,7 +164,7 @@
if (!isset($_REQUEST ['p_jrn']))
{
$def_ledger = $Ledger->get_first('ach',2);
- if ( empty ($first_ledger))
+ if ( empty ($def_ledger))
{
exit('Pas de journal disponible');
}
Modified: phpcompta/trunk/include/compta_fin.inc.php
===================================================================
--- phpcompta/trunk/include/compta_fin.inc.php 2011-12-11 20:54:08 UTC (rev
4598)
+++ phpcompta/trunk/include/compta_fin.inc.php 2011-12-11 22:15:10 UTC (rev
4599)
@@ -44,6 +44,10 @@
else
{
$def_ledger=$Ledger->get_first('fin');
+ if ( empty ($def_ledger))
+ {
+ exit('Pas de journal disponible');
+ }
$Ledger->id=$def_ledger['jrn_def_id'];
}
$jrn_priv=$g_user->get_ledger_access($Ledger->id);
Modified: phpcompta/trunk/include/compta_ven.inc.php
===================================================================
--- phpcompta/trunk/include/compta_ven.inc.php 2011-12-11 20:54:08 UTC (rev
4598)
+++ phpcompta/trunk/include/compta_ven.inc.php 2011-12-11 22:15:10 UTC (rev
4599)
@@ -183,7 +183,7 @@
if ( !isset($_REQUEST ['p_jrn']) )
{
$def_ledger=$Ledger->get_first('ven',2);
- if (empty($first_ledger))
+ if (empty($def_ledger))
{
exit('Pas de journal disponible');
}
_______________________________________________
Phpcompta-dev mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/phpcompta-dev