KoD 0.5.2

- Fix Parziale Cloudflare
- Maggiore Reattività
- Su ANDROID alcuni siti es. SerieHD e GuardaSerie.click non funzionano
This commit is contained in:
Alhaziel
2019-12-07 19:50:43 +01:00
parent 98580ba11a
commit 58e7a3e84d
147 changed files with 59089 additions and 11503 deletions
+10 -3
View File
@@ -9,6 +9,9 @@ except ImportError:
raise RuntimeError('Please install the python module v8eval either via pip or download it from https://github.com/sony/v8eval')
from . import JavaScriptInterpreter
from .encapsulated import template
# ------------------------------------------------------------------------------- #
class ChallengeInterpreter(JavaScriptInterpreter):
@@ -16,11 +19,15 @@ class ChallengeInterpreter(JavaScriptInterpreter):
def __init__(self):
super(ChallengeInterpreter, self).__init__('v8')
def eval(self, jsEnv, js):
# ------------------------------------------------------------------------------- #
def eval(self, body, domain):
try:
return v8eval.V8().eval('{}{}'.format(jsEnv, js))
except: # noqa
return v8eval.V8().eval(template(body, domain))
except (TypeError, v8eval.V8Error):
RuntimeError('We encountered an error running the V8 Engine.')
# ------------------------------------------------------------------------------- #
ChallengeInterpreter()