Which work/passage could Rand be paraphrasing? Where can this, or a similar, idea be found in Kant's works?
This probably refers to the infamous "murderer at the door" passage from Kant's essay On a Supposed Right to Lie from Philanthropy (1797), written near the end of his life. The essay was a response to Constant who offered the following criticism:
"The moral principle, “it is a duty to tell the truth” would, if taken unconditionally and singly, make any society impossible. We have proof of this in the very direct consequences drawn from this principle by a German philosopher [Kant], who goes so far as to maintain that it would be a crime to lie to a murderer who asked us whether a friend of ours whom he is pursuing has taken refuge in our house."
In the 20th century it was dramatized into a hypothetical of someone lying to the Nazis to save the victim from impending death. Kant seemed to emphatically prescribe telling the truth instead, and it became a reductio ad absurdum of his position.
There is some ambiguity in what he actually says, the essay deals more with legal responsibilities than with moral ones, and Nazis would probably not be a legitimate authority in his eyes, for example. And in The Metaphysics of Morals, Kant carefully distinguishes between law and virtue, and rejects the idea that justice is an enforceable part of moral duties. Varden mounts a defense in Kant and Lying to the Murderer at the Door based on such considerations. Also, we should not forget that such rhetorical hyperbolism was not uncommon historically, suffice it to recall Fiat iustitia, et pereat mundus (let the world die but the justice prevail).
Still, Kant's general tendency towards moral absolutism in ethics is unquestionable, and the "murderer at the door" became a crude symbol of its untenability in the eyes of many, as Constant already took it to be. Here is a part of Kant's passage:
"If you have by a lie prevented someone just now bent on murder from committing the deed, then you are legally accountable for all the consequences that might arise from it. But if you have kept strictly to the truth, then public justice can hold nothing against you, whatever the unforeseen consequences might be. It is still possible that, after you have honestly answered “yes” to the murderer's question as to whether his enemy is at home, the latter has nevertheless gone out unnoticed, so that he would not meet the murderer and the deed would not be done; but if you had lied and said that he is not at home, and he has actually gone out (though you are not aware of it), so that the murderer encounters him while going away and perpetrates his deed on him, then you can by right be prosecuted as the author of his death... Thus one who tells a lie, however well disposed he may be, must be responsible for its consequences even before a civil court and must pay the penalty for them, however unforeseen they may have been; for truthfulness is a duty that must be regarded as the basis of all duties to be grounded on contract, the laws of which is made uncertain and useless if even the least exception to it is admitted."