Likewise the YouTube algorithm helps many people, but criminals or unwanted people (like pedophiles) can also use it.
It's ok to think about ways to prevent it, but I don't think it should be the first concern. Imagine outlawing telephony, because criminals could benefit from its use.
Telephone service providers were monopolies, sometimes government monopolies. There was only one type of telephone you could use, and that was supplied by that same monopoly. It was illegal to attach anything else to the line either directly or indirectly. There were even (outside the US) laws on what you could say when talking on the phone.
Here's an article from 1994 about a modem maker who had products that were not officially licensed to connect to the network. https://www.newscientist.com/article/mg14219263-000-technolo...