Skip to content

Commit 5b1bab1

Browse files
authored
Merge pull request #54 from 0xBallpoint/upgrade-http-framework
Upgrade HTTP framework
2 parents dfc2c43 + 2fb2e13 commit 5b1bab1

10 files changed

Lines changed: 659 additions & 346 deletions

File tree

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ scapy>=2.5.0
88
jinja2>=3.1.4
99
PyYAML>=6.0.2
1010
fastapi>=0.115.9
11-
uvicorn>=0.34.0
11+
hypercorn>=0.17.0

trapster/data/http/default_apache/config.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ name: default_apache
22
description: Default Apache server
33
headers:
44
Server: Apache/2.4.41 (Ubuntu)
5+
Content-Type: text/html; charset=utf-8
56

67
endpoints:
78
- "/":

trapster/data/http/default_iis/config.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ name: default_iis
22
description: Default IIS server
33
headers:
44
Server: Microsoft-IIS/10.0
5+
Content-Type: text/html; charset=utf-8
56

67
endpoints:
78
- "/":

trapster/data/http/demo_ai/config.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
name: demo_ai
22
description: Learn how to use AI to create honeypot web servers
33
headers:
4+
Content-Type: text/html; charset=utf-8
45
X-Frame-Options: SAMEORIGIN
56
Content-Security-Policy: frame-ancestors 'self'
67
X-Xss-Protection: 1; mode=block

trapster/data/http/demo_api/config.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ description: Learn how to create your own config file for the HTTP server
77

88
# headers here are optional, and will be added to all responses
99
headers:
10+
Content-Type: text/html; charset=utf-8
1011
Server: nginx
1112
X-Powered-By: PHP/7.4.3
1213

trapster/data/http/fortigate/config.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
name: fortigate
22
description: Fortigate honeypot
33
headers:
4+
Content-Type: text/html; charset=utf-8
45
X-Frame-Options: SAMEORIGIN
56
Content-Security-Policy: frame-ancestors 'self'
67
X-Xss-Protection: 1; mode=block

trapster/logger/formatters.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,7 @@ def format(self, event):
190190

191191
if protocol in {"http", "https"}:
192192
ecs_event["http"] = {
193+
"version": extra.get("version"),
193194
"request": {
194195
"method": extra.get("method"),
195196
"headers": extra.get("headers"),

0 commit comments

Comments
 (0)