The details of the first 2 Stages of Purification can be found in the Graduated Training which occurs many times thruout the suttas.
The last 5 Stages - the 16 Insight Knowledges are briefly sketched in many places in the suttas as
Disenchantment
Dispassion
Calm, Tranquility
Higher knowledge
Insights [of the higher stages of the Path]
Nibbana
The most detailed exposition of the Insight Knowledges found in the suttas is in SN 12.23 - Upanisa Sutta (Transcendental Dependent Arising).
And finally, these Seven Stages form the outline for the Visuddhimagga (Path of Purification), the commentary from about 500 AD. Each stage is discussed in detail and the Insight Knowledges (the last 5 Stages) are dicussed quite excellently in Chapters 18 - 23.
Notice that only 1 of the 10 imperfections is an unwholesome state and that 3 of them are even factors of awakening. It's misunderstanding these occurances that is the imperfection, not the states themselves.