Update to use the JSON extractor for nextcloud-owncloud-detect.yaml (#8719)
* Update to use the JSON extractor * fix regex * word matcher + json extractor --------- Co-authored-by: Dhiyaneshwaran <leedhiyanesh@gmail.com> Co-authored-by: sandeep <8293321+ehsandeep@users.noreply.github.com>patch-1
parent
f24a093cca
commit
92b97e17b5
|
@ -2,7 +2,7 @@ id: owncloud-status-page
|
|||
|
||||
info:
|
||||
name: Owncloud StatusPage detection
|
||||
author: myztique
|
||||
author: myztique,invisiblethreat
|
||||
severity: info
|
||||
metadata:
|
||||
verified: true
|
||||
|
@ -16,17 +16,15 @@ http:
|
|||
- "{{BaseURL}}/status.php"
|
||||
|
||||
matchers:
|
||||
- type: regex
|
||||
- type: word
|
||||
part: body
|
||||
regex:
|
||||
- '{"installed":(?:true|false),"maintenance":(?:true|false),"version":"[0-9\.]*","versionstring":"[a-z-A-Z0-9\.]*","edition":"[\d\D]*"}'
|
||||
words:
|
||||
- '"versionstring":'
|
||||
- '"installed":'
|
||||
- '"edition":'
|
||||
condition: and
|
||||
|
||||
extractors:
|
||||
- type: regex
|
||||
part: body
|
||||
name: version
|
||||
group: 1
|
||||
regex:
|
||||
- '{[\d\D]*"version":"([0-9\.]+)"'
|
||||
|
||||
# digest: 4a0a00473045022100f3414071ecfd36084121e102dde43f6816d4f5bf9af4653cab8e3f50914aa7d4022002503f4e4f126a0581b1d1731362eaf5b67e9aace6301b608d4a2f24f89d4609:922c64590222798bb761d5b6d8e72950
|
||||
- type: json
|
||||
json:
|
||||
- .version
|
||||
|
|
Loading…
Reference in New Issue