TL;DR: Invincibility by itself is neither dharma nor adharma. But what you do with it will decide if you are following dharma or adharma.
First off, what is dharma?
In Karṇa-parva of the Mahābhārata, Kṛṣṇa explains dharma to Arjuna as:
dhāraṇād dharmam ity āhur dharmo dhārayati prajāḥ
yaḥ syād dhāraṇa saṃyuktaḥ sa dharma iti niścayaḥ
Dharma protects and preserves the people. So it is the conclusion of the pandits that what maintains is Dharma.
In Śānti-parva, Bhīṣma responding to Yudhiṣṭhira's query 'How should a person act who desires to adhere to virtue?' says:
tādṛśo 'yam anupraśno yatra dharmaḥ sudurvacaḥ
duṣkaraḥ pratisaṃkhyātuṃ tarkeṇātra vyavasyati
The question you have asked me is a difficult one, since it is difficult to say what righteousness is. It is not easy to indicate it. No one in discoursing upon righteousness, can indicate it accurately.
prabhāvārthāya bhūtānāṃ dharmapravacanaṃ kṛtam
yat syād ahiṃsāsaṃyuktaṃ sa dharma iti niścayaḥ
dhāraṇād dharma ity āhur dharmeṇa vidhṛtāḥ prajāḥ
yat syād dhāraṇa saṃyuktaṃ sa dharma iti niścayaḥ
Righteousness was declared (by Brahman) for the advancement and growth of all creatures. Therefore, that which leads to advancement and growth is Righteousness. Righteousness was declared for restraining creatures from injuring one another. Therefore, that is righteousness which prevents injury to creatures. Righteousness (dharma) is so called because it upholds all creatures.
Kaṇāda in his Vaiśeṣika Sūtras defines dharma as:
यतोऽभ्युदयनिःश्रेयससिद्धिः स धर्मः ॥ १ । १ । २ ॥
Dharma (is) that from which (results) the accomplishment of Exaltation and of the Supreme Good.
That which leads to the attainment of Abhyudaya (prosperity in this world) and Nihsreyasa (total cessation of pain and attainment of eternal bliss hereafter) is Dharma.
Is invincibility dharma or adharma?
Invincibility by itself is neither dharma nor adharma. But what you do with it will decide if you are following dharma or adharma.
Example 1: Knife (doctor, thief and housewife)
- A doctor with his knife and scissors can cut open the wounds of a patient to remove an infectious growth and then stitch up the patient. Now assume a similar knife is in possession of a thief who uses it to threaten people and steal their wallets; once in a while he may even kill someone trying to get away after a robbery. Further, a housewife could use her kitchen knife to attack an intruder who was trying to kidnap her baby. The object, knife, is the same in all three cases. However, the doctor has used his knife merely as tool for very good cause (to save a patient's life). Whereas the thief totally misused it, inflicting pain on others, for his own personal gain. While the housewife faced a totally unexpected situation and used the knife to scare away the kidnapper.
Example 2: Gun (soldier, terrorist and civilian)
- Soldiers in the military are usually equipped with guns. They get trained to use guns to use in warfare someday. It is the duty of a soldier to use gun in battle; he may also end up killing soldiers of the opposite side. The same gun could end up in the hands of a terrorist and he might use it to kill innocent civilians. Now some countries like the US allow civilians to own guns, so, assume a man buys and keeps a gun at home for safety reasons (e.g., to protect his family from grizzly bears or burglars). But one day he gets really upset with his nagging wife and shoots her to death with the same gun he bought to keep his family safe. Like the above example, here too, the object, gun, is the same in all three cases. Yet, it was used by different people for different reasons.
In the above two examples, the problem is not with the knife or gun itself but who used it and for what purpose. Let's see which of the above can be classified as dharma and which as adharma.
Clear Case of Dharma
Clear Case of Adharma
The thief was in the wrong profession to begin with and carrying a knife only made matters worse for him and the people he came in contact with.
Terrorist was not authorized to possess a gun nor shoot unarmed civilians. He violated many established norms and rules.
Dharma-sūkṣma (subtle dharma)
The housewife only tried to protect her baby from the kidnapper. She never imagined herself in this situation, so, she did what she had to, to protect the baby. Even if it meant taking a stab or two at the intruder with her kitchen knife. It's her dharma to protect the baby and herself at any cost. So after some analysis, we conclude that she was right.
The man (or householder) was authorized to keep a gun at home. If he had shot a burglar who tried to steal from the house or hurt his wife or kids, he would be justified doing so. But since he misused the weapon to shoot his unarmed wife, he committed an act of adharma.
Invincibility is also like the knife and gun in the above examples. If used for all the wrong reasons that would be adharma.
Is invincibility in battle adharma?
As explained above, invincibility by itself is not adharma. In a battle, to one who has it, invincibility will be like a special weapon which can be put to good use.
Take the case of Hanumān from Rāmāyaṇa. He had boons of chiranjīvi (by Indra) and that no weapon can kill him (from Brahma):
"Oh, chivalric warrior at war, while the Air-god is being supplicated, oh, dear boy, Brahma gave you a boon decreeing your 'indestructibility by any missile...' [4-66-27]
On scrutinizing that you are unhurt even after hit by Thunderbolt, oh, ablest Hanuma, the Thousand-eyed Indra kind-heartedly gave you a choicest boon saying that your death occurs only by your own volition... [4-66-28, 29a]
Hanumān took full advantage of his powers. As mentioned in Sundara Kāṇḍa, he was once attacked by a Brahmāstra launched by Indrajit but the weapon couldn't do much damage; it only made him immobile. He recovered from it and carried the message of Sita's location to Sugrīva and Rāma.
He was almost killed by Rāvaṇa in the main war, but due to his chiranjīvity he once again recovered from Rāvaṇa's blow. He later went on to bring the mṛta-sañjīvanī herbs to save the lives of Rāma, Lakṣmaṇa and the vānaras.
If having these kinds of boons is dharma (i.e., allowed) then why should such warriors be defeated using adharma?
The simple reason why adharma (backed by someone's invincibility) has to quashed by any means is to uphold dharma by all means. Although on the surface, Rāma's killing of Vāli, Lakṣmaṇa disrupting Indrajit's yajña, Arjuna defeating Bhīṣma with help of Śikhaṇḍī, etc., may all seem like adharma, they can be classified as sūkṣma-dharma (subtle dharma) as I explained above.
Also, from this answer, as Bhīṣma again explains:
यस्मिन्यथा वर्तते यो मनुष्य: स्तस्मिंस्तथा वर्तितव्यं स धर्मः ।
मायाचारो मायया वर्तितव्य; साध्वाचार साधुना प्रत्युदय ।।
yasmin yathā vartate yo manuṣyas; tasmiṃs tathā vartitavyaṃ sa dharmaḥ ।
māyācāro māyayā vartitavyaḥ; sādhvācāraḥ sādhunā pratyudeyaḥ ।।
One should treat another as the latter does to him. A deceitful person should be thwarted with deceit, while an honest man should be treated with honesty.