Here's something I couldn't find an answer to. Say you have a form and on that form you have a field for someone to enter their e-mail address. Now after the e-mail address is entered, is there a way after using RegEx to verify that it follows the syntax of an e-mail address, to then verify that it is a valid e-mail that can receive messages?
I looked all over the net and found a deprecated way to do it that has since been stopped by patches, so I was wondering if there wasn't a way to do it on the server maybe polling the smtp server or something.
If you're looking to verify that the user hasn't made a mistake (or is giving you a bogus address because they aren't interested in your messages), you should probably do what every other system does: don't activate the account (or whatever) until you get some verification that the user has gotten the email by clicking a link or entering a code that the email contains.
You need to do this because you might never get an indication that an email address is invalid - some servers are configured to throw away some (or all) invalid email addresses or dump them in a spam bin. Just because the email appears to have been successfully sent doesn't mean it's valid or that it's getting to the right person.
Related
I want to send a email to the user from my laravel application. But i want to add a hidden token in that email so that user cannot see it and when user reply to that mail i can read that token and further use it.
Is it even possible?
I am using laravel 5.6 and sending emails using SMTP
There are several ways to do it but none is ideal. Let's start with your idea:
You can add a token within the message, but it can never be invisible, the contents of the message have to be fully visible. Even so, if the reply simply doesn't contain the original message, you will lose the reference
The standard way of tracking replies is based on Message-ID, since every email has to have unique Message-ID. Since you mentioned that you are using SMTP, that allows you to setup Message-ID upfront, otherwise, you'd retrieve it after the message is sent. It helps in a way that you can store that value in the database and automatically link it to the recipient.
Then, you'd look for In-Reply-To: and/or References: headers which should mention the original Message-ID if the reply is properly formatted, which doesn't have to be the case.
Ultimately, depending on your use case, you might not need any of these and you could just keep the sent email based on the recipient email address and extra information that you wanted to pass in the email within your database. Assuming that you'd expect an email from the same recipient email address, you could just figure out the token locally.
Here is the scenario. I am using PHP and I want to check whether an email address is valid and deliverable. Here are the steps I take:
Validate email address via regex
Validate email address via php filter_var
Finally use SMTP to check whether the recipient exists
This thing works perfectly except that using an SMTP way is too slow and takes anywhere between 10 seconds to 40 seconds to validate. Sometimes the SMTP check is blocked by the recipient server and my server ip was blacklisted which made all the emails to that server as invalid.
There are professional services out there which do this for you but I don't want to use them for this particular project I am doing. Due to restrictions I cannot actually send an email to that email address.
Is there anyother way or faster way to validate the email addresses? How do these professional email validating companies do the validations so fast and cheaply?
I apologise if the question is not right for this forum. Please tell me and I will promptly delete this. I am new to stackoverflow.
P.S: I checked the other questions but they all pointed to using SMTP as the solution which I am already doing.
Is there a way to setup Outlook 2010 to run a script or some other form of sanity-check when you attempt to SEND messages from the client? My specific situation is that I use the same outlook client for multiple accounts (work, gmail, VPS server, etc) and I've found myself a couple of times sending emails "from" the wrong account.
In a perfect world I'd want to be able to write a script with logic something like the following:
when (I hit send)
if (the "source" account is "myuserid#gmail.com") then
if (there are addresses in TO or CC that match "work.com") then
pop up a dialog box that says:
"You appear to be sending email to work.com from gmail.com - do you really want to do this?"
if yes, then send it and return
if no, go back to the message compose window
that way, I'd have to actually very intentionally use a non-work email address to send email to the work people (which is rare in my particular case)
Try SendUsingAccount to read the "source" account in ItemSend.
From what I've been reading the SPF can be used to validate email addresses by sending commands (rather than an actual email) such as HELO. I've managed to pick up a basic grasp of the policy but I can't get my head around how I'd go about solving the following problem:
I've got a number of email addresses attached to contacts in a CRM system and I'd like to find out if the email addresses are valid and still in use.
Currently we're using a REST Web Service (http://emailinspector.co.uk/) which returns "Ok" (if its ok... duh), "Bad" (if its not valid or not in use) or "Unknown". For Unknown, you are also provided some notes on why it came back with that, i.e. you are told if the Mailbox is full or if its a well known DEA.
I'd like to be able to program a script that can replicate this functionality and from what I've worked out it should use the Sender Policy Framework to do this? The problem is I don't know how I'd go about returning such precise information for "Unknown" email addresses.
Ideas and thoughts?
Actually SPF is just a text record, with some "hints" to let you know if an IP address or mail server is "allowed/Authorized" to send email for that domain. It doesn't tell you anything about an individual email address in that domain..
for example
[doon#qix:~] host -t txt labratsoftware.com
labratsoftware.com descriptive text "v=spf1 a -all"
The SPF record for one of my domains says that only the a record for the domain is authorized to send email for labratsoftware.com, and that if it doesn't come from that IP then it should be rejected (-all).
So the best you can do with SPF is tell that a received email came from an authorized host, and then use that information to help decide if you want to reject it or not.
The best way To test the validity of an email address you have, is to email it, and see if it bounces. You can use options like VERP (http://en.wikipedia.org/wiki/Variable_envelope_return_path) to automate the bounce handling. You can also try and connect to the MX records listed for the domain and try to deliver a message that way. Some Mail servers support verify (But most admins disable this to prevent information leakage). You can use RCPT TO to see if the server accepts it, but even if it does , you have no way of knowing if it will actually make it to their INBOX. My guess is that is what the API you are currently using is doing. And unknown are just ones that either don't answer, greylist, etc.
That might be silly question but I really need to know the answer. If I got the Outlook client installed on my machine and I click on the mailto link on the website the subject and body specified in the link is passed to the client. Is anything else attached to the message? Any headers or addition information about my website?
I am asking this question because I have such a link on my website and every time I test it the email fails spam checks with Postini.
I also get this message:
Your email has been encoded as 'Quoted-printable', and yet one of the lines of content is longer than the maximum 76 characters. No line within a quoted-printable body may exceed that size.
When I remove long links I am not getting this message but the email still fails the Postinig check.
Thanks for help,
Marcin
mailto: links are just interpreted by the browser as a signal to say "Open the default mail client to send an email to this person". Everything else is treated as a classic mail by Outlook.
Maybe it is something in your mail that Postini recognises as a potential spam phrase?