The task of performing trustworthy computation in a network of autonomous agents in the presence of misbehaving components is the subject of this work. A solution to this problem is relevant for several coordination, formation, and synchronization tasks. Relying only on the information flow of the control protocol, uncooperative behaviors are revealed using an unknown input observer technique. Necessary and sufficient conditions to detect and correctly identify misbehaving nodes are given, together with a study of the genericity of such conditions. It is shown that generically any node of the network can correctly estimate the state of the other agents, and therefore compute any function of the state, provided that the connectivity of the communication graph is strictly greater than the number of misbehaving nodes. An intrusion detection and identification algorithm is described, and its effectiveness is confirmed through a numerical study.