My Profile Photo

Bencey's Blog


Informing the world about the application of Technology.
If you are looking for Tier III Technologies click the button below


Virus Scanner Bot

Hey all. Recently I have been coding a new bot for discord. What this bot does is its connected to virus total API if you are unaware of what virus total is its basically a site where if you are unsure of if a link is safe you enter the site link into the website and it will scan the link and see if its been reported as malicious with any search engines you can view the website Here.

So basically the other night I thought of an idea of creating a discord bot which does exactly the same but you can send a command in discord which will scan the link and give you results, I have been coding this bot today and I have finally gotten it to a stage where its good to tell the public about. I quite liked this idea because personally, I have not seen a discord bot before that offers this feature so this bot is unique. Currently, I am working on getting the formatting so it looks nice but I will be adding this bot to my public server later tonight (hopefully) if you haven’t already you can join my discord server Here. I may consider adding the feature into my main bot depending on how popular it gets.

At the moment when you do !scan (link) it takes approx 30 seconds to scan the link and then the bot will send a message saying “There is {Amount of positive results} Search engines that mark this site as unsafe” and then it will send a link with a detailed result of what search engines looked at the link and if it was malicious or not the link will be a haste-bin.

Currently, the bot is only hosted on glitch but when I get home from camping I will move the bot over to the VPS where it will be online 24/7. As I am writing this post I am still away camping I was planning on publishing this post tonight but I exceeded my wifi limit which refreshes at random points of the day (Weird campsite wifi) so I am unsure if this post will be published tonight, tomorrow morning or when I get home from camping. I am currently on my way home and when I arrive home I will make the final arrangements such as proofreading this post and will publish this post :P Of course if you are reading this post It would be home already and published it

How did I figure out how to get this bot working?

So originally I looked at the API for virus total and I specifically looked at the cURL API (curl) and then I copied and pasted this code into the terminal and replaced certain things such as the API token and the link it was scanning. So when I finally figured out what does what I found a node module for the virus total API so I installed it on glitch and tested this. originally when I ran the code I noticed that the bot error out, I knew this was because the bot was hitting the character limit so I thought of ways to get around this then realized I had a Pastebin command which uploaded any text into haste bin so I used parts of that code and added it into the scan command. After that, I noticed that the detailed message looked too cluttered so I decided to make it so the bot will give a brief summary then will post the link to the Pastebin website. And now I’m up to the stage I am now.

In the future, I may add the feature of being able to scan files such as download files once again it depends on how popular this bot gets.

Disclaimer

I am not responsible for any damages caused due to incorrect results, the results given may not be 100% correct. Some websites may not have been flagged if they are new. Please make sure if you are unsure that you have an antivirus and VPN connected when visiting suspicious sites.


I feel like this is one of my longest blog posts. Thanks for reading guys and I will see you later

Bencey