Pope Nicholas II issues the papal bull In nomine Domini ("In the name of the Lord") on reforming the election of popes. When he himself was elected pope in 1058, he decided to make it a priority to reform how popes are chosen.
One major change is that popes can only be elected by cardinals. This takes away from secular rulers any direct say on who can or should become pope. It also helps establish the preeminence and power of cardinals in the church.
Another provision is that any election of an antipope should be "subjected, as Antichrist and invader and destroyer of all Christianity, to a perpetual anathema."