id: wordpress-fluent-smtp

info:
  name: FluentSMTP – WP SMTP Plugin with Amazon SES, SendGrid, MailGun, Postmark, Google and Any SMTP Provider Detection
  author: ricardomaia
  severity: info
  reference:
    - https://wordpress.org/plugins/fluent-smtp/
  metadata:
    plugin_namespace: fluent-smtp
    wpscan: https://wpscan.com/plugin/fluent-smtp
  tags: tech,wordpress,wp-plugin,top-200,discovery

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

    payloads:
      last_version: helpers/wordpress/plugins/fluent-smtp.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: 490a0046304402204d85aaa1cac951d77cc047606b4e1849b2ea291983d2773374abc2fe79dfa481022054f229ec2fff0174e66b896123b3571683af86666059b212366b36fcf0cbecef:922c64590222798bb761d5b6d8e72950