Inspired by What is this idiom: "I'm going to start taking names and..."?, but that question doesn't actually ask for where the expression originated. I Googled around, but couldn't find any reliable source. Surely the expression originates in a major or cult movie or literary work of some kind or another?
People ain't buying that shit no more. We're checking Whitey out, telling him his system is corrupt, it stinks. Black people are ready to kick ass and take names .
Edit: Sorry. I spoke too soon. Here's a citation from five years earlier from The Green Berets by Robin Moore (1965):
He's out kicking ass and taking names everywhere. He found Ling for me and that stud is a tiger. Harvey eyed the bulge in my pack. 'Now, you piker, how about a little of that celebration?'
It appears ass kicking itself dates back to the early '40s and the phrase having as much chance as a one-legged man in a mule/butt/ass-kicking contest. The similar expression kick in the pants dates to the late 1800s.
I just antedated the 1965 reference by 11 years. This is from John Oliver Killens' 1954 novel Youngblood:
Man ain't you heard? After Joe Louis whupped that cracker, some crackers came down here wanted to turn Harlem Avenue out. Boy, some young Negroes started kicking asses and taking names. Some Negroes tried to get on the bus to Pleasant Grove and the bus driver wouldn't let them on, and they turned the damn bus over and upside down.
This is a military term, specifically Navy, and the exact unit is the Navy military police, or Shore Patrol.
Origin was based on shore-leave: it is the job of the SP to patrol and manage crimes and other behavioral problems of Naval personnel, preferably before they happen-- but to deal with them effectively when they do happen.
After a fight, the SP will sequester the "ringleaders" and confiscate their ID cards long enough to make official note of who they are.