intelmq-manager allows the user to fill in a configuration value with a numeric string by enclosing it in quotes, such as "200", and it is submitted correctly. When editing the configuration of the same bot later, the values, including the numeric string, are filled in with the current configuration values. However, this filled in value will not contain the quotes and will subsequently be considered a number. This can cause type errors if a string is expected for this value.
This patch detects numeric strings and adds quotation marks for them ahead of time when editing the configuration in intelmq-manager, preventing "200" from being silently converted to 200 on subsequent edits.
intelmq-manager allows the user to fill in a configuration value with a numeric string by enclosing it in quotes, such as
"200"
, and it is submitted correctly. When editing the configuration of the same bot later, the values, including the numeric string, are filled in with the current configuration values. However, this filled in value will not contain the quotes and will subsequently be considered a number. This can cause type errors if a string is expected for this value.This patch detects numeric strings and adds quotation marks for them ahead of time when editing the configuration in intelmq-manager, preventing
"200"
from being silently converted to200
on subsequent edits.