File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change 1
1
.PHONY : lambda gcf
2
2
3
- VERSION =2.0.0
3
+ VERSION =2.0.1
4
4
CURRENT_DIR =$(shell pwd)
5
5
6
6
lambda :
Original file line number Diff line number Diff line change @@ -52,7 +52,8 @@ def execute(request):
52
52
request_json = request .get_json (force = True )
53
53
if "executable" not in request_json :
54
54
return bad_request ("Missing executable value" )
55
- if len (request_json ["executable" ]) > MAX_EXECUTABLE :
55
+ executable = base64 .b64decode (request_json ["executable" ])
56
+ if len (executable ) > MAX_EXECUTABLE :
56
57
return bad_request ("Executable exceeds max size" )
57
58
if "calldata" not in request_json :
58
59
return bad_request ("Missing calldata value" )
@@ -67,7 +68,7 @@ def execute(request):
67
68
68
69
path = "/tmp/execute.sh"
69
70
with open (path , "w" ) as f :
70
- f .write (base64 . b64decode ( request_json [ " executable" ]) .decode ())
71
+ f .write (executable .decode ())
71
72
72
73
os .chmod (path , 0o775 )
73
74
try :
You can’t perform that action at this time.
0 commit comments