In the case of ZigBee (or Z-Wave), devices have the ability to talk to each other and to the controller. But they don't directly have the ability to talk outside the mesh, even if something like the hub has Internet access.
Home Automation
Home automation is the residential extension of building automation.
It is automation of the home, housework or household activity.
Home automation may include centralized control of lighting, HVAC (heating, ventilation and air conditioning), appliances, security locks of gates and doors and other systems, to provide improved convenience, comfort, energy efficiency and security.
Warning: Working with electricity can result in injury, property damage, or even death if it is not done properly. Please keep this in mind while assisting others. If you are not sure about what you are doing, hire a licensed professional.
Rules
- No abusive behaviour. This is a forum for friendly discussion; personal attacks will not be tolerated and you will be banned without warning.
- Referral/affiliate links are NOT ALLOWED!
- NO POLITICS! There are plenty of other communities to discuss them; this is not one.
- When posting project details must be included. Posting a video or image without detail will result in a removed post and may result in a ban.
- Crowdfunding links are not allowed.
- Reposts, low-effort content and karma farming may be removed at the discretion of the mods. Posters may be banned without warning.
On top of ZigBee/zwave/other protocols, I would recommend setting up pihole or some other similar traffic blocker so that you can control what is allowed in and out of your network
My question is what stops the devices that are integrated with HA from talking to some random cloud server) ?
You can use your firewall/router to stop any if your networked device to go to the internet.
Proper isolation is what stops them.
HA/IoT should be on it's own isolated SSID (wifi name) and Vlan with only the hub connecting to it. This becomes the one thing you have to trust but between open source and reputable vendors you have plenty of choices here. It's also the device that provides a modicum of security since you can keep it up to date.