Selaa lähdekoodia

add thread matcher, make mitm port vars strings

tags/v0.7.0
Jonathan Cobb 4 vuotta sitten
vanhempi
commit
02bb6fb288
4 muutettua tiedostoa jossa 10 lisäystä ja 3 poistoa
  1. +1
    -1
      automation/roles/mitmproxy/files/bubble_modify.py
  2. +1
    -1
      automation/roles/mitmproxy/templates/bubble_config.py.j2
  3. +1
    -1
      bubble-server/src/main/resources/logback.xml
  4. +7
    -0
      bubble-server/src/main/resources/models/apps/user_block/hn/bubbleApp_userBlock_hn_matchers.json

+ 1
- 1
automation/roles/mitmproxy/files/bubble_modify.py Näytä tiedosto

@@ -82,7 +82,7 @@ def send_bubble_response(response):
def responseheaders(flow):

if flow.request.path and flow.request.path.startswith(BUBBLE_URI_PREFIX):
uri = 'https://' + bubble_host_alias + ':' + str(bubble_ssl_port) + '/' + flow.request.path[len(BUBBLE_URI_PREFIX):]
uri = 'http://127.0.0.1:' + bubble_port + '/' + flow.request.path[len(BUBBLE_URI_PREFIX):]
bubble_log('responseheaders: sending special bubble request to '+uri)
headers = {
'Accept' : 'application/json',


+ 1
- 1
automation/roles/mitmproxy/templates/bubble_config.py.j2 Näytä tiedosto

@@ -2,4 +2,4 @@ bubble_network = '{{ bubble_network }}'
bubble_port = '{{ admin_port }}';
bubble_host = '{{ server_name }}'
bubble_host_alias = '{{ server_alias }}'
bubble_ssl_port = {{ ssl_port }}
bubble_ssl_port = '{{ ssl_port }}'

+ 1
- 1
bubble-server/src/main/resources/logback.xml Näytä tiedosto

@@ -41,7 +41,7 @@
<!-- <logger name="bubble.filters.BubbleRateLimitFilter" level="TRACE" />-->
<!-- <logger name="org.cobbzilla.wizard.filters.RateLimitFilter" level="TRACE" />-->
<logger name="bubble.service.stream.StandardRuleEngineService" level="DEBUG" />
<logger name="bubble.service.stream.ActiveStreamState" level="DEBUG" />
<logger name="bubble.service.stream.ActiveStreamState" level="INFO" />
<logger name="bubble.resources.stream" level="DEBUG" />
<!-- <logger name="bubble.resources.stream.FilterHttpResource" level="TRACE" />-->
<logger name="bubble.service.stream" level="INFO" />


+ 7
- 0
bubble-server/src/main/resources/models/apps/user_block/hn/bubbleApp_userBlock_hn_matchers.json Näytä tiedosto

@@ -8,6 +8,13 @@
"fqdn": "news.ycombinator.com",
"urlRegex": "/item\\?id=\\d+",
"rule": "hn_user_blocker"
}, {
"name": "HNThreadsMatcher",
"site": "HackerNews",
"template": true,
"fqdn": "news.ycombinator.com",
"urlRegex": "/threads\\?id=\\w+",
"rule": "hn_user_blocker"
}]
}
}]

Ladataan…
Peruuta
Tallenna