I am a bit curious to know that when did lord indra asked for Kawach-Kundal to Karna? It's before Kurukshetra war or mid of war? Because while making link-up of many things related to karna's life, mostly I got confused.
As Hinduism is a living culture, its mythology is not just in texts but in the minds of the people, and there are various folk stories, family traditions, and even half-remembered distortions in memory, none of which I wish to discount. Perhaps "during the prelude to war", as Wikipedia claims citing some random book, seems the "logical" place to some, and no doubt that's what has been depicted in many movies and the like too.
But I can tell you what the Mahābhārata says. In the Mahābhārata, the narration of this incident is found near at the end of Book 3 (Vana Parva), before Book 4 (Virāṭa Parva). The incident itself occurs after the Pāṇḍavas' stipulated 12th year in exile and before their 13th year incognito — a full year before the war.
Here are some relevant passages from K. M. Ganguly's translation. Book 3, Section 298:
After twelve years (of their exile) had passed away and the thirteenth year had set in, Sakra [Indra], ever friendly to the sons of Pandu, resolved to beg of Karna (his ear-rings). And, O mighty monarch, ascertaining this intention of the great chief of the celestials about (Karna's) ear-rings, Surya, having effulgence for his wealth, went unto Karna.
And so on. After a few more sections of back-and-forth between Surya and Karna, and sections that relate Karna's birth and so on, the actual incident occurs in Section 307–308:
And when, O foremost of monarchs, Karna after rising from the water, used at mid-day to worship the effulgent Surya with joined hands, the Brahmanas used to solicit him for wealth. And at that time there was nothing that he would not give away to the twice-born ones. And Indra, assuming the guise of a Brahmana, appeared before him (at such a time) and said, 'Give me!' And thereupon Radha's son replied unto him, 'Thou art welcome!'"
And Indra asks him; there's a bit of bargaining, and finally the incident:
Hearing these words of Indra, Karna was filled with delight and seeing that his purpose was about to be accomplished he approached Vasava, and intent upon obtaining a dart incapable of being baffled, he addressed Indra, saying, 'Do thou, O Vasava, in exchange for my coat of mail and ear-rings, give me a dart incapable of being baffled, and competent to destroy hosts of enemies when arrayed in order of battle!' […] Thereupon, O king, taking the blazing dart, Karna began to peel off his natural mail. And beholding Karna cutting his own body, the entire host of celestials and men and Danavas set up a leonine roar. And Karna betrayed no contortions of face while peeling his mail. And beholding that hero among men thus cutting his body with an weapon, smiling ever and anon, celestial kettle-drums began to be played upon and celestial flowers began to be showered on him. And Karna cutting off the excellent mail from his person, gave it to Vasava, still dripping. And cutting off his ear-rings also from off his ears, he made them over to Indra. And it is for this fact that he came to be called Karna.
A second confirmation of the "when" in this question is provided short after:
Janamejaya said, "When were those heroes, the sons of Pandu, at that time? And from whom did they hear this welcome news? And what also did they do, when the twelfth year of their exile passed away? Do thou, O illustrious one, tell me all this!" Vaisampayana said, "Having defeated the chief of the Saindhavas, and rescued Krishna, and having outlived the entire term of their painful exile in the woods, and having listened to the ancient stories about gods and Rishis recited by Markandeya, those heroes among men returned from their asylum in Kamyaka to the sacred Dwaitavana, […]"
In the Critical Edition of the Mahābhārata, compiled by the Bhandarkar Oriental Research Institute, this passage (Book 3, section 308 in Ganguli's translation) occurs at 3.294. (You need a bit of Sanskrit to verify for yourself.)
It was during the prelude of the war. Indra was scared that since Karna was invincible with his armor, he would vanquish Arjuna. So, to protect Arjuna, he took the form of a Brahmin while Karna was worshipping Surya (Since he never refused charity at that time) and asked for his armor and earrings. Karna gave them to him at once, cutting them from his skin. Indra gave his weapon to Karna in return, for a single use.