aboutsummaryrefslogtreecommitdiff
path: root/src/hydrilla/proxy/state_impl
diff options
context:
space:
mode:
authorWojtek Kosior <koszko@koszko.org>2022-08-11 21:55:46 +0200
committerWojtek Kosior <koszko@koszko.org>2022-08-11 21:55:46 +0200
commit1960eedc813b878ab193ff84ae10054ca4e0eccd (patch)
tree465b29e8702275a75dedd712f9f415270ccddd18 /src/hydrilla/proxy/state_impl
parenta38d19576c387e505cc468b20ca5b8bcf2fa4759 (diff)
downloadhaketilo-hydrilla-1960eedc813b878ab193ff84ae10054ca4e0eccd.tar.gz
haketilo-hydrilla-1960eedc813b878ab193ff84ae10054ca4e0eccd.zip
serve a stub of meta-site for proxy configuration
Diffstat (limited to 'src/hydrilla/proxy/state_impl')
-rw-r--r--src/hydrilla/proxy/state_impl/concrete_state.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/hydrilla/proxy/state_impl/concrete_state.py b/src/hydrilla/proxy/state_impl/concrete_state.py
index 0699bf7..bb14734 100644
--- a/src/hydrilla/proxy/state_impl/concrete_state.py
+++ b/src/hydrilla/proxy/state_impl/concrete_state.py
@@ -718,6 +718,15 @@ class ConcreteHaketiloState(base.HaketiloStateWithFields):
)
new_policy_tree = base.PolicyTree()
+
+ ui_factory = policies.WebUIPolicyFactory(builtin=True)
+ web_ui_pattern = 'http*://hkt.mitm.it/***'
+ for parsed_pattern in url_patterns.parse_pattern(web_ui_pattern):
+ new_policy_tree = new_policy_tree.register(
+ parsed_pattern,
+ ui_factory
+ )
+
new_payloads_data: dict[st.PayloadRef, st.PayloadData] = {}
for row in cursor.fetchall():