Project

General

Profile

Actions

Bug #20142

open

Invalid metadata (section with empty name) generated by the technique editor

Added by Félix DALLIDET 10 months ago. Updated 24 days ago.

Status:
New
Priority:
N/A
Assignee:
-
Category:
Web - Technique editor
Target version:
Severity:
Critical - prevents main use of Rudder | no workaround | data loss | security
UX impact:
User visibility:
Operational - other Techniques | Rudder settings | Plugins
Effort required:
Priority:
66
Regression:

Description

While working on the CIS technique for rhel7 in rudder language, I ended up with a broken metadata.xml, resulting in a broken technique.
No errors where detected or thrown by the technique editor, but my technique does not appear in the directive webapp page nor in the technique tree.
The webapp logs are raising the following errors:

[2021-10-11 14:13:22+0000] ERROR application - An error occurred when compiling technique 'My technique name' (id : 'BundleName(CIS_rhel7_setup_filesystem)') with rudderc, error details in /var/log/rudder/rudderc/failures/2021-10-11T14:13:22.704Z_CIS_rhel7_setup_filesystem.log, falling back to old saving process
[2021-10-11 14:13:23+0000] ERROR techniques.reader - Error with technique at path: '/ncf_techniques/CIS_rhel7_setup_filesystem/1.0/metadata.xml', it will be ignored. Error: Chained: Couldn't parse Section in CIS_rhel7_setup_filesystem/1.0 -> My technique name for XML: <SECTION reporting="sum" name="Initial Setup" multivalued="true" component="true">
      <SECTION reporting="sum" name="Additional Process Hardening" multivalued="true" component="true">
        <SECTION reporting="sum" name="Ensure XD/NX support is enabled" multivalued="true" component="true">
          <SECTION name="Condition from command" multivalued="true" component="true">
            <REPORTKEYS>
              <VALUE>xd_nx_support_enabled</VALUE>
            </REPORTKEYS>
          </SECTION>
          <SECTION name="Report if condition" multivalued="true" component="true">
            <REPORTKEYS>
              <VALUE>Ensure core dumps are restricted</VALUE>

I could not find what the issue was, the xml seems correct (xmllint accepts it).
The metadata.xml is pretty big, and is attached in the ticket. There are two issues here:
  • The technique should not be saved and failing silently in the technique editor if the metadata.xml is incorrect
  • The metadata does not seem to work as intended

Files

metadata.xml (93.4 KB) metadata.xml Félix DALLIDET, 2021-10-18 11:09

Related issues 1 (1 open0 closed)

Related to Rudder - Bug #19930: We were able to save a technique without a name which caused chaos NewActions
Actions #1

Updated by Vincent MEMBRÉ 10 months ago

  • Target version changed from 7.0.0~beta2 to 7.0.0~beta3
Actions #2

Updated by Vincent MEMBRÉ 9 months ago

  • Target version changed from 7.0.0~beta3 to 7.0.0~rc1
Actions #3

Updated by Vincent MEMBRÉ 9 months ago

  • Target version changed from 7.0.0~rc1 to 7.0.0~rc2
  • Priority changed from 76 to 75
Actions #4

Updated by Vincent MEMBRÉ 8 months ago

  • Target version changed from 7.0.0~rc2 to 7.0.0~rc3
Actions #5

Updated by Vincent MEMBRÉ 7 months ago

  • Target version changed from 7.0.0~rc3 to 7.0.0
  • Priority changed from 75 to 73
Actions #6

Updated by Vincent MEMBRÉ 7 months ago

  • Target version changed from 7.0.0 to 7.0.1
Actions #7

Updated by François ARMAND 6 months ago

  • Priority changed from 73 to 72

The root cause is lower in the error trace:

cause was: Parsing: Section must have name. Missing name for: <SECTION reporting="weighted" name="" multivalued="true" component="true">

So the technique editor missed generation of a name somewhere.

Actions #8

Updated by François ARMAND 6 months ago

  • Subject changed from Invalid metadata generated by the technique editor to Invalid metadata (section with empty name) generated by the technique editor
Actions #9

Updated by François ARMAND 6 months ago

  • Related to Bug #19930: We were able to save a technique without a name which caused chaos added
Actions #10

Updated by Vincent MEMBRÉ 6 months ago

  • Target version changed from 7.0.1 to 7.0.2
Actions #11

Updated by Vincent MEMBRÉ 4 months ago

  • Target version changed from 7.0.2 to 7.0.3
  • Priority changed from 72 to 70
Actions #12

Updated by Vincent MEMBRÉ 3 months ago

  • Target version changed from 7.0.3 to 7.0.4
  • Priority changed from 70 to 69
Actions #13

Updated by Vincent MEMBRÉ about 2 months ago

  • Target version changed from 7.0.4 to 7.0.5
  • Priority changed from 69 to 67
Actions #14

Updated by Vincent MEMBRÉ 24 days ago

  • Target version changed from 7.0.5 to 7.0.6
  • Priority changed from 67 to 66
Actions

Also available in: Atom PDF