Seriously, do you think Iran is not at war with us?
If the govt of IRAQ withdrew accreditation from this "consulate" (if that is, indeed, formally, what it was) then it is fair game and must have been a hi value target given the rapid raid.
The rules of diplomacy cut both ways and restrict diplomats from using their facilities and diplomatic cover to be used to conduct military operations against the host country.
Yup, since November, 1979. Time the US took the gloves off.
Counsulates are equivalent to KFC's. Only embassies have extra territorial status as far as I know, and then again not even embassies where the current Iranian regime is concerned.