The way this usually happens is someone decides to create a device, in order to be able to access it and program it they give it an embedded controller listening to some port on a local area network. Next up someone installs a gateway that starts to assign NAT'd or public IPs to devices and boom suddenly that box is now wide open to whoever stumbles upon the IP. This has caused a whole raft of problems with embedded systems that were built before people were more security conscious.
The real problem is that the end users are more often than not totally unaware that their stuff is exposed to the world until something bad happens.
The real problem is that the end users are more often than not totally unaware that their stuff is exposed to the world until something bad happens.