Don’t give them your boss’s name. Give them a coworker’s name. Give them a friend’s name and have them lie for you.
If a company is proactively contacting people you don’t give them contact information for, that’s not requiring references — which is the process I (and the comment I replied to) was talking about. If a company knows where you’ve worked, they can contact them if they want.