Skip to content

[BUG] XML entities are not encoded in service files #34

@kbabioch

Description

@kbabioch

firewalld-formular will render the following pillar data into a XML service file:

  services:
    monitoring:
      short: monitoring
      description: >-
        These ports are required for monitoring based on check_mk & NRPE.
      ports:
        tcp:
          - 5665
          - 6556

However it does not encode XML entities (such as & into &, which leads to the service not being loaded into firewalld` and the following error message:

ERROR: Failed to load service file
'/etc/firewalld/services/monitoring.xml': INVALID_SERVICE: not a valid
service file: not well-formed (invalid token): line 9, column 74

Hence, this service will not be loaded and the firewall behaves differently than expected.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions