mirror of
https://github.com/LOLBAS-Project/LOLBAS
synced 2025-02-05 18:12:17 +01:00
Adding pyKwalify checking
This commit is contained in:
parent
f6761fad95
commit
9955d4ea77
16
.github/workflows/validate-yaml-schema.yml
vendored
Normal file
16
.github/workflows/validate-yaml-schema.yml
vendored
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
name: Validate YAML Schema
|
||||||
|
|
||||||
|
on: [push, pull_request]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: Validate YAML Schema
|
||||||
|
uses: eliezio/action-pykwalify@v0.3
|
||||||
|
with:
|
||||||
|
files: yml/*/*.yml
|
||||||
|
schema: YML-Schema.yml
|
92
YML-Schema.yml
Normal file
92
YML-Schema.yml
Normal file
@ -0,0 +1,92 @@
|
|||||||
|
---
|
||||||
|
type: map
|
||||||
|
mapping:
|
||||||
|
# Id field enhancement possibility commenting out for now
|
||||||
|
# "Id":
|
||||||
|
# type: str
|
||||||
|
# required: yes
|
||||||
|
# pattern: '[a-zA-Z0-9]{8}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{12}'
|
||||||
|
"Name":
|
||||||
|
type: str
|
||||||
|
required: yes
|
||||||
|
"Description":
|
||||||
|
type: str
|
||||||
|
required: yes
|
||||||
|
"Author":
|
||||||
|
type: str
|
||||||
|
required: yes
|
||||||
|
"Created":
|
||||||
|
type: str
|
||||||
|
required: yes
|
||||||
|
"Commands":
|
||||||
|
type: seq
|
||||||
|
sequence:
|
||||||
|
- type: map
|
||||||
|
mapping:
|
||||||
|
"Command":
|
||||||
|
type: str
|
||||||
|
required: yes
|
||||||
|
"Description":
|
||||||
|
type: str
|
||||||
|
required: yes
|
||||||
|
"Usecase":
|
||||||
|
type: str
|
||||||
|
required: yes
|
||||||
|
"Category":
|
||||||
|
type: str
|
||||||
|
required: yes
|
||||||
|
enum: [ADS, AWL Bypass, Compile, Copy, Credentials, Decode, Download, Dump, Encode, Execute, Reconnaissance, UAC Bypass, Upload]
|
||||||
|
"Privileges":
|
||||||
|
type: str
|
||||||
|
required: yes
|
||||||
|
"MitreID":
|
||||||
|
type: str
|
||||||
|
required: yes
|
||||||
|
pattern: 'T[0-9]{4}'
|
||||||
|
"OperatingSystem":
|
||||||
|
type: str
|
||||||
|
required: yes
|
||||||
|
"Full_Path":
|
||||||
|
type: seq
|
||||||
|
required: yes
|
||||||
|
sequence:
|
||||||
|
- type: map
|
||||||
|
mapping:
|
||||||
|
"Path":
|
||||||
|
type: str
|
||||||
|
required: yes
|
||||||
|
"Code_Sample":
|
||||||
|
type: seq
|
||||||
|
required: yes
|
||||||
|
sequence:
|
||||||
|
- type: map
|
||||||
|
mapping:
|
||||||
|
"Code":
|
||||||
|
type: str
|
||||||
|
"Detection":
|
||||||
|
type: seq
|
||||||
|
required: yes
|
||||||
|
sequence:
|
||||||
|
- type: map
|
||||||
|
mapping:
|
||||||
|
"IOC":
|
||||||
|
type: str
|
||||||
|
"Resources":
|
||||||
|
type: seq
|
||||||
|
required: yes
|
||||||
|
sequence:
|
||||||
|
- type: map
|
||||||
|
mapping:
|
||||||
|
"Link":
|
||||||
|
type: str
|
||||||
|
pattern: 'http[s]?://(?:[a-zA-Z]|[0-9]|[$-_@.&+]|[!*\(\),]|(?:%[0-9a-fA-F][0-9a-fA-F]))+'
|
||||||
|
"Acknowledgement":
|
||||||
|
type: seq
|
||||||
|
required: yes
|
||||||
|
sequence:
|
||||||
|
- type: map
|
||||||
|
mapping:
|
||||||
|
"Person":
|
||||||
|
type: str
|
||||||
|
"Handle":
|
||||||
|
type: str
|
Loading…
Reference in New Issue
Block a user