It’d just be called collaboration instead of spying
Happens all the time, the NSA can't spy on US citizens to it asks GCHQ to do it for them, and vice-versa.
Kaspersky's software had been known for flagging US 3-letter-agencies' malware, so there's that...