Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- send_api_cmd() {
- answer=$(curl -s -k \
- --data-urlencode "user=$username" \
- --data-urlencode "password=$password" \
- --data-urlencode "cod=yes" \
- --data-urlencode "cmd=$1" \
- --data-urlencode "ab1=$2" \
- --data-urlencode "cd2=$3" \
- --data-urlencode "ef3=$4" \
- https://$host:$port/api/)
- return $answer
- }
Advertisement
Add Comment
Please, Sign In to add comment