Now passing get_dump and post_dump to PHP/Python
This commit is contained in:
parent
73857c46ab
commit
09008f78a2
|
@ -5,14 +5,14 @@ get_mime ${r[uri]}
|
||||||
|
|
||||||
if [[ ${cfg[php_enabled]} == true && ${r[uri]} =~ ".php" ]]; then
|
if [[ ${cfg[php_enabled]} == true && ${r[uri]} =~ ".php" ]]; then
|
||||||
temp=$(mktemp)
|
temp=$(mktemp)
|
||||||
php "${r[uri]}" > $temp
|
php "${r[uri]}" "$(get_dump)" "$(post_dump)" > $temp
|
||||||
[[ ${r[headers]} != '' ]] && printf "${r[headers]}\r\n\r\n" || printf "\r\n"
|
[[ ${r[headers]} != '' ]] && printf "${r[headers]}\r\n\r\n" || printf "\r\n"
|
||||||
cat $temp
|
cat $temp
|
||||||
rm $temp
|
rm $temp
|
||||||
|
|
||||||
elif [[ ${cfg[python_enabled]} == true && ${r[uri]} =~ ".py" ]]; then
|
elif [[ ${cfg[python_enabled]} == true && ${r[uri]} =~ ".py" ]]; then
|
||||||
temp=$(mktemp)
|
temp=$(mktemp)
|
||||||
python "${r[uri]}" > $temp
|
python "${r[uri]}" "$(get_dump)" "$(post_dump)" > $temp
|
||||||
[[ ${r[headers]} != '' ]] && printf "${r[headers]}\r\n\r\n" || printf "\r\n"
|
[[ ${r[headers]} != '' ]] && printf "${r[headers]}\r\n\r\n" || printf "\r\n"
|
||||||
cat $temp
|
cat $temp
|
||||||
rm $temp
|
rm $temp
|
||||||
|
|
Loading…
Reference in a new issue