We often project our current political concerns backwards in time in order to justify ourselves. I say ‘we’ because everyone does it. Nazi Germany invented a mythical blonde Aryan people who had always been kept down by lesser breeds. The Hindu nationalists in India imagine that Hinduism has always been a centralised doctrine rather than a conglomerate of texts and local traditions, and describe Muslim, Buddhist, Christian, Sikh, Jain and animist influences on Indian history as foreign intrusions. Black nationalists in the Americas depict ancient Africa as a continent not of hunter-gatherers and subsistence farmers but as a wonderland of kings and queens, gold and silk, science and monumental architecture. To our current cost, Zionists and the neo-cons have been able to reactivate old Orientalist myths in the West, myths in which the entirety of Arab and Islamic history has involved the slaughter and oppression of Christians, Jews, Hindus, women, gays, intellectuals .. and so on.
Such retrospective mythmaking frequently goes to the most absurd extremes in young nations conscious of their weakness or of a need for redefinition (America may be one of these). Probably for that reason it is particularly evident in the Middle East.
Many Muslims go beyond adherence to those concepts and taboos that are necessary for religious belief and idolise or demonise historical figures who have nothing to do with the divine revelation. For many Sunnis, the first caliphs were ‘rightly guided’ saints who could do no wrong. During their reign there was no crime, poverty or injustice in the realm of Islam. For many Shia, the same men (apart from Ali) were decadent criminals. These secular figures were not deities or prophets but human beings working in specific contexts, with all the good and bad and moral ambiguity that implies, but Muslims frequently hold religious positions on their worth. The same applies even to later worldly figures like Haroon ar-Rasheed (saint or criminal) and Salahuddeen al-Ayubbi (likewise; as well as Kurdish traitor and hero of Arabism).