Worf believes Starfleet and by extension the Federation to be honorable institutions else he would not be a part of them. Worf believes Klingon society to be honorable, despite his own personal experiences with the Empire. He would not have resigned from Starfleet to fight in the Klingon civil war if he felt otherwise.
Worf's judgments are mostly cultural, not racial. Clearly he has a deep hatred of the Romulan Empure for slaughtering his parents at Khitomer. But Romulans and Cardassians are also deemed to be without honor because their societies do not seem to value personal honor as a central and guiding principal of individual behavior. Treachery seems much more acceptable to them as a path to success and advancement. Because of this Worf takes a dim view of all Romulans and Cardassians instead of assuming the ones he's met have been outliers or a few bad actors. Look around at today's societies and you'll see similar demonization of groups who live by different moral codes, so Worf's uncompromising personal stance is not novel by any means.