I think it's time to get rid of the "you always become wanted for firing at an unscanned ship, even if it turns out to be in fact wanted" rule once for all. It's stupid beyond belief.
Imagine the communication between the pirate ship and the authorities:
"This is Jabba the Hutt speaking, I'm a dangerous criminal, wanted in 586 systems. I'm currently in a Res site, shooting at an innocent novice miner. I'm also being shot at by a bunch of cops at the same time. There is a clean BHer CMDR here, who scratched my shield 0.5 ms before his scanner fiinished with scanning me. Please put a bounty on his head for the heinous crime he committed. Jabba the Hutt out."
"All right Mr Hutt, we're always glad to help you."