This file contains hidden or 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
#!/bin/bash | |
git log --format=">%H< %cN" -10 | while read line | |
do | |
pre=`echo $line|sed -e "s/\(.*\)>[^<]*<.*/\1/"` | |
sha=`echo $line|sed -e "s/.*>\([0-9a-fA-F]*\)<.*/\1/"` | |
#echo "Cut sha as: $sha" | |
sha=`git rev-parse --short=4 $sha` | |
rest=`echo $line|sed -e "s/.*>[^<]*<\(.*\)/\1/"` | |
echo "$pre -- $sha -- $rest" |
This file contains hidden or 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
These lines are saved to a text file and loaded into iptables with iptables-restore (like "/sbin/iptables-restore </etc/iptables.conf"): | |
:DO_BLACKLIST - [0:0] | |
:IN_SSH - [0:0] | |
-A INPUT -m recent --rcheck --seconds 3600 --name blacklist --rsource -j DROP | |
-A INPUT -p tcp -m tcp --dport 22 -j IN_SSH | |
-A IN_SSH -s 192.168.1.0/24 -p tcp -m tcp --dport 22 -j ACCEPT | |
-A IN_SSH -m recent --rcheck --seconds 60 --hitcount 4 --name ssh_limits --rsource -j DO_BLACKLIST | |
-A IN_SSH -p tcp -m tcp --dport 22 --tcp-flags FIN,SYN,RST,ACK SYN -m recent --set --name ssh_limits --rsource -j ACCEPT | |
-A IN_SSH -j ACCEPT |
This file contains hidden or 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
import java.awt.Image; | |
import java.awt.event.MouseEvent; | |
import java.awt.event.MouseListener; | |
import java.io.BufferedReader; | |
import java.io.IOException; | |
import java.io.InputStreamReader; | |
import java.net.MalformedURLException; | |
import java.net.URL; | |
import java.util.regex.Matcher; | |
import java.util.regex.Pattern; |
NewerOlder