Answer the question
In order to leave comments, you need to log in
How to recognize URLs of porn sites?
I am writing a telegram bot, on nodeJS, one of the functions of which will be to delete messages that contain adult site addresses. The first thing I came up with was to simply write all the domains of such sites into a json file, import and check links for compliance, but this solution seemed complicated and unreliable to me. Is there a better solution? Thank you in advance.
PS: is-porn library - r#&*+
Answer the question
In order to leave comments, you need to log in
I think the best option is to programmatically follow the link and analyze the keywords that are always in the meta tags or the body of the page.
Only following the link, checking for forbidden words, adding a domain to the database table where prohibited sites, from the same table, bot 2 takes domains and checks for presence in another database table, if a match is found, it deletes it.
But there are link shortening services and redirects.
The bot must add to the database not the final domain, but the one that it went through, otherwise it will not work.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question