summaryrefslogtreecommitdiffstats
path: root/src/go/collectors/go.d.plugin/modules/dnsquery/config_schema.json
blob: cfa6f3a147e21d240b0698bbdd20562551bbd583 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
{
  "jsonSchema": {
    "$schema": "http://json-schema.org/draft-07/schema#",
    "title": "DNS query collector configuration.",
    "type": "object",
    "properties": {
      "update_every": {
        "title": "Update every",
        "description": "Data collection interval, measured in seconds.",
        "type": "integer",
        "minimum": 1,
        "default": 5
      },
      "timeout": {
        "title": "Timeout",
        "description": "Timeout for DNS queries, in seconds.",
        "type": "number",
        "default": 2
      },
      "network": {
        "title": "Protocol",
        "description": "Network protocol for DNS queries.",
        "type": "string",
        "enum": [
          "udp",
          "tcp",
          "tcp-tls"
        ],
        "default": "udp"
      },
      "port": {
        "title": "Port",
        "description": "Port number for DNS servers.",
        "type": "integer",
        "default": 53
      },
      "record_types": {
        "title": "Record types",
        "description": "Types of DNS records to query for each server.",
        "type": [
          "array",
          "null"
        ],
        "items": {
          "type": "string",
          "enum": [
            "A",
            "AAAA",
            "ANY",
            "CNAME",
            "MX",
            "NS",
            "PTR",
            "SOA",
            "SPF",
            "SRV",
            "TXT"
          ],
          "default": "A"
        },
        "default": [
          "A"
        ],
        "uniqueItems": true
      },
      "servers": {
        "title": "Servers",
        "description": "List of DNS servers to query.",
        "type": [
          "array",
          "null"
        ],
        "items": {
          "title": "DNS server",
          "description": "IP address or hostname of the DNS server.",
          "type": "string"
        },
        "default": [
          "8.8.8.8"
        ],
        "uniqueItems": true,
        "minItems": 1
      },
      "domains": {
        "title": "Domains",
        "description": "List of domains or subdomains to query. A random domain will be selected from this list at each iteration.",
        "type": [
          "array",
          "null"
        ],
        "items": {
          "title": "Domain",
          "type": "string"
        },
        "default": [
          "google.com",
          "github.com"
        ],
        "uniqueItems": true,
        "minItems": 1
      }
    },
    "required": [
      "domains",
      "servers",
      "network"
    ],
    "additionalProperties": false,
    "patternProperties": {
      "^name$": {}
    }
  },
  "uiSchema": {
    "uiOptions": {
      "fullPage": true
    },
    "timeout": {
      "ui:help": "Accepts decimals for precise control (e.g., type 1.5 for 1.5 seconds)."
    },
    "network": {
      "ui:widget": "radio",
      "ui:options": {
        "inline": true
      }
    },
    "servers": {
      "ui:listFlavour": "list"
    },
    "domains": {
      "ui:listFlavour": "list"
    }
  }
}