Reese Witherspoon put her checkered (and awesome) past with cops behind her today ... and donned a police uniform ... right here on American soil!

Reese is playing a police officer in her new movie, "Don't Mess With Texas" ... alongside Sofia Vergara. They're filming down in Louisiana -- where Reese recently did some Karaoke with Kenny Chesney.

Sofia definitely looks like she needs to be frisked, but Reese ... make sure you know her name before slapping the cuffs on her.

Who's obstructing whose justice now?

