I don't know. Generally, it seems to me (perhaps to others), that, when you want to find a rule for what is allowed in the extreme cases, you would have to search for examples that were widely accepted. For example, suppose someone finds a case of a midwife who baptizes a dying baby, and then, the baby recovers, and the Bishop and Synod say, "The baptism should not be repeated". Someone, could always say, 'the Synod was wrong.' But, if, let's say, that man became a priest and bishop, and a glorified saint, venerated widely, it would demonstrate, that, in extreme cases, with the Church's permission, a woman, as a last case, can baptize an infant who is dying, assuming no man is there, whatsoever. Otherwise, we would be forced to denounce the man's priesthood, and saintliness. Now, I don't know if that is the case anywhere. I'm just say, "for example", if one can be found.
Though, I seem to recall, somewhere, and I am not sure where, reading that midwives did baptize dying children, and the children were given funeral rites appropriate for an Orthodox Christian. If I ever come across this again, I will post it.
One poster, already, did say he had heard of a woman being told that she could baptize someone in extremis. Yet, I think, by in extremis, we are counting someone on their death bed with little time left, someone on their deathbed who may dye before the deacon or priest gets there, or a man, or a child dying before a priest, deacon, or another man can be reached.
I believe, in the Fourth Council of Carthage, it categorically forbade women to baptize. The power belongs to the Priesthood, and, a man may baptize in exteme, because he belongs to the class that may possibly be capable of the powers of the Priesthood. In much of the Canons and writings of the Church's rules, it may sometimes seen that contradiction may appear; that is, for example, it may say in one place that 3 bishops are need for ordination of another, while, we read of accounts of saints and councils saying two, or even one, can do such; what are we to think? Obviously, the Fathers made stringent rules, and did not generally put in 'except' clauses, even though such clause may be possible. Why? possibly because with an 'except' clause formulated as a principle, it would mean people would be more likely to draw on such a codification to justify much that should not be done.