During the Fourth Ninja World War, Uchiha Madara manage to escape Edo Tensei by releasing himself and put himself in Edo Tensei again. But how or when did Madara knew about the hand seals of Edo Tensei?
It is not really stated how and when Madara learned to use ET.
But it is possible that during the battles between Senju and Uchiha, Madara had seen Tobirama use it. And since ET is not a bloodline jutsu, and Madara as top Uchiha ninja, he copied it with Sharingan's ability.
There are a few ways he could have learned it:
- Copying it from Tobirama
- Figuring it out himself
- Getting the information from a different source, like a scroll. Orochimaru learned ET from the scroll of forbidden jutsus.
There is no definite answer however. It has never been stated or shown how Madara learned ET.