From 29ebd70fc2d2fcb5e1a476f68b0e223cd834e3db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20K=C3=B6ck?= Date: Tue, 6 Oct 2020 13:09:05 +0200 Subject: [PATCH 1/5] added support for .do domains --- .idea/workspace.xml | 75 ++++++++++++++++++++++++++++++++++++++ check_domain_expiration.sh | 11 +++++- 2 files changed, 85 insertions(+), 1 deletion(-) create mode 100644 .idea/workspace.xml diff --git a/.idea/workspace.xml b/.idea/workspace.xml new file mode 100644 index 0000000..688745b --- /dev/null +++ b/.idea/workspace.xml @@ -0,0 +1,75 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1601975347454 + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/check_domain_expiration.sh b/check_domain_expiration.sh index c551b03..04d72ff 100755 --- a/check_domain_expiration.sh +++ b/check_domain_expiration.sh @@ -304,7 +304,16 @@ check_domain() EXP_DAYS=$(( ( $(date -ud ${EXDATE} +'%s') - $(date -ud `date +%Y-%m-%d` +'%s') )/60/60/24 )) fi - + elif [ "$DTYPE" == "do" ] + then + EXDATE_TMP=$(${WHOIS} -h whois.nic.do "${1}" | ${AWK} '/Registrar Registration Expiration Date:/ { print $5 }') + if [ -z "$EXDATE_TMP" ] + then + EXP_DAYS=NULL + else + EXDATE=`date -d"$EXDATE_TMP" +%Y-%m-%d` + EXP_DAYS=$(( ( $(date -ud ${EXDATE} +'%s') - $(date -ud `date +%Y-%m-%d` +'%s') )/60/60/24 )) + fi else echo "UNKNOWN - "$DTYPE" unsupported" exit 3 From e19b41608b4f84d2bfaf17fe68fa04ba6ad66e77 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20K=C3=B6ck?= Date: Tue, 6 Oct 2020 13:12:52 +0200 Subject: [PATCH 2/5] removed idea config file --- .gitignore | 1 + 1 file changed, 1 insertion(+) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..485dee6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.idea From 6c827bf8e23765c005b6395e35f32bb374260ab6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20K=C3=B6ck?= Date: Tue, 6 Oct 2020 13:14:57 +0200 Subject: [PATCH 3/5] removed idea files --- .idea/workspace.xml | 75 --------------------------------------------- 1 file changed, 75 deletions(-) delete mode 100644 .idea/workspace.xml diff --git a/.idea/workspace.xml b/.idea/workspace.xml deleted file mode 100644 index 688745b..0000000 --- a/.idea/workspace.xml +++ /dev/null @@ -1,75 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 1601975347454 - - - - - - - - - - - - - - - - - - - - \ No newline at end of file From b83c380e2ebb062c0c7ebb06aa05dfff7f610662 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20K=C3=B6ck?= Date: Tue, 6 Oct 2020 13:17:29 +0200 Subject: [PATCH 4/5] idea part 3 --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 485dee6..020c29c 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ .idea +.gitignore From 4eac15f57d993d5e05464f2f7985b9321697789e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20K=C3=B6ck?= Date: Tue, 6 Oct 2020 13:20:37 +0200 Subject: [PATCH 5/5] deleted .gitignore --- .gitignore | 2 -- 1 file changed, 2 deletions(-) delete mode 100644 .gitignore diff --git a/.gitignore b/.gitignore deleted file mode 100644 index 020c29c..0000000 --- a/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -.idea -.gitignore