-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathprogramer.php
46 lines (35 loc) · 961 Bytes
/
programer.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<?php
/* programer run as www-data user */
if ( ! is_readable('conf.inc.php') ) {
die('conf.inc.php no encontrado');
}
include('conf.inc.php');
include('modules/common.inc.php');
$now=strftime("%d/%m/%Y %H:%M:%S");
class GUI {
function info($txt) {
global $now;
if($txt == '') return;
fwrite(STDERR, "[$now]: ".print_r($txt, true)." \n");
}
function debug($txt) {
if($txt == '') return;
if (DEBUG)
fwrite(STDERR, "D: ".print_r($txt, true)." \n");
}
function debuga($txt) {
$this->debug($txt);
}
function session_info($txt) {
$this->info("SESSION INFO: ".$txt);
}
function session_error($txt) {
$this->debug("SESSION ERROR:".$txt);
}
}
$gui = new GUI();
include("classes/ldap.class.php");
include("classes/programer.class.php");
include('classes/winexe.class.php');
$cronprogramer = new CronProgramer();
$cronprogramer->doJobs();