Hi,
I'm getting some issues using the 'CALL' instruction into my wrapscript and didn't find much help.
For the moment, here is my WrapScript with the CALL instruction:
'/pythonScripts/testScript/wrapper.sh'
CALL
First, I get this error:
ERROR line #3: in section '[TOP]': Empty stack
So, first weird things, it look like my value is not detected as 'pushed on the stack'.
So I tried to push two time my value on the stack:
'/pythonScripts/testScript/wrapper.sh'
'/pythonScripts/testScript/wrapper.sh'
CALL
This time, I get another error, closest that what I've expected:
ERROR line #4: in section '[TOP]': CALL invalid subprogram '/pythonScripts/testScript/wrapper.sh'.
I've double checked, the patch are correct.
bash-4.3# cat /pythonScripts/testScript/wrapper.sh
#!/bin/sh
#
# This shellscript is a simple python script wrapper boilerplate
#
EXECDIR=${PWD}
BASEDIR=$(dirname $0)
# Setup a new virtualenv for the script
python3 -m venv $BASEDIR/venv
source $BASEDIR/venv/bin/activate
# Install all required script packages
# Can do:
# pip install -r requirements.txt
# Or manually:
pip install requests
python $BASEDIR/script.py
And for the script itself, It's really basic:
bash-4.3# cat /pythonScripts/testScript/script.py
import requests
# This script is a simple example, do not use it
if response.status_code == 200:
print("80027d71002858060000005049434b4c4571015806000000535452494e477102752e")
I didn't spot my error, hoping you can help me to find it :)