Framework for detecting and resisting cyberattacks on cyber-physical systems in internet of things | Synapse