Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

The state trooper who shot and apprehended fugitive killer David Sweat has been hailed a “hero” by New York Governor Andrew Cuomo.

Sgt. Jay Cook, a 21-year veteran and father-of-two, was part of the vast manhunt scouring the tough terrain of upstate New York for Sweat, one of the two convicted murderers who escaped their maximum security prison more than three weeks ago.

Speaking at a press conference after Sweat’s capture, Governor Cuomo said he “had the chance to speak with Sgt. Cook and congratulate him on his great police work.”

The governor said the officer should go home to his 16 and 17-year-old daughters and tell them “that you’re a hero,” before joking that “with teenage girls that will probably last a good 24 hours and then you’ll go back to being a regular dad.”

New York State Police Sgt. Jay Cook (right) with colleagues Xaymara Morales (left) and Jon Giddings (center). New York State Police

Cook was alone in his car when he spotted someonejogging along the side of the road, less than two miles from the Canadian border.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

Cook got out of his car, approached the man and said: “Hey, come over here,” according to New York State Police Superintendent Joseph D'Amico, recounting the incident at a press conference late Sunday.

After Sweat ignored him he called out a second time, to which the escapee turned around as if to say: “What do you want from me?” D'Amico said.

It was then Cook recognized Sweat, who escaped the Clinton Correctional Facility 22 days ago with 49-year-old Richard Matt, who was shot and killed by law enforcement on Friday.

Sweat fled and the trooper chased after him, D'Amico said.

Cook knew the densely forested terrain of the northern reaches of New York, having served most of his career there. He pursued Sweat into an open field, but realized his target was about to make the tree line and disappear once again, D'Amico said.

David Sweat after being shot on by Sgt. Jay Cook on Sunday.

Cook fired two shots from his handgun and hit Sweat twice in the torso. He was then handcuffed.

The fugitive was later treated by emergency medical services personnel and airlifted to hospital where he was listed in critical condition.

The sergeant's heroics were also recognized on Twitter with the hashtag #jaycook.

Heroes do exist! #jaycook great job from the NY State police — maria cicero (@kmcicero) June 28, 2015

#PrisonBreakNY honored to have #JayCook write me a speeding ticket — David Regan (@DavidRegan) June 29, 2015

#jaycook Great job! You remained cool under pressure and GOT your man! — Elise Jacobson (@Elise2027) June 29, 2015

D'Amico said that he presumed Sweat was about to make a break for the Canadian border.

Meanwhile, the family of a cop killed by Sweat expressed thanks to all of the officers involved in the three-week manhunt.

Relatives of Broome County Sheriff's Deputy Kevin Tarsla recounted that he had been "ambushed, shot 15 times and then run over with a car simply for stopping to check unusual activity in a town park" on July 4, 2002.

"We would like to extend a special thank you to Sgt. Jay Cook for being vigilant when he saw something that didn't look right and going with his instincts," the family's statement added. They described Matt and Sweat as "two evil people that had no regard for human life."