Check if an email address exists without sending any email, written in Rust. Comes with a ⚙️ HTTP backend.
Rust emailemail-validationemail-validation-apiemail-verificationemail-verification-apiemail-verifierhacktoberfest
fix: Add "recipient unknown" check (#446)
Amaury Martinydeca071583e3
diff --git a/Cargo.lock b/Cargo.lockindex f5da8702..fcedb41c 100644--- a/Cargo.lock+++ b/Cargo.lock@@ -373,7 +373,7 @@ checksum = "4785bdd1c96b2a846b2bd7cc02e86b6b3dbf14e7e53446c4f54c92a361040822"[[package]]name = "check-if-email-exists"-version = "0.8.6"+version = "0.8.7"dependencies = ["async-smtp","async-std-resolver",@@ -392,7 +392,7 @@ dependencies = [[[package]]name = "check-if-email-exists-cli"-version = "0.8.6"+version = "0.8.7"dependencies = ["check-if-email-exists","clap",@@ -405,7 +405,7 @@ dependencies = [[[package]]name = "check-if-email-exists-test-suite"-version = "0.8.6"+version = "0.8.7"dependencies = ["check-if-email-exists","serde",diff --git a/Cargo.toml b/Cargo.tomlindex 59258a4a..007170e4 100644--- a/Cargo.toml+++ b/Cargo.toml@@ -1,6 +1,6 @@[package]name = "check-if-email-exists-cli"-version = "0.8.6"+version = "0.8.7"default-run = "check_if_email_exists"edition = "2018"license = "AGPL-3.0"diff --git a/Dockerfile b/Dockerfileindex 6a0a05ff..a976fb96 100644--- a/Dockerfile+++ b/Dockerfile@@ -3,7 +3,7 @@ FROM alpine# `ciee` stands for check-if-email-existsWORKDIR /ciee# Fetch latest version-ENV CIEE_VERSION 0.8.6+ENV CIEE_VERSION 0.8.7# Install needed librariesRUN apk update && \diff --git a/README.md b/README.mdindex 2145d9e7..6edba00d 100644--- a/README.md+++ b/README.md@@ -93,7 +93,7 @@ Head to the [releases page](https://github.com/amaurymartiny/check-if-email-exis```> $ check_if_email_exists --help-check_if_email_exists 0.8.6+check_if_email_exists 0.8.7Check if an email address exists without sending any email.USAGE:diff --git a/core/Cargo.toml b/core/Cargo.tomlindex 5d59ff92..617699c2 100644--- a/core/Cargo.toml+++ b/core/Cargo.toml@@ -1,6 +1,6 @@[package]name = "check-if-email-exists"-version = "0.8.6"+version = "0.8.7"authors = ["Amaury Martiny <[email protected]>"]categories = ["email"]description = "Check if an email address exists without sending any email"diff --git a/core/src/smtp/mod.rs b/core/src/smtp/mod.rsindex 36e746f1..7ad5cc98 100644--- a/core/src/smtp/mod.rs+++ b/core/src/smtp/mod.rs@@ -227,6 +227,19 @@ async fn email_deliverable(});}+ // Check error messages that say that user can actually receive+ // emails.+ // 4.2.1 The user you are trying to contact is receiving mail at a rate that+ if err_string+ .contains("The user you are trying to contact is receiving mail at a rate that")+ {+ return Ok(Deliverability {+ has_full_inbox: false,+ is_deliverable: true,+ is_disabled: false,+ });+ }+// These are the possible error messages when email account doesn't exist.// 550 Address rejected// 550 5.1.1 : Recipient address rejected@@ -253,6 +266,8 @@ async fn email_deliverable(|| err_string.contains("user unknown")// 550 Unknown user|| err_string.contains("unknown user")+ // 5.1.1 Recipient unknown <EMAIL>+ || err_string.contains("recipient unknown")// 550 5.1.1 No such user - pp// 550 No such user here|| err_string.contains("no such user")diff --git a/test_suite/Cargo.toml b/test_suite/Cargo.tomlindex 092e2dcc..a2f85567 100644--- a/test_suite/Cargo.toml+++ b/test_suite/Cargo.toml@@ -1,6 +1,6 @@[package]name = "check-if-email-exists-test-suite"-version = "0.8.6"+version = "0.8.7"edition = "2018"publish = false