Unlikely. You have the origin mixed up. The spy satellites came first, and then Hubble.
The shared mirror size is not a coincidence: https://en.wikipedia.org/wiki/KH-11_KENNEN#Size_and_mass
The two also share a multi-billion dollar budget.
https://www.precisioncontent.com/blog/on-rocket-ships-and-ho...
https://www.space.com/34522-secret-shuttle-missions.html
https://launiusr.wordpress.com/2012/11/12/nasas-space-shuttl...
https://en.wikipedia.org/wiki/Category:Department_of_Defense...
The Hubble design was remarkably close to Keyhole:
https://space.stackexchange.com/questions/3448/was-hubble-re...
Keyhole satellites were seriously cool. Photos were taken on film, and the film reels were jettisoned over the ocean. C-130 transports would capture the payloads as they parachuted back to earth:
https://www.cnn.com/2016/09/01/us/declassified-spy-satellite...
Wouldn't that depend on how much dynamic range it has? Webb is intended to look at very dim signals in space so Earth would blind it, but if a spy-Webb were intended to track rocket or jet engines, things quite hotter than the rest of earth, perhaps it might be capable of that?