[munin/audimat,tv,conficker] modifications mineures

non commitées

darcs-hash:20090226070644-bd074-fb6d9810a8b61b395dda719f78ef2e1fe5a64d83.gz
This commit is contained in:
Antoine Durand-Gasselin 2009-02-26 08:06:44 +01:00
parent 8bb0244c5c
commit 2a1216e9fd
4 changed files with 8 additions and 7 deletions

View file

@ -53,7 +53,7 @@ if 'config' in sys.argv :
chaines.sort() chaines.sort()
for nom in chaines : for nom in chaines :
if not nom : continue if not nom : continue
nom1 = nom.replace(' ','_') nom1 = nom.replace(' ','_').replace("'", '')
print "%s.label %s" % (nom1, nom) print "%s.label %s" % (nom1, nom)
if inc == 0 : if inc == 0 :
print "%s.draw AREA" % nom1 print "%s.draw AREA" % nom1

View file

@ -1,7 +1,7 @@
#!/bin/bash #!/bin/bash
# Script de détection des machines infectées par Conficker # Script de détection des machines infectées par Conficker
# Copyright (c) 2008 Michel Blockelet <blockelet@crans.org> # Copyright (c) 2009 Michel Blockelet <blockelet@crans.org>
# This program is free software; you can redistribute it and/or modify # This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by # it under the terms of the GNU General Public License as published by

View file

@ -83,7 +83,7 @@ except :
cartes = range(6) cartes = range(6)
if verbose > 2 : if verbose > 2 :
print "Mode debug non permis avec le lancement automatique" print "Mode debug non permis avec le lancement automatique"
verbose = 2 verbose = 3
if args[0] in ( 'start', 'restart' ) : if args[0] in ( 'start', 'restart' ) :
if cartes == range(6) : if cartes == range(6) :

View file

@ -67,10 +67,12 @@ def vignettes() :
chaines_sap = open('/tmp/chaines_recup_sap.txt','r').readlines() chaines_sap = open('/tmp/chaines_recup_sap.txt','r').readlines()
chaines_sap_sort = open('%s/chaines_recup_sap_triees.txt' % tmp_dir, 'w' ) chaines_sap_sort = open('%s/chaines_recup_sap_triees.txt' % tmp_dir, 'w' )
chaines_sap.sort() chaines_sap.sort()
for line in chaines_sap :
chaines_sap_sort.write(line.replace('\'',''))
chaines_sap_sort.close()
for line in chaines_sap : for line in chaines_sap :
chaines_sap_sort.write(line)
line = line.strip() line = line.strip()
nom = line.split(':')[0] nom = line.split(':')[0]
ip = line.split(':')[-1] ip = line.split(':')[-1]
@ -163,9 +165,8 @@ def vignettes() :
html.close() html.close()
html_petites.write(trame_piedpage) html_petites.write(trame_piedpage)
html_petites.close() html_petites.close()
shutil.move('%s/vignettes.html' % (tmp_dir),'%s/vignettes.html' % (www_dir)) shutil.copy('%s/vignettes.html' % tmp_dir,'%s/vignettes.html' % www_dir)
shutil.move('%s/vignettes_petites.html' % (tmp_dir),'%s/vignettes_petites.html' % (www_dir)) shutil.copy('%s/vignettes_petites.html' % tmp_dir,'%s/vignettes_petites.html' % www_dir)
chaines_sap_sort.close()
if __name__ == '__main__' : if __name__ == '__main__' :