Recently we have found that WordPress, the most used website CMS has been carrying a bug within the main source code. From 5.0.3 release WordPress team has fixed the issue. So if you are a webmaster using WordPress, please upgrade it to the latest version.
What will happen if I don’t upgrade my WordPress?
Easily some hackers can enable the codex in your WordPress directory even if your website indexes are closed within a really easy SQL Injection and then your website will be redirected into another URL.
What should I do if my site has been kacked?
Before you do anything you should make a backup through your files in wp-content/uploads and make sure there are no external files in there. Then go to the main WordPress directory and backup wp-config.php then open it and make sure there are not any unknown codes in the file. Don’t forget to write down your theme name.
Next step is to clear the public_html (Main directory). Then download the latest version of WordPress from here and then upload it to your public-