Is that a pistol in your G-string, or are you just glad to see us?

Four female NYPD cops who appeared eager to bring back stop-and-frisk are under the gun for posing for photos with a strapping male stripper.

The gals were all grins as the buff entertainer — wearing nothing but boots and a thong — draped his arms around two of them while a third pointed at his barely wrapped package.

A snapshot of the action — which gives new meaning to the term “junk justice” — also shows another beefy stripper nearby, wearing a sailor cap in addition to his G-string.

The photo was posted on social media Sunday morning and reveals someone in a Police Academy shirt taking a close-up on a cellphone at the same time.

The incident took place during a recent Mother’s Day party at the ARC XVI Fort Washington Senior Center in Upper Manhattan.

Sources identified two of the cops as Amber Guzman and Nathalie Lebron, both of whom work as neighborhood coordinating officers under Mayor Bill de Blasio’s “neighborhood policing” initiative.

The women, who are assigned to 33rd Precinct’s Sector D, are known around the station house as “the Divas,” sources said. Neither immediately returned emails seeking comment.

Precinct cops traditionally attend the senior center’s annual Mother’s Day celebration, and an NYPD spokeswoman said, “Our officers were not aware that the males in the photo would be present at this event.”

“The senior center participants encouraged the officers to pose for the picture,” Sgt. Jessica McRorie said.

“The commanding officer is aware and will address the incident at the precinct level.”

The center’s executive director, Fern Hertzberg, didn’t return a phone message.

Male NYPD cops have been transferred and disciplined for similar antics, sources said.

In 2015, two male NYPD cops were photographed posing with topless “desnudas” in Times Square, and two other male cops were captured on video dirty dancing with scantily clad female performers at the 2011 West Indian Day Parade in Brooklyn.

One of the dancing cops, Officer Gregory Gordon, later came under fire for racist Facebook posts, including one that targeted first lady Chirlane McCray.