That's like saying it's fine to beat someone up and take their lunch, but it's not fine to learn how locks work.
I can develop security exploits myself just fine without the use of AI. Many people don't have the capability to use Photoshop and free online porn to deepfake someone else they might or might not personally know into a realistic video...