id: wordpress-popup-builder

info:
  name: Popup Builder – Create highly converting, mobile friendly marketing popups. Detection
  author: ricardomaia
  severity: info
  reference:
    - https://wordpress.org/plugins/popup-builder/
  metadata:
    max-request: 1
    plugin_namespace: popup-builder
    wpscan: https://wpscan.com/plugin/popup-builder
  tags: tech,wordpress,wp-plugin,top-200

http:
  - method: GET
    path:
      - "{{BaseURL}}/wp-content/plugins/popup-builder/readme.txt"

    payloads:
      last_version: helpers/wordpress/plugins/popup-builder.txt

    extractors:
      - type: regex
        part: body
        internal: true
        name: internal_detected_version
        group: 1
        regex:
          - '(?i)Stable.tag:\s?([\w.]+)'

      - type: regex
        part: body
        name: detected_version
        group: 1
        regex:
          - '(?i)Stable.tag:\s?([\w.]+)'

    matchers-condition: or
    matchers:
      - type: dsl
        name: "outdated_version"
        dsl:
          - compare_versions(internal_detected_version, concat("< ", last_version))

      - type: regex
        part: body
        regex:
          - '(?i)Stable.tag:\s?([\w.]+)'
# digest: 4b0a00483046022100dbaa8bae77b7418ad2a3fdfa06dc604e124732e0207b9d05e01f1018b030a29d022100faf2c2391c0e94e3679eb5ff5cc87ba754e6162ab0803b5bf5ac30cd667f5b70:922c64590222798bb761d5b6d8e72950