This document proposes a distributed trusted agent-based approach (DTADA) to detect and defend against cloning attacks and sinkhole attacks in wireless sensor networks. DTADA uses mobile agents that can move between nodes to detect attacks in a distributed manner without relying on a centralized authority. The mobile agents are programmed to identify inconsistencies that would indicate a cloning or sinkhole attack has occurred. The document reviews related work on centralized and local detection methods and their limitations. It then describes how DTADA uses mobile agents to efficiently detect attacks in a distributed way without high communication or energy costs.