Benjamin Renard commited on 2011-06-10 09:29:00
Showing 1 changed files, with 14 additions and 0 deletions.
... | ... |
@@ -35,6 +35,20 @@ case $TLD in |
35 | 35 |
exit 0 |
36 | 36 |
fi |
37 | 37 |
;; |
38 |
+ be) |
|
39 |
+ STATUS="`echo -e "$WHOIS"|grep "^Status:"|awk '{print $2}'`" |
|
40 |
+ [ $DEBUG -eq 1 ] && echo "Status : $STATUS" |
|
41 |
+ SINCE="`echo -e "$WHOIS"|grep "^Registered:"|sed 's/^Registered: *//'`" |
|
42 |
+ [ $DEBUG -eq 1 ] && echo "Since : $SINCE" |
|
43 |
+ if [ "$STATUS" != "REGISTERED" ] |
|
44 |
+ then |
|
45 |
+ echo "CRITICAL : $DOMAIN status is not REGISTERED (value : $STATUS)" |
|
46 |
+ exit 2 |
|
47 |
+ else |
|
48 |
+ echo "OK : $DOMAIN registered since $SINCE" |
|
49 |
+ exit 0 |
|
50 |
+ fi |
|
51 |
+ ;; |
|
38 | 52 |
*) |
39 | 53 |
EXTXT=`echo -e "$WHOIS"|grep "^expires:"` |
40 | 54 |
[ $DEBUG -eq 1 ] && echo "expire result format 1 : $EXTXT" |
41 | 55 |