Terminate with extreme prejudice

I know this is a military term that means in effect
to "execute" or kill. But I am curious as the origin
of such words. As an American living abroad I am now
finding myself questioning phrases that I always took
for granted, mainly because they are idioms and are not
translatable..

Thanks


Andy

TERMINATE WITHEXTREME
Murdering an agent who has outlived his usefulness, per spy novelists and movie writers. The term has never been used by any intelligence professional, espionage mythologists notwithstanding.
From _The Dictionary of Espionage: Spookspeak into English_ by Harry S.A. Becket
----------
"A few years ago when he wanted an agent out of the organization he ended up dismissing him with extreme prejudice." "You mean he had him killed?" Ted nodded. (B. F. Conners, _Don't Embarrass Bureau_, 1973)
"There is no question of anyone killing anybody." "There is. I'm asking it. Terminate with extreme prejudice?" (W. Garner _Big Enough Wreath_, 1974)
A "termination with extreme prejudice," as the CIA called its assassination projects in those days. (C. Pincher _Dirty Tricks_ 1980)