-
Notifications
You must be signed in to change notification settings - Fork 11
/
ci_automated_tests.py
467 lines (409 loc) · 25.1 KB
/
ci_automated_tests.py
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
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
# Checkpot - Honeypot Checker
# Copyright (C) 2018 Vlad Florea
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, version 3 of the License.
#
# DISCLAIMER: All prerequisites (containers, additional programs, etc.)
# and libraries that might be needed to run this program are property
# of their original authors and carry their own separate licenses that
# you should read to inform yourself about their terms.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# As this software is PROVIDED WITH ABSOLUTELY NO WARRANTY OF ANY KIND,
# YOU USE THIS SOFTWARE AT YOUR OWN RISK!
#
# By using this tool YOU TAKE FULL LEGAL RESPONSIBILITY FOR ANY
# POSSIBLE OUTCOME.
#
# We strongly recommend that you read all the information in the README.md
# file (found in the root folder of this project) and even the
# documentation (which you can find locally in the /docs/ folder or
# at http://checkpot.readthedocs.io/) to make sure you fully
# understand how this tool works and consult all laws that apply
# to your use case.
#
# We strongly suggest that you keep this notice intact for all files.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
# The local copy of the license should be located in the root folder of the app
# in the file gpl-3.0.txt.
#
# You can contact the author and team at any time via the Checkpot official
# GitHub page: https://github.com/honeynet/checkpot or via the Honeynet
# official Slack channel: https://gsoc-slack.honeynet.org/ or
# https://honeynetpublic.slack.com/
#
# You can contact us at any time and with any question, we are here to help!
#
# If you consider any information in this copyright notice might be incorrect,
# outdated, arises any questions, raises any problems, etc. please contact us
# and we will make it our top priority to fix it. We have the deepest respect
# for the work of all authors and for all of our users.
import time
import sys
from termcolor import colored, cprint
from datetime import timedelta
from containers.manager import Manager
from honeypots.honeypot import Honeypot
from tests.test import Test
from tests.test import TestResult
from tests.test_platform import TestPlatform
import argv_parser
from tests import *
manager = Manager(verbose=True, build_info=False)
def honeypot_test(container_name, tests, port_range=None):
"""
Starts a container and runs a list of tests against it.
Compares results with the expected results.
Stops the container.
:param container_name: target container
:param tests: dict of Test objects and expected TestResult pairs
:param port_range: specify a custom port range for scan (e.g '20-100')
:return: boolean representing test pass/failure
"""
test_list = [key for key in tests]
expected_results = [tests[key] for key in tests]
assert all(isinstance(test, Test) for test in test_list)
assert all(isinstance(result, TestResult) for result in expected_results)
manager.start_honeypot(container_name)
time.sleep(10) # TODO wait for container to start, catch some sort of signal
hp = Honeypot(manager.get_honeypot_ip(container_name), scan_os=False, verbose_scan=False)
print(">", colored("Collecting data ...", color="yellow"))
print("> Test", colored(container_name, color="yellow"), "started at:",
colored(time.strftime("%H:%M:%S", time.gmtime()), color="blue"))
start_time = time.time()
if port_range:
hp.scan(port_range)
else:
hp.scan()
print(">", colored("Running tests ...", color="yellow"))
tp = TestPlatform(test_list, hp)
tp.run_tests()
manager.stop_honeypot(container_name)
for i, result in enumerate(tp.results):
tname, treport, tresult, tkarma = result
if expected_results[i] != tresult:
print("Test ", colored(container_name, color="yellow"), "->", colored("FAILED:", color="red"))
print("\ttest:", tname, " -> expected ", expected_results[i], " got ", tresult, " instead!\n", treport)
print("> Test ended at:", colored(time.strftime("%H:%M:%S", time.gmtime()), color="blue"))
end_time = time.time()
print("Elapsed time =", colored(timedelta(seconds=end_time - start_time), color="blue"), "\n")
sys.exit(1) # exit failure
print("Test ", container_name, "->", colored("PASSED", color="green"))
print("> Test ended at:", colored(time.strftime("%H:%M:%S", time.gmtime()), color="blue"))
end_time = time.time()
print("Elapsed time =", colored(timedelta(seconds=end_time - start_time), color="blue"), "\n")
def interface_test():
"""Test argument parsing"""
print("Testing argument parser ...")
# TODO add tests for long options too
parsed = argv_parser.parse(['checkpot.py', '-t', '172.17.0.2', '-O', '-p', '20-100,102'])
expected = {'target': '172.17.0.2', 'scan_os': True, 'scan_level': 5, 'port_range': '20-100,102', 'fast': False,
'brief': False}
if parsed != expected:
print("ERROR: parsed != expected")
sys.exit(1)
parsed = argv_parser.parse(['checkpot.py', '-t', '172.17.0.2', '-p', '20-1000'])
expected = {'target': '172.17.0.2', 'scan_os': False, 'scan_level': 5, 'port_range': '20-1000', 'fast': False,
'brief': False}
if parsed != expected:
print("ERROR: parsed != expected")
sys.exit(1)
parsed = argv_parser.parse(['checkpot.py', '-t', '172.17.0.2', '-O', '-l', '3'])
expected = {'target': '172.17.0.2', 'scan_os': True, 'scan_level': 3, 'port_range': None, 'fast': False,
'brief': False}
if parsed != expected:
print("ERROR: parsed != expected")
sys.exit(1)
parsed = argv_parser.parse(['checkpot.py', '-O', '-t', '172.17.0.2', '-l', '3', '-f'])
expected = {'target': '172.17.0.2', 'scan_os': True, 'scan_level': 3, 'port_range': None, 'fast': True,
'brief': False}
if parsed != expected:
print("ERROR: parsed != expected")
sys.exit(1)
parsed = argv_parser.parse(['checkpot.py', '-O', '-t', '172.17.0.2', '-l', '3'])
expected = {'target': '172.17.0.2', 'scan_os': True, 'scan_level': 3, 'port_range': None, 'fast': False,
'brief': False}
if parsed != expected:
print("ERROR: parsed != expected")
sys.exit(1)
print("OK")
def main():
"""
Entry point for the Continuous Integration tools.
Write all tests here.
"""
print(
"Checkpot - Honeypot Checker, Copyright (C) 2018 Vlad Florea\n"
"This program comes with ABSOLUTELY NO WARRANTY; for details\n"
"run `python checkpot.py --show w`.\n"
"This is free software, and you are welcome to redistribute it\n"
"under certain conditions; run `python checkpot.py --show c` for details.\n"
)
# test amun
honeypot_test('amun',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.WARNING,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.WARNING,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.WARNING,
default_ftp.DefaultFTPBannerTest(): TestResult.WARNING,
service_implementation.HTTPTest(): TestResult.OK,
default_http.DefaultWebsiteTest(): TestResult.WARNING,
default_http.DefaultGlastopfWebsiteTest(): TestResult.OK,
default_http.DefaultStylesheetTest(): TestResult.NOT_APPLICABLE,
default_http.CertificateValidationTest(): TestResult.WARNING,
default_imap.DefaultIMAPBannerTest(): TestResult.WARNING,
default_smtp.DefaultSMTPBannerTest(): TestResult.WARNING,
service_implementation.SMTPTest(): TestResult.OK,
default_telnet.DefaultTelnetBannerTest(): TestResult.UNKNOWN,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.NOT_APPLICABLE,
default_templates.DefaultTemplateFileTest(): TestResult.NOT_APPLICABLE
},
port_range='-')
# test artillery
honeypot_test('artillery',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.OK,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.WARNING,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.OK,
default_ftp.DefaultFTPBannerTest(): TestResult.OK,
service_implementation.HTTPTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultGlastopfWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultStylesheetTest(): TestResult.NOT_APPLICABLE,
default_http.CertificateValidationTest(): TestResult.NOT_APPLICABLE,
default_imap.DefaultIMAPBannerTest(): TestResult.NOT_APPLICABLE,
default_smtp.DefaultSMTPBannerTest(): TestResult.OK,
service_implementation.SMTPTest(): TestResult.WARNING,
default_telnet.DefaultTelnetBannerTest(): TestResult.NOT_APPLICABLE,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.WARNING, # random reply
default_templates.DefaultTemplateFileTest(): TestResult.NOT_APPLICABLE
},
port_range='-')
# test beartrap
honeypot_test('beartrap',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.OK,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.OK,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.OK,
default_ftp.DefaultFTPBannerTest(): TestResult.WARNING,
service_implementation.HTTPTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultGlastopfWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultStylesheetTest(): TestResult.NOT_APPLICABLE,
default_http.CertificateValidationTest(): TestResult.NOT_APPLICABLE,
default_imap.DefaultIMAPBannerTest(): TestResult.NOT_APPLICABLE,
default_smtp.DefaultSMTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.SMTPTest(): TestResult.NOT_APPLICABLE,
default_telnet.DefaultTelnetBannerTest(): TestResult.NOT_APPLICABLE,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.NOT_APPLICABLE,
default_templates.DefaultTemplateFileTest(): TestResult.NOT_APPLICABLE
})
# test conpot
honeypot_test('conpot',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.OK,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.OK,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.OK,
default_ftp.DefaultFTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.HTTPTest(): TestResult.OK,
default_http.DefaultWebsiteTest(): TestResult.OK,
default_http.DefaultGlastopfWebsiteTest(): TestResult.OK,
default_http.DefaultStylesheetTest(): TestResult.NOT_APPLICABLE,
default_http.CertificateValidationTest(): TestResult.NOT_APPLICABLE,
default_imap.DefaultIMAPBannerTest(): TestResult.NOT_APPLICABLE,
default_smtp.DefaultSMTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.SMTPTest(): TestResult.NOT_APPLICABLE,
default_telnet.DefaultTelnetBannerTest(): TestResult.NOT_APPLICABLE,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.NOT_APPLICABLE,
default_templates.DefaultTemplateFileTest(): TestResult.WARNING
},
port_range='0-501,503-1000')
# test cowrie
honeypot_test('cowrie',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.OK,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.OK,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.OK,
default_ftp.DefaultFTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.HTTPTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultGlastopfWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultStylesheetTest(): TestResult.NOT_APPLICABLE,
default_http.CertificateValidationTest(): TestResult.NOT_APPLICABLE,
default_imap.DefaultIMAPBannerTest(): TestResult.NOT_APPLICABLE,
default_smtp.DefaultSMTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.SMTPTest(): TestResult.NOT_APPLICABLE,
default_telnet.DefaultTelnetBannerTest(): TestResult.WARNING,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.OK,
default_templates.DefaultTemplateFileTest(): TestResult.NOT_APPLICABLE
},
port_range='-')
# test dionaea
honeypot_test('dionaea',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.WARNING,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.WARNING,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.WARNING,
default_ftp.DefaultFTPBannerTest(): TestResult.WARNING,
service_implementation.HTTPTest(): TestResult.OK,
default_http.DefaultWebsiteTest(): TestResult.WARNING,
default_http.DefaultGlastopfWebsiteTest(): TestResult.OK,
default_http.DefaultStylesheetTest(): TestResult.NOT_APPLICABLE,
default_http.CertificateValidationTest(): TestResult.WARNING,
default_imap.DefaultIMAPBannerTest(): TestResult.NOT_APPLICABLE,
default_smtp.DefaultSMTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.SMTPTest(): TestResult.NOT_APPLICABLE,
default_telnet.DefaultTelnetBannerTest(): TestResult.NOT_APPLICABLE,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.NOT_APPLICABLE,
default_templates.DefaultTemplateFileTest(): TestResult.NOT_APPLICABLE
},
port_range='-')
# test glastopf
honeypot_test('glastopf',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.OK,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.OK,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.OK,
default_ftp.DefaultFTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.HTTPTest(): TestResult.OK,
default_http.DefaultWebsiteTest(): TestResult.OK,
default_http.DefaultGlastopfWebsiteTest(): TestResult.WARNING,
default_http.DefaultStylesheetTest(): TestResult.WARNING,
default_http.CertificateValidationTest(): TestResult.NOT_APPLICABLE,
default_imap.DefaultIMAPBannerTest(): TestResult.NOT_APPLICABLE,
default_smtp.DefaultSMTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.SMTPTest(): TestResult.NOT_APPLICABLE,
default_telnet.DefaultTelnetBannerTest(): TestResult.NOT_APPLICABLE,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.NOT_APPLICABLE,
default_templates.DefaultTemplateFileTest(): TestResult.NOT_APPLICABLE
})
# test honeypy
honeypot_test('honeypy',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.OK,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.WARNING,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.WARNING,
default_ftp.DefaultFTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.HTTPTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultGlastopfWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultStylesheetTest(): TestResult.NOT_APPLICABLE,
default_http.CertificateValidationTest(): TestResult.NOT_APPLICABLE,
default_imap.DefaultIMAPBannerTest(): TestResult.NOT_APPLICABLE,
default_smtp.DefaultSMTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.SMTPTest(): TestResult.NOT_APPLICABLE,
default_telnet.DefaultTelnetBannerTest(): TestResult.WARNING,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.NOT_APPLICABLE,
default_templates.DefaultTemplateFileTest(): TestResult.NOT_APPLICABLE
},
port_range='-')
# test dionaea
honeypot_test('honeything',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.OK,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.OK,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.OK,
default_ftp.DefaultFTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.HTTPTest(): TestResult.OK,
default_http.DefaultWebsiteTest(): TestResult.WARNING,
default_http.DefaultGlastopfWebsiteTest(): TestResult.OK,
default_http.DefaultStylesheetTest(): TestResult.NOT_APPLICABLE,
default_http.CertificateValidationTest(): TestResult.NOT_APPLICABLE,
default_imap.DefaultIMAPBannerTest(): TestResult.NOT_APPLICABLE,
default_smtp.DefaultSMTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.SMTPTest(): TestResult.NOT_APPLICABLE,
default_telnet.DefaultTelnetBannerTest(): TestResult.NOT_APPLICABLE,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.NOT_APPLICABLE,
default_templates.DefaultTemplateFileTest(): TestResult.NOT_APPLICABLE
})
# test honeytrap
honeypot_test('honeytrap',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.OK,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.OK,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.WARNING,
default_ftp.DefaultFTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.HTTPTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultGlastopfWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultStylesheetTest(): TestResult.NOT_APPLICABLE,
default_http.CertificateValidationTest(): TestResult.NOT_APPLICABLE,
default_imap.DefaultIMAPBannerTest(): TestResult.NOT_APPLICABLE,
default_smtp.DefaultSMTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.SMTPTest(): TestResult.NOT_APPLICABLE,
default_telnet.DefaultTelnetBannerTest(): TestResult.NOT_APPLICABLE,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.UNKNOWN,
default_templates.DefaultTemplateFileTest(): TestResult.NOT_APPLICABLE
},
port_range='-')
# test kippo
honeypot_test('kippo',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.OK,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.OK,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.OK,
default_ftp.DefaultFTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.HTTPTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultGlastopfWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultStylesheetTest(): TestResult.NOT_APPLICABLE,
default_http.CertificateValidationTest(): TestResult.NOT_APPLICABLE,
default_imap.DefaultIMAPBannerTest(): TestResult.NOT_APPLICABLE,
default_smtp.DefaultSMTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.SMTPTest(): TestResult.NOT_APPLICABLE,
default_telnet.DefaultTelnetBannerTest(): TestResult.NOT_APPLICABLE,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.OK,
default_templates.DefaultTemplateFileTest(): TestResult.NOT_APPLICABLE
},
port_range='-')
# test mtpot
honeypot_test('mtpot',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.OK,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.OK,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.OK,
default_ftp.DefaultFTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.HTTPTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultGlastopfWebsiteTest(): TestResult.NOT_APPLICABLE,
default_http.DefaultStylesheetTest(): TestResult.NOT_APPLICABLE,
default_http.CertificateValidationTest(): TestResult.NOT_APPLICABLE,
default_imap.DefaultIMAPBannerTest(): TestResult.NOT_APPLICABLE,
default_smtp.DefaultSMTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.SMTPTest(): TestResult.NOT_APPLICABLE,
default_telnet.DefaultTelnetBannerTest(): TestResult.WARNING,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.NOT_APPLICABLE,
default_templates.DefaultTemplateFileTest(): TestResult.NOT_APPLICABLE
})
# test shockpot
honeypot_test('shockpot',
{
direct_fingerprinting.DirectFingerprintTest(): TestResult.OK,
direct_fingerprinting.DefaultServiceCombinationTest(): TestResult.OK,
direct_fingerprinting.DuplicateServicesCheck(): TestResult.OK,
default_ftp.DefaultFTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.HTTPTest(): TestResult.OK,
default_http.DefaultWebsiteTest(): TestResult.WARNING,
default_http.DefaultGlastopfWebsiteTest(): TestResult.OK,
default_http.DefaultStylesheetTest(): TestResult.OK,
default_http.CertificateValidationTest(): TestResult.NOT_APPLICABLE,
default_imap.DefaultIMAPBannerTest(): TestResult.NOT_APPLICABLE,
default_smtp.DefaultSMTPBannerTest(): TestResult.NOT_APPLICABLE,
service_implementation.SMTPTest(): TestResult.NOT_APPLICABLE,
default_telnet.DefaultTelnetBannerTest(): TestResult.NOT_APPLICABLE,
old_version_bugs.KippoErrorMessageBugTest(): TestResult.NOT_APPLICABLE,
default_templates.DefaultTemplateFileTest(): TestResult.NOT_APPLICABLE
},
port_range='-')
# test the interface
interface_test()
if __name__ == '__main__':
main()