SPAM or Disguised MS Outlook?— Credentials Harvester

It is not fun to watch end users, company stakeholders, company management receiving such emails. Most of the times, I have seen Invoice emails, Email not received type of mails etc. Over the period of time I have took few samples to look into over a period of time in order to gain more insights onto how the newbies and highly sophisticated attackers are using this known technique of Social Engineering nowadays.

In one of the sample, which derived my interest was it contained an attachment with the disguised text that your emails are rejected. But the thing to be noted was that the attachment was not an excel, pdf neither a word document. In fact it was an HTML file. But Why?

Let’s take a look into what this HTML file has to offer.

On opening the HTML file. It looked like this. An Outlook Web App. Pretty disguised. The attacker has auto filled the email field with the actual email of the recipient. Which in this I had to remove!

So, before entering the login details. I have opened the file in Visual Studio Code. On looking the code. We can see that the attacker is trying to harvest the below information.

The CSS code was just for styling and nothing else. But I found a comment which was uncommented in a unique way and my eyes caught an EVAL function. Well, it seems like this might be the actual stuff.


The data was URL Encoded. So, I moved onto decoding it and it yielded below data.


Here we can find three different unescape functions being used. We got to perform URL Decoding twice to reveal the actual function.


As we have now checked what the JS was about. This JS is generating the FORM action value which then get’s replaced in the actual phishing page as it does not contains the beginning of the form.

The technique used here to obfuscate the code XOR Multibyte!

Now let us try adding a sample username and password to check the exact behavior of this Credential Harvester.

On providing the credentials and clicking on Login. The page requests a website hosted over .xyz domain.

The passwords are being stored using the sauce.php, Well they are indeed creating a good sauce by harvesting more credentials.

As the attacker is quite good at creating pages. So he has used a redirection method to redirect the users to another page.

Eventually leading to the below page!

This states that you have successfully fixed your email delivery problem. Well, on this page we can see another script which is to set a timeout for redirecting user to where?

The timer is set to redirect the users to Microsoft Official Website, providing details on troubleshooting. This is just to make the users able to read that they have solved the issue. The redirection is to disguise the users in order to feel them comfortable.

Also, on checking Whois information. We can see that these domains were registered in January 2021. Which means that these domains are fairly new and are being used actively for harvesting AD/Outlook credentials for further compromising the victims.

The domains is still active and if you have got the privilege to reach at this end. Kindly block these domains in your organization as well.


Never trust the emails you received outside of your organization. Always be vigilant with the attachments you find with such emails. Report such cases to your organizational Information Security Department/Concerned Department.

If you have intentionally/unintentionally have opened the attachment and have added your credentials. Change your passwords immediately. Disconnect your system from the internal network. Reach out the Incident Response Unit or file the incident. Finally enable MFA everywhere.

Thank you for reading!

Cyber Security Enthusiast