...the applicable paragraphs from the Catholic Encyclopedia entry on Celestine V, the Pope who set the precedent that it was possible to resign ("Cardinal Gaetani" was the name of Boniface VIII before he become Pope, succeeding Celestine):
...That the idea originated with Cardinal Gaetani the latter vigorously denied, and maintained that he originally opposed it. But the serious canonical doubt arose: Can a pope resign? As he has no superior on earth, who is authorized to accept his resignation? The solution of the question was reserved to the trained canonist, Cardinal Gaetani, who, basing his conclusion on common sense and the Church's right to self-preservation, decided affirmatively.
It is interesting to notice how curtly, when he became Boniface VIII, he dispatches the delicate subject on which the validity of his claim to the papacy depended. In the "Liber Sextus" I, vii, 1, he issued the following decree: "Whereas some curious persons, arguing on things of no great expediency, and rashly seeking, against the teaching of the Apostle, to know more than it is meet to know, have seemed, with little forethought, to raise an anxious doubt, whether the Roman Pontiff, especially when he recognizes himself incapable of ruling the Universal Church and of bearing the burden of the Supreme Pontificate, can validly renounce the papacy, and its burden and honour: Pope Celestine V, Our predecessor, whilst still presiding over the government of the aforesaid Church, wishing to cut off all the matter for hesitation on the subject, having deliberated with his brethren, the Cardinals of the Roman Church, of whom We were one, with the concordant counsel and assent of Us and of them all, by Apostolic authority established and decreed, that the Roman Pontiff may freely resign. We, therefore, lest it should happen that in course of time this enactment should fall into oblivion, and the aforesaid doubt should revive the discussion, have placed it among other constitutions ad perpetuam rei memoriam by the advice of our brethren."
When the report spread that Celestine contemplated resigning, the excitement in Naples was intense. King Charles, whose arbitrary course had brought things to this crisis, organized a determined opposition. A huge procession of the clergy and monks surrounded the castle, and with tears and prayers implored the pope to continue his rule. Celestine, whose mind was not yet clear on the subject, returned an evasive answer, whereupon the multitude chanted the Te Deum and withdrew. A week later (13 December) Celestine's resolution was irrevocably fixed; summoning the cardinals on that day, he read the constitution mentioned by Boniface in the "Liber Sextus", announced his resignation, and proclaimed the cardinals free to proceed to a new election. After the lapse of the nine days enjoined by the legislation of Gregory X, the cardinals entered the conclave, and the next day Benedetto Gaetani was proclaimed Pope as Boniface VIII. After revoking many of the provisions made by Celestine, Boniface brought his predecessor, now in the dress of a humble hermit, with him on the road to Rome. He was forced to retain him in custody, lest an inimical use should be made of the simple old man. Celestine yearned for his cell in the Abruzzi, managed to effect his escape at San Germano, and to the great joy of his monks reappeared among them at Majella. Boniface ordered his arrest; but Celestine evaded his pursuers for several months by wandering through the woods and mountains. Finally, he attempted to cross the Adriatic to Greece; but, driven back by a tempest, and captured at the foot of Mt. Gargano, he was delivered into the hands of Boniface, who confined him closely in a narrow room in the tower of the castle of Fumone near Anagni (Analecta Bollandiana, 1897, XVI, 429-30). Here, after nine months passed in fasting and prayer, closely watched but attended by two of his own religious, though rudely treated by the guards, he ended his extraordinary career in his ninety-first year. That Boniface treated him harshly, and finally cruelly murdered him, is a calumny. Some years after his canonization by Clement V in 1313, his remains were transferred from Ferentino to the church of his order at Aquila, where they are stillthe object of great veneration. His feast is celebrated on 19 May.
http://www.newadvent.org/cathen/03479b.htm