Addressing the trends of digitalization, decentralization, democratization, and decarbonization, local peer-to-peer (P2P) markets have the potential to significantly accelerate decarbonization at the communal level. However, due to an increase in the number of energy consumers, such as electric vehicles or heat pumps, grid congestion can occur since actual low-voltage grids are not designed to transmit large loads. This paper introduces a novel concept for a platform to combine the advantages of P2P trading with the need for secure, automated low-voltage grid control, ensuring effective congestion management. Therefore, a dual local energy market has been developed, comprising a P2P energy market and a flexibility market with the latter ensures preventively managing congestion. Furthermore, mechanisms exist to provide curative, real-time congestion management. Additionally, the platform empowers prosumers, i.e. end users that produce and consume electrical energy, with intelligent market strategies to maximize their financial outcomes by participating in both markets. To provide a secure trading mechanism, the novel concept of Self-Sovereign-Identity is integrated into the platform. Tested in a smart grid laboratory at the University of Wuppertal, the platform provides financial gains for prosumers and effectively manages current-and voltagerelated grid congestions.