This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo -u postgres psql | |
sudo -u postgres createuser <username> | |
sudo -u postgres createdb <dbname> | |
sudo -u postgres psql | |
psql=# alter user <username> with encrypted password '<password>'; | |
psql=# grant all privileges on database <dbname> to <username> ; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -i $INTERFACE -v -n -c $Number_of _packets -w attack.log dst port 80 | |
tcpdump -i eth0 -v -n -c 500 -w attack.log dst port 80 | |
#After you can analise | |
tcpdump -nr attack.log |awk '{print $3}' |grep -oE '[0-9]{1,}.[0-9]{1,}.[0-9]{1,}.[0-9]{1,}' |sort |uniq -c |sort -rn | |
#show only Top-20 | |
tcpdump -nr attack.log |awk '{print $3}' |grep -oE '[0-9]{1,}.[0-9]{1,}.[0-9]{1,}.[0-9]{1,}' |sort |uniq -c |sort -rn | head -20 |
NewerOlder