Browse Source

Added WAAP Exam script for Partners

main
kusum 2 months ago
parent
commit
024180e458
1 changed files with 44 additions and 0 deletions
  1. 44
    0
      PartnerAutomation/waap-labs/waap_partner_exam.sh

+ 44
- 0
PartnerAutomation/waap-labs/waap_partner_exam.sh View File

@@ -0,0 +1,44 @@
#!/bin/bash

# Prompt the user for the Prefix value
read -p "Enter the Prefix for the URL: " Prefix

# Construct URL with the user-provided prefix
url="https://${Prefix}waapexam.appsec-akaed.com/shop/"

# Generate GET requests for /shop/
echo -e "\n---- Generating Traffic ----\n"
siege -c 150 -t 10s -b --no-parser $url

echo -e "\n---- Generating Traffic ----\n"
ab -v 0 -q -S -d -c 2 -n 30 -H "cookie:waapexam=wrongValue" -H "User-Agent: ExamBot" "https://${Prefix}waapexam.appsec-akaed.com/"
sleep 1

ab -v 0 -q -S -d -c 2 -n 30 -H "cookie:waapexam=ABC1234" -H "User-Agent: ExamBot" "https://${Prefix}waapexam.appsec-akaed.com/"
sleep 1

echo -e "\n---- Generating Traffic ----\n"
ab -v 0 -q -S -d -c 2 -n 30 -H "User-Agent: Mozilla/5.0 (compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm)" "https://${Prefix}waapexam.appsec-akaed.com/"
sleep 1

echo -e "\n---- Generating Traffic ----\n"
ab -v 0 -q -S -d -c 2 -n 30 -H "User-Agent: Ruby/3.2.2" "https://${Prefix}waapexam.appsec-akaed.com/"
sleep 1

for i in $(seq 1 30); do
echo -ne "\r$i/30"
sleep 1
curl -s -S "https://${Prefix}waapexam.appsec-akaed.com/" \
-H 'user-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.193 Safari/537.36' \
-H 'task: Browser Impersonator' \
--compressed \
-o /dev/null
curl -s -S "https://${Prefix}waapexam.appsec-akaed.com/robots.txt" \
-A 'Googlebot' \
-H 'task: transparent bots v2' \
--compressed \
-o /dev/null
done

echo -e "\nFinished"

Loading…
Cancel
Save