id: wordpress-loginizer

info:
  name: Loginizer Detection
  author: ricardomaia
  severity: info
  reference:
    - https://wordpress.org/plugins/loginizer/
  metadata:
    plugin_namespace: loginizer
    wpscan: https://wpscan.com/plugin/loginizer
  tags: tech,wordpress,wp-plugin,top-100,top-200

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

    payloads:
      last_version: helpers/wordpress/plugins/loginizer.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: 4a0a00473045022100e5daa4d95dcff71203cda1c83be5d763505eb2870fc52145c6ef31ecff6b30aa02203180ea4cd6f5f097da861a37c888aab23cdd7f4fb917cd2766754b03b24acac4:922c64590222798bb761d5b6d8e72950