Is this true for all states?
in general, yes. you’d have to check each state’s constitutions for particulars, but yes. state are divided into counties or parishes, and the sheriff is the top leo of the county. anything law-wise going on in the county can only occur wth the permission of the sheriff.
i would guess a lot of sheriff’s however do not operate this way or know that this technically is what powers they have over the feds. lots of times they don’t b/c they let the feds do what they want under ‘professional courtesy’.