Revision 8ef154dd
[#1638] Echappement noms d'interfaces/partitions
La recherche des partitions/interfaces se fait par expression régulière
dans GLPI. Il faut donc échapper les méta-caractères susceptibles
d'interférer et présents dans les noms d'interfaces/partitions.
Change-Id: Iba22348ca9baeb9ab115bd85e2866957a668194f
Refs: #1638
Reviewed-on: https://vigilo-dev.si.c-s.fr/review/2574
Tested-by: Build system <qa@vigilo-dev.si.c-s.fr>
Reviewed-by: Yves OUATTARA <yves.ouattara@c-s.fr>
Reviewed-by: Francois POIROTTE <francois.poirotte@c-s.fr>
src/plugins/vigilo/inc/monitoredcomputer.class.php | ||
---|---|---|
70 | 70 |
$this->children[] = |
71 | 71 |
$test = new VigiloTest('Partition'); |
72 | 72 |
$test['label'] = $disk->getName(); |
73 |
$test['partname'] = $disk->fields['mountpoint'];
|
|
73 |
$test['partname'] = self::escapeRegex($disk->fields['mountpoint']);
|
|
74 | 74 |
if (!empty($total)) { |
75 | 75 |
$test[] = new VigiloArg('max', $total * 1024 * 1024); |
76 | 76 |
} |
Also available in: Unified diff