SAN DIEGO — A lawyer for a decorated Navy SEAL charged with war crimes grilled the lead investigator in the case Tuesday as he tried to paint a picture of an upstanding war hero being framed by lies.

A special agent with the Naval Criminal Investigative Service prejudged the case and decided to take aim at Special Warfare Operator Chief Edward “Eddie” Gallagher before he gathered any evidence, attorney Marc Mukasey suggested.

The agent, Joseph Warpinski, befriended witnesses and encouraged them to speak with each other in violation of standard investigation practices, Mukasey said.

Warpinski acknowledged making some mistakes in the hundreds of text messages he exchanged with witnesses, but denied making friends with them or encouraging them to discuss the case to get their stories straight.

He said he had to build rapport with members of the insular special forces community to earn their trust and cooperation.

Gallagher, 40, is on trial for allegedly killing a wounded young Islamic State prisoner and shooting of an elderly civilian and a school-age girl. He has pleaded not guilty to murder and attempted murder charges at his court-martial trial in San Diego.

Mukasey also suggested Warpinski had not asked pertinent questions of witnesses, such as the cause of death of the captive Islamic State fighter Gallagher is accused of fatally stabbing after treating him for battle wounds.

One of the witnesses to the alleged stabbing, Navy SEAL Corey Scott, embarrassed prosecutors last week when he confessed on the witness stand that he, not Gallagher, asphyxiated the patient by plugging his breathing tube.

"You never asked Corey Scott the cause of death, did you?" Mukasey said.

"I didn't say it in those exact words," Warpinski replied.

The young Islamic State fighter authorities say was murdered by Special Warfare Operator Chief Edward “Eddie” Gallagher. But he said he's been framed. (photo provided)
The young Islamic State fighter authorities say was murdered by Special Warfare Operator Chief Edward “Eddie” Gallagher. But he said he's been framed. (photo provided)

Scott testified that he thought the patient would have survived the stabbing, despite previously saying his life could not have been saved.

Scott said he decided to kill the prisoner because he assumed he’d be tortured to death by the Iraqi forces who captured him after he was wounded in an air strike outside Mosul in 2017.

Prosecutors pointed out that Scott had never told the government that version of the story until he took the stand under immunity from prosecution for his testimony.

Scott said Gallagher stabbed the boy multiple times, Warpinski testified.

Scott declined to make any changes or additions to statements he gave to investigators after being granted immunity months ago, Warpinski said.

"At that point did he tell you, 'No, no, no, it was me who killed the ISIS detainee?'" the prosecutor, Lt. Scott McDonald, asked.

"No," Warpinski replied.

Prosecutors rested their case later in the afternoon and the defense has asked the judge to find him not guilty.

The judge took a recess Tuesday to consider the request of attorneys who argued that the case rests on tainted testimony from fellow SEALs who hated Gallagher.

The final prosecution witness connected Gallagher to photos he texted friends in May 2017 showing him holding the dead militant by the hair and clutching a knife in his other hand.

The computer specialist also linked Gallagher to a text message sent to friends that bragged: “Got him with my hunting knife.”

Melley reported from Los Angeles.