Is it possible to run the tool called BeEF to do penetration testing on real domains like example.com? As far as I know, BeEF can only be used within localhost.
I can only test my site for XSS on the real domain because of the database running.
Information Security Stack Exchange is a question and answer site for information security professionals. It only takes a minute to sign up.Sign up to join this community
Yes, it's absolutely possible to use this tool in public...
Beef is a browser exploitation tool, not a server exploitation tool. If you use beef to attack browsers of other people, who have not given explicit consent to being attacked, then you are likely committing an unlawful act, depending on your jurisdiction.
So yes, technically it is possible. But no, it is likely not lawful and I would recommend against doing it.