Skip to content

Commit

Permalink
inql.burp_ext.generator_tab: disable unsupported Jython HTTP/2
Browse files Browse the repository at this point in the history
  • Loading branch information
thypon committed May 11, 2021
1 parent 1218043 commit 0982a34
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions inql/burp_ext/generator_tab.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ class GeneratorTab(ITab):
def __init__(self, callbacks, helpers):
self._callbacks = callbacks
self._helpers = helpers
self.disable_http2()

def getTabCaption(self):
"""
Expand Down Expand Up @@ -91,6 +92,12 @@ def getUiComponent(self):
self._callbacks.customizeUiComponent(self.panel.this)
return self.panel.this

def disable_http2(self):
print("Jython does not support HTTP/2 at the current stage: disabling it!")
j = json.loads(self._callbacks.saveConfigAsJson())
j['project_options']['http']['http2']['enable_http2'] = False
self._callbacks.loadConfigFromJson(json.dumps(j))

def bring_in_front(self):
self.panel.this.setAlwaysOnTop(True)
self.panel.this.setAlwaysOnTop(False)
Expand Down

0 comments on commit 0982a34

Please sign in to comment.