version 1.99, 2011/11/26 13:05:03
|
version 1.101, 2011/11/30 09:28:38
|
Line 31
|
Line 31
|
*/ |
*/ |
|
|
int |
int |
rplinit(int argc, char *argv[], unsigned char ***resultats, char *rpl_home) |
rplinit(int argc, char *argv[], char *envp[], |
|
unsigned char ***resultats, char *rpl_home) |
{ |
{ |
# include "copyright-conv.h" |
# include "copyright-conv.h" |
# include "licence-conv.h" |
# include "licence-conv.h" |
Line 182 rplinit(int argc, char *argv[], unsigned
|
Line 183 rplinit(int argc, char *argv[], unsigned
|
(*s_etat_processus).erreur_systeme = d_es; |
(*s_etat_processus).erreur_systeme = d_es; |
(*s_etat_processus).erreur_execution = d_ex; |
(*s_etat_processus).erreur_execution = d_ex; |
|
|
|
(*s_etat_processus).argc = argc; |
|
(*s_etat_processus).argv = argv; |
|
(*s_etat_processus).envp = envp; |
|
|
(*s_etat_processus).rpl_home = rpl_home; |
(*s_etat_processus).rpl_home = rpl_home; |
|
|
pthread_mutexattr_init(&attributs_mutex); |
pthread_mutexattr_init(&attributs_mutex); |
Line 3640 informations(struct_processus *s_etat_pr
|
Line 3645 informations(struct_processus *s_etat_pr
|
} |
} |
|
|
|
|
|
logical1 |
|
controle_integrite(struct_processus *s_etat_processus, |
|
unsigned char *executable_candidat, unsigned char *executable) |
|
{ |
|
unsigned char *md5; |
|
unsigned char *sha1; |
|
|
|
if (strcmp(executable, "rplpp") == 0) |
|
{ |
|
md5 = rplpp_md5; |
|
sha1 = rplpp_sha1; |
|
} |
|
else if (strcmp(executable, "rplfile") == 0) |
|
{ |
|
md5 = rplfile_md5; |
|
sha1 = rplfile_sha1; |
|
} |
|
else if (strcmp(executable, "rpliconv") == 0) |
|
{ |
|
md5 = rpliconv_md5; |
|
sha1 = rpliconv_sha1; |
|
} |
|
else if (strcmp(executable, "rplawk") == 0) |
|
{ |
|
md5 = rplawk_md5; |
|
sha1 = rplawk_sha1; |
|
} |
|
else if (strcmp(executable, "rplconvert") == 0) |
|
{ |
|
md5 = rplconvert_md5; |
|
sha1 = rplconvert_sha1; |
|
} |
|
else |
|
{ |
|
return(d_faux); |
|
} |
|
|
|
if (controle(s_etat_processus, executable_candidat, "md5", md5) != d_vrai) |
|
{ |
|
return(d_faux); |
|
} |
|
|
|
if (controle(s_etat_processus, executable_candidat, "sha1", sha1) != d_vrai) |
|
{ |
|
return(d_faux); |
|
} |
|
|
|
return(d_vrai); |
|
} |
|
|
|
|
unsigned char * |
unsigned char * |
date_compilation() |
date_compilation() |
{ |
{ |