John Major - also thought that most of his colleagues were bastards.
As has already been pointed out by wiser people than myself*, it is quite likely that most ordinations were also invalid - we can give you a list of prime suspects on request - not to mention Masses, Reconciliation (Penance), etc.
*wiser, but less saved, perhaps.
Having spent the three years of his papacy in accusing Catholics of particular sins (Pope Francis has a particular objection to holiness, faithfulness, honesty, truthfulness and orthodoxy), the Holy Father has now decided to "go for broke" by issuing this general Commination on his Church.
"O God! I've just insulted my own parents!"
Some critics (not us) have responded by suggesting that certain papal conclaves were invalid, because either Cormac Murphy-O'Connor and his mates interfered, or simply because the the cardinals ended up electing a rather dim person who didn't understand canon law. I expect that dear brother Mundabor could tell you more.
However, we should remember that the choice of the Pope is made by the Holy Spirit, possibly influenced by the Spirit of Vatican II, and that God moves in a mysterious way His wonders to perform. He plants His footsteps in the sea, and rides upon the storm. After one saintly Pope, and one very learned Pope, it is clear that the time had come for the Church to be led by someone very different. You got it.