They are sealed away behind a mighty wall by a legendary king, Dhul al-Qarnayn who is frequently linked to Alexander the Great and occasionally Cyrus the Great, though neither are exact matches
In Islamic eschatology, the world will be flooded by a mighty invasion in the end of days.
The great army of the monstrous Yajuj and Majuj (Gog and Magog) will rampage throughout the earth.
A thread-
They are sealed away behind a mighty wall by a legendary king, Dhul al-Qarnayn who is frequently linked to Alexander the Great and occasionally Cyrus the Great, though neither are exact matches
Thus sealed away, the world is safe from Yajuj and Majuj, that is, until the end of days.
When they stand in formation their army stretches from Syria to ends of Persia.
They will swarm the Earth, until it becomes difficult to find food and water. Then Isa (Jesus) who had returned, will ask God to intervene.
The mightiest army will by laid low by the tiniest bugs.
They are frequently treated as monstrous humans. A tradition from ibn Abbas deems them as inhuman, different from human and jinn both.
Written descriptions say they are covered in great ears.
The wall holding them back is generally associated with places like Armenia, or Ibn Battuta may have linked it to the Great Wall of China.
He quickly dispatched an emissary to ensure the wall was still intact.
Artistic rendering of the building of the wall show jinn and human working together to build it—a reminder of how great the threat of Yajuj and Majuj was for human and jinn alike.
They postulated the world would come to an end and the armies of the Yajuj and Majuj unleashed when all the planets aligned in Pisces.
It also provides an important insight into medieval imagination of geography, conceptions of the other, and the boundaries of empire