Some shit.

This commit is contained in:
2025-01-01 16:46:38 +02:00
parent 5726dabf09
commit 98b37597e0

View File

@@ -68,41 +68,73 @@ function curlRequest {
if [[ "$DEBUG" == "off" ]]; then if [[ "$DEBUG" == "off" ]]; then
response="$(curl_ff117 -s -L \ if [[ "$OSTYPE" == "linux-gnu" ]]; then
-c "$GRPOPPRO_COOKIE_FILE" \ response="$(curl_ff117 -s -L \
-b "$GRPOPPRO_COOKIE_FILE" \ -c"$GRPOPPRO_COOKIE_FILE" \
"$url" \ -b"$GRPOPPRO_COOKIE_FILE" \
--compressed \ "$url" \
-X "$custom_method" \ --compressed \
-A "$USER_AGENT" \ -X "$custom_method" \
-H "$custom_accept" \ -A "$USER_AGENT" \
-H "$ACCEPT_LANGUAGE" \ -H "$custom_accept" \
-H "$CONNECTION" \ -H "$ACCEPT_LANGUAGE" \
-H "$UP_IN_REQ" \ -H "$CONNECTION" \
"$@" -H "$UP_IN_REQ" \
)" "$@"
)"
else
response="$(curl -s -L \
-c "$GRPOPPRO_COOKIE_FILE" \
-b "$GRPOPPRO_COOKIE_FILE" \
"$url" \
--compressed \
-X "$custom_method" \
-A "$USER_AGENT" \
-H "$custom_accept" \
-H "$ACCEPT_LANGUAGE" \
-H "$CONNECTION" \
-H "$UP_IN_REQ" \
"$@"
)"
fi
else else
if [[ "$OSTYPE" == "linux-gnu" ]]; then if [[ "$OSTYPE" == "linux-gnu" ]]; then
LOG_FILE="/tmp/grpoppro_curl_commands.log" LOG_FILE="/tmp/grpoppro_curl_commands.log"
local curl_command=(
"curl_ff117"
"-s"
"-L"
"-c$GRPOPPRO_COOKIE_FILE"
"-b$GRPOPPRO_COOKIE_FILE"
"$url"
"-X"
"$custom_method"
"-H $custom_accept"
"$@"
)
else else
LOG_FILE="$GRPOPPRO_DATA_DIR/grpoppro_curl_commands.log" LOG_FILE="$GRPOPPRO_DATA_DIR/grpoppro_curl_commands.log"
local curl_command=(
"curl"
"-s"
"-L"
"-c $GRPOPPRO_COOKIE_FILE"
"-b $GRPOPPRO_COOKIE_FILE"
"$url"
"--compressed"
"-X"
"$custom_method"
"-A $USER_AGENT"
"-H $custom_accept"
"-H $ACCEPT_LANGUAGE"
"-H $CONNECTION"
"-H $UP_IN_REQ"
"$@"
)
fi fi
local curl_command=(
"curl_ff117"
"-s"
"-L"
"-c$GRPOPPRO_COOKIE_FILE"
"-b$GRPOPPRO_COOKIE_FILE"
"$url"
"-X"
"$custom_method"
"-H $custom_accept"
"$@"
)
{ {
echo -e "<===========================\n" echo -e "<===========================\n"
echo "Called by: ${FUNCNAME[1]}" echo "Called by: ${FUNCNAME[1]}"