A Cyber-physical system (CPS) is a complex system embedding advanced computation, communication and control techniques into physical spaces, and is usually built up with a set of networked agents such as sensors, actuators, control processing units, and communication devices. Although the development of CPS facilitates efficient and real-time collaboration between elements, the open nature of communication networks makes it rather vulnerable to malicious attacks. Given that the applications of CPSs vary from aerospace, transportation, power grids, which are always safety-critical, researcher have acknowledged the importance of designing the system with secure algorithms. This thesis first characterizes the properties required for a secure system and possible security threats. Driven by the concerns of deception attacks on communication channels, we study secure detection and control in adversarial environment. New Acronyms CPS Cyber-Physical System WSN Wireless Sensor Networks MAS Multi-Agent System i.i.d. independent and identically distributed