Combining 内 (inside) and 奸 (traitor) gives you the very direct and literal meaning of an “inside traitor” or “internal villain”—a mole.
The concept of the 内奸 strikes a particularly sensitive chord in Chinese culture, which places a high value on loyalty (忠诚, zhōngchéng) and group cohesion. The ultimate betrayal isn't just from an enemy you expect to fight, but from a trusted member of your “in-group” (自己人, zìjǐrén).
The term 内奸 is serious and highly negative. It's not used for minor tattling. It implies significant consequences and a deliberate, malicious act of betrayal.