A bit late to the party, but I just ran across this question and also an answer to it in Luther's sermons that I thought might be a helpful contribution. The flowing is an excerpt from Luther's commentary on Matthew 5:33-37:
This text has been spun out with many glosses, and many a queer notion and error has been drawn from it, so that many great doctors have been worried about it, and could not become reconciled to the blunt prohibition here that we are to “Swear not at all,” but “let your communication be Yea, yea, and Nay, nay.” So that some have stretched their conscience so tightly, that one doubts whether one ought to take a solemn oath not to avenge himself when he is set free from prison, or whether we are by an oath to make peace and a treaty with the Turks or unbelievers, etc. Now we cannot deny that Christ himself and St. Paul often took an oath; besides, it is said, in the Scriptures, that those are praised who swear by his name; so that also here we must make a distinction, so that we rightly understand the text.
But we have been told sufficiently, that Christ does not wish here to interfere with the secular authority and ordinance, nor to detract at all from the powers that be; but he is preaching here only for the individual Christians, how they are to conduct themselves in their ordinary life.
Therefore we are to regard the swearing as forbidden in exactly the same sense as above the killing and the looking upon or desiring a woman.
Killing is right, and yet it is also wrong; to desire a man or a woman is sin, and it is not sin; but in this way, that we rightly distinguish both, namely, that it is said to you and to me: if you kill, you do wrong; if you look at a woman to desire her, you do wrong. But to a judge he says: If you do not punish and kill, you shall yourself be punished; likewise to a married man or woman: If you do not cleave to your spouse, you do wrong. So both are right, that one is to kill and not to kill, to be and not to be with a woman; namely, that you do not be wrathful or kill, or look lovingly upon a woman, unless you are specially authorized by God’s word or command to do so. If you are wrathful, however, when God commands you, or if you have a wife according to the word of God, then each is right; for what God says and commands is a very different thing from when you do it of your own accord.
As you have understood that, so understand this also; that the prohibition here is, “Swear not at all,” just as he has entirely forbidden killing, so that there may be no wrath in the heart; in like manner, that we shall keep so aloof from man and woman as not to be looking at them, or thinking upon them to desire them. And it would be a dangerous sermon if we were to apply it to the exercise of governmental authority or to married life, and were to say to the judge, Thou shalt not become indignant, or give practical proof of wrath; or to a wedded pair, Thou shalt not look upon or love thy wife or husband: but we must turn about here and teach the opposite, saying: Thou judge shalt be angry and punish; and every one shall have and love his spouse. How then does Christ say one must desire no woman, and have no wrath in his heart? Answer, as said above, he is speaking of the woman that God has not given you, and of the wrath that is not demanded of you, that you are not to have. But if it is demanded of you, then it is no longer yours, but it is God’s wrath, and no longer your desire, but that which is given and ordained by God; for you have God’s word for it that you shall love your spouse and not desire any other. Thus also in regard to swearing; we must see to it, if we have God’s word for it or not.