-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
swagger.yml
349 lines (348 loc) · 11.8 KB
/
swagger.yml
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
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
swagger: "2.0"
# ---- INFO ----
info:
title: "Misterchef"
description: "Misterchef API Documentation"
version: "1.0.0"
contact:
name: "Kike Fontán (@CosasDePuma)"
url: "kike.wtf"
email: "[email protected]"
# ---- CONF ----
basePath: "/api/v1"
consumes: ["application/json"]
produces: ["application/json"]
# ---- TAGS ----
tags:
- name: "WTF?"
description: "Weird stuff..."
- name: "Basic"
description: "operations"
- name: "Lookup"
description: "operations"
- name: "Stealth enumeration"
description: "using OSINT tools"
# ---- PATH ----
paths:
# Basic
"/request":
post:
tags: ["Basic"]
summary: "HTTP Request"
description: "**Performs an HTTP request against the specified URL.**\n\nDefault headers:\n- **Connection**: close\n- **Accept-Enconding**: gzip"
parameters:
- in: "header"
name: "X-Powered-By"
required: true
schema:
type: "string"
example: "Misterchef!"
- in: "body"
name: "urls"
description: "Target url(s)"
required: true
schema:
$ref: "#/definitions/urls"
- in: "body"
name: "method"
description: "HTTP Method"
schema:
$ref: "#/definitions/method"
- in: "body"
name: "proxy"
description: "Custom proxy"
schema:
$ref: "#/definitions/proxy"
- in: "body"
name: "headers"
description: "Custom headers"
schema:
$ref: "#/definitions/headers"
responses:
200:
description: "OK"
schema:
type: "object"
properties:
urls:
description: "Requested urls"
$ref: "#/definitions/urls"
responses:
type: "array"
description: "Responses"
items:
type: "object"
properties:
url:
type: "string"
example: "http:https://example.com"
status:
type: "integer"
description: "Response status code"
example: 200
length:
type: "integer"
description: "Response length"
example: 648
headers:
type: "object"
description: "Response headers"
example: "{\"Accept-Ranges\":\"bytes\",\"Age\":\"187604\",\"Cache-Control\":\"max-age=604800\",\"Content-Encoding\":\"gzip\",\"Content-Length\":\"648\",\"Content-Type\":\"text/html; charset=UTF-8\",\"Date\":\"Sat, 05 Jun 2021 17:53:19 GMT\",\"Etag\":\"\\\"3147526947\\\"\",\"Expires\":\"Sat, 12 Jun 2021 17:53:19 GMT\",\"Last-Modified\":\"Thu, 17 Oct 2019 07:18:26 GMT\",\"Server\":\"ECS (dcb/7ECA)\",\"Vary\":\"Accept-Encoding\",\"X-Cache\":\"HIT\"}"
body:
type: "string"
description: "Body encoded in base64"
example: "PCFkb2N0eXBlIGh0bWw+CjxodG1sPgo8aGVhZD4KICAgIDx0aXRsZT5FeGFtcGxlIERvbWFpbjwvdGl0bGU+CgogICAgPG1ldGEgY2hhcnNldD0idXRmLTgiIC8+CiAgICA8bWV0YSBodHRwLWVxdWl2PSJDb250ZW50LXR5cGUiIGNvbnRlbnQ9InRleHQvaHRtbDsgY2hhcnNldD11dGY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haW4gaXMgZm9yIHVzZSBpbiBpbGx1c3RyYXRpdmUgZXhhbXBsZXMgaW4gZG9jdW1lbnRzLiBZb3UgbWF5IHVzZSB0aGlzCiAgICBkb21haW4gaW4gbGl0ZXJhdHVyZSB3aXRob3V0IHByaW9yIGNvb3JkaW5hdGlvbiBvciBhc2tpbmcgZm9yIHBlcm1pc3Npb24uPC9wPgogICAgPHA+PGEgaHJlZj0iaHR0cHM6Ly93d3cuaWFuYS5vcmcvZG9tYWlucy9leGFtcGxlIj5Nb3JlIGluZm9ybWF0aW9uLi4uPC9hPjwvcD4KPC9kaXY+CjwvYm9keT4KPC9odG1sPgo="
warnings:
type: "array"
items:
type: "string"
example: []
406:
description: "No required arguments"
# Lookup
"/lookup/dns":
post:
tags: ["Lookup"]
summary: "Reverse DNS lookup"
description: "**Gets DNS from IP addresses**"
parameters:
- in: "header"
name: "X-Powered-By"
required: true
schema:
type: "string"
example: "Misterchef!"
- in: "body"
name: "ips"
description: "Target IPs"
required: true
schema:
$ref: "#/definitions/ips"
responses:
200:
description: "OK"
schema:
type: "object"
properties:
ips:
description: "Target IPs"
$ref: "#/definitions/ips"
domains:
type: "array"
items:
type: "string"
description: "Related domains"
example:
- "dns.google"
warnings:
type: "array"
items:
type: "string"
example: []
406:
description: "No arguments or bad provider"
"/lookup/ip":
post:
tags: ["Lookup"]
summary: "IP lookup"
description: "**Gets IPs from domains**"
parameters:
- in: "header"
name: "X-Powered-By"
required: true
schema:
type: "string"
example: "Misterchef!"
- in: "body"
name: "domains"
description: "Target domains"
required: true
schema:
$ref: "#/definitions/domains"
- in: "body"
name: "onlyv4"
description: "Only returns IPv4"
schema:
type: "boolean"
example: true
responses:
200:
description: "OK"
schema:
type: "object"
properties:
domains:
description: "Target domains"
$ref: "#/definitions/domains"
ips:
type: "array"
items:
type: "string"
description: "Related IPs"
example:
- "93.184.216.34"
warnings:
type: "array"
items:
type: "string"
example: []
406:
description: "No arguments or bad provider"
# Stealth Enumeration
"/stealth/spider":
post:
tags: ["Stealth enumeration"]
summary: "Finds links for the specified domain"
description: "**Finds links for the specified domain, using public APIs**\n\nThis method does not log activity in the target domain, but depends on the availability of the used API."
parameters:
- in: "header"
name: "X-Powered-By"
required: true
schema:
type: "string"
example: "Misterchef!"
- in: "body"
name: "domains"
description: "Target domains"
required: true
schema:
$ref: "#/definitions/domains"
- in: "body"
name: "provider"
description: "Public API"
required: true
schema:
type: string
example: "alienvault"
- in: "body"
name: "includeSubdomains"
description: "Include the domain and its subdomains"
schema:
type: "boolean"
example: true
responses:
200:
description: "OK"
schema:
type: "object"
properties:
domains:
description: "Target domains"
$ref: "#/definitions/domains"
links:
type: "array"
items:
type: "string"
description: "Related links"
example:
- "http:https://example.com:80/"
- "http:https://example.com:80/!"
- "http:https://www.example.com:80/!!"
- "http:https://www.example.com:80/!/product"
- "..."
warnings:
type: "array"
items:
type: "string"
example: []
406:
description: "No arguments or bad provider"
"/stealth/subdomainer":
post:
tags: ["Stealth enumeration"]
summary: "Finds subdomains for the specified domain"
description: "**Finds subdomains for the specified domain, using public APIs**\n\nThis method does not log activity in the target domain, but depends on the availability of the used API."
parameters:
- in: "header"
name: "X-Powered-By"
required: true
schema:
type: "string"
example: "Misterchef!"
- in: "body"
name: "domains"
description: "Target domains"
required: true
schema:
$ref: "#/definitions/domains"
- in: "body"
name: "provider"
description: "Public API"
required: true
schema:
type: string
example: "hackertarget"
responses:
200:
description: "OK"
schema:
type: "object"
properties:
domain:
type: "string"
description: "Target domain"
example: "example.com"
subdomains:
type: "array"
items:
type: "string"
description: "Related subdomains"
example:
- "example.com"
- "www.example.com"
warnings:
type: "array"
items:
type: "string"
example: []
406:
description: "No arguments or bad provider"
# WTF?
"/dummy":
post:
tags: ["WTF?"]
summary: "Useless endpoint"
description: "**Shows some random messages and jokes.**"
produces: ["plain/text"]
parameters:
- in: "header"
name: "X-Powered-By"
required: true
schema:
type: "string"
example: "Misterchef!"
responses:
418:
description: "I'm a teapot!"
schema:
type: string
example: "I was eavesdropping on two indian chefs talking...\nIt was a dhal conversation"
# ---- DEFS ----
definitions:
domains:
type: "array"
items:
type: "string"
example:
- "example.com"
urls:
type: "array"
items:
type: string
example:
- "http:https://example.com"
ips:
type: "array"
items:
type: string
example:
- "8.8.8.8"
method:
type: "string"
example: "GET"
headers:
type: "object"
example: '{"User-Agent": "Misterchof!"}'
proxy:
type: "string"
example: "http:https://localhost:8080/"