FBI special agent Brad Garrett wasn't sure the man on the bed in the seedy hotel room in Pakistan really was Mir Aimal Kasi. He had a beard and was heavier than the gunman who had opened fire outside CIA headquarters, killing two agency employees and injuring three other people.

"Turn him over," Garrett told the other agents, their guns drawn, as he straddled the man in the $3-a-night room at the Shalimar Hotel in Dera Ghazi Kahn. Garrett then took the man's left thumb and pressed it onto an ink pad.

Garrett had brought a photograph of Kasi's fingerprints in a bag. In the middle of the night, in a desolate, dusty town bordering Afghanistan, in 1997, the agent pulled out a magnifying glass and studied the prints. The 4 1/2-year international manhunt was finally over. "It's a match!" Garrett said.

Kasi, 38, is scheduled to be executed by injection tonight at the Greensville Correctional Center in Jarratt, Va. His death would end an odyssey that began nearly a decade ago on traffic-choked Chain Bridge Road in Langley. Just before 8 a.m., Kasi stepped out of his Izusu pickup truck, shouldered an AK-47 and began firing methodically at motorists waiting to turn in to CIA headquarters.

The FBI and the CIA never found evidence that Kasi was linked to an organized terrorist organization. But his shocking, violent acts that day foreshadowed future terrorist acts against the United States here and abroad. Like a suicide bomber, Kasi was willing to sacrifice his life to protest U.S. foreign policy, which he believed was hurting Muslims worldwide.

"So much of America was surprised by 9/11, but, in fact, the degree of animosity and hatred that has been mobilized in Third World countries had been growing," said Jerrold Post, a George Washington University professor who has studied the psychology of terrorism. "We're not just talking about al Qaeda; we're talking about the climate of radical Islam."

Harvey Kushner, a terrorism consultant at Long Island University, called Kasi the "perfect prototype of what we face in al Qaeda. He's the guy who steps up to the plate."

During the plane ride to the United States, Kasi told Garrett he wanted to "teach a lesson" to the U.S. government.

"He would have killed anyone at the gates of the CIA that day," said Fairfax County Commonwealth's Attorney Robert F. Horan Jr., who prosecuted Kasi. "He was getting even with the CIA for the way they treated the Muslim people of the world. He was, and I believe he is, proud of what he did, and I believe he'd do it again tomorrow morning if he had the chance."

Kasi has said as much in various media interviews over the past several days. He had agreed to speak to The Washington Post but backed out moments before the scheduled interview.

The U.S. State Department has warned that Kasi's execution could result in retaliation against Americans around the world. Protesters have taken to the streets in Pakistan, including hundreds of angry university students in Multan.

Many consider the threat very real. Kasi was hailed as a hero among some in Pakistan and Afghanistan after the shooting. A day after his conviction in 1997, four American oil executives were killed in Pakistan, and U.S. officials speculated at the time that the slayings were in retaliation for the trial.

It is unlikely that the execution will be halted. In the five years since Kasi was convicted in Fairfax County Circuit Court and sentenced to death, he exhausted his appeals. Now only the U.S. Supreme Court or Virginia Gov. Mark R. Warner (D) can intervene.

Kasi plans to spend much of what could be his last day praying, said Garrett, who has met regularly with Kasi on death row and was asked by the Pakistani native to attend his execution.

Kasi has appealed to his supporters to refrain from any violent response, said his attorney, Charles R. Burke. "He doesn't want any uproar or retaliation. He doesn't want anyone to do anything," Burke said.

But Kasi also says he has no regrets.

"He stands by what he did and now knows he's got to pay the ultimate price," Garrett said.

It was bitterly cold Jan. 25, 1993, at the height of the morning rush, when Kasi stepped out of his truck in the left-turn lanes outside the CIA and began firing, the first shot piercing the rear window of a Volkswagen Golf.

Judy Becker-Darling, sitting in the front passenger seat next to her husband, Frank Darling, heard the crash and thought another car had struck theirs. "Oh my God, somebody has a gun," Darling, 28, told his wife of only three months. "I've been shot."

As Darling urged his wife to hide under the dashboard, Kasi turned to another car trapped at the light and fatally shot Lansing Bennett, 66, a physician and CIA intelligence analyst. Kasi then walked between the double line of cars, shooting and wounding Calvin Morgan, 61, an engineer; Nicholas Starr, 60, a CIA analyst; and Stephen E. Williams, 48, an AT&T employee.

Then Kasi returned to the Darlings' car and fired three more times, striking Frank Darling, a CIA employee who worked in covert operations, in the leg, groin and head. Out of the corner of her eye, Becker-Darling saw something rush past. She saw the gun, not Kasi. "I hope he runs out of bullets," she prayed.

Kasi, who carried 150 rounds of ammunition that day, was aiming only at men -- he believed killing women, who did not have any power in his country, would be wrong. He stopped firing only because there was no one left to shoot.

Kasi was surprised that he was able to climb back into his truck and continue down the road without having a shootout with police. When he got to Kirby Road, he turned right and headed for a park in McLean.

As law enforcement officials widened their search, Kasi was just five minutes away in the park, where he stayed for 90 minutes. No one seemed to be looking for him, so he returned to his Herndon apartment, stuck the assault weapon in a green plastic bag, placed the bag under the sofa and grabbed something to eat at McDonald's.

It was clear to Kasi from CNN news reports that police had the wrong description of his vehicle and that no one had seen his license plate number. Nevertheless, he decided to spend the night at a Days Inn before catching a flight to Pakistan the next day.

A task force of Fairfax police and federal law enforcement officers, called "Langmur" for the Langley murders, tried to learn the identity of the gunman. Garrett, who arrived about 30 minutes after the shootings, was assigned to the case.

On the theory that the gun was recently bought, the task force began combing through AK-47 purchases in Virginia and Maryland in the past year, Garrett said. There had been more than 1,600.

An employee at a Chantilly gun store recalled exchanging a customer's gun for an AK-47. The owner's name on the sales slip: Mir Aimal Kasi.

Kasi's roommate, who had reported him missing after the shootings, told police that Kasi would get incensed watching CNN when he heard how Muslims were being treated. Kasi had said he was going to do "something big" at the White House, the Israeli Embassy or the CIA, but his roommate didn't think much of it.

The roommate let police search the apartment, where they found the AK-47 under the couch. Soon after, Garrett got a double 911 page: The ballistics matched, and the search began.

A month after the CIA shootings came the first bombing of the World Trade Center. Authorities wanted to know whether Kasi was acting alone or was part of some bigger plan.

"The investigators spent a lot of time trying to find out: Did he have an accomplice? Was he part of some movement? Was he part of some collection that had other violence in mind?" Horan recalled.

During the next four years, Garrett and other agents made frequent trips to Pakistan. Developing and corroborating sources was difficult. Leads would evolve, then evaporate, in places as far away as Thailand. "We literally followed up hundreds of leads that took us all over the globe," Garrett said.

Finally, in the late spring of 1997, informants said agents could find Kasi in a hotel, the Shalimar, in Dera Ghazi Kahn. They produced recent photos and fingerprints. Garrett and the other FBI agents began to get excited.

The team of four, including two agents from the hostage rescue team, practiced room entries, parking one agent in the hallway, Garrett said. The first agent in the room would not be armed and would jump Kasi when he answered the door. The other two would clear the room of people or weapons. They were pumped -- and concerned. "What if we end up killing him? Or killing the wrong person? Or one of us gets killed?"

At 4 a.m. June 15, 1997, wearing traditional Pakistani clothes over their jeans and weapons, they approached the hotel, which they were told would be unlocked. It wasn't. So they had no choice: They knocked.

"It was surreal," Garrett said. "It's dark. It's dusty. I felt like I was in a David Lynch movie. We're actually starting to sweat it."

On the trip home, Kasi did not resist when Garrett asked him about the shootings. He said he had done it because he was upset at how Muslims were treated by the CIA in their own countries, particularly Iraq. He hoped his actions would make a statement.

"He was very upfront about what he did. He didn't try to blame it on anyone. He didn't try to hide it," Horan said.

Back home, Kasi became a hero, Garrett said.

To Garrett, who was involved in the arrest of Ramzi Yusef, the mastermind of the 1993 World Trade Center bombing, Kasi's story sounded similar to Yusef's: He thought that if he caused enough havoc, it would change U.S. policies.

"It was almost illogic logic," Garrett said. "It wasn't personal. It wasn't like hating individuals. It was more institutional."

Garrett made the first of many visits to Kasi on death row about three months after his November 1997 conviction. "Why haven't you executed me yet?" Kasi asked. The agent explained that it takes a few years in the United States.

After the Sept. 11, 2001, terrorist attacks, Kasi told Garrett that he did not approve of the attack on the World Trade Center because innocent civilians were killed. He understood, however, the attack on the Pentagon, the symbol of government might.

Kushner, the terrorism expert, said that even though Kasi acted alone, he was the opening salvo for Muslim fundamentalists. "He was one of the dots that should have been connected before 9/11," Kushner said. "He was a serious player even though they were never able to link him to any specific group."

Thomas J. Badey, a political scientist at Randolph Macon College, said the students' protests in Pakistan over Kasi's pending execution is a sign that the fervor isn't nearly over. "It appears that Kasi's fate is becoming a rallying cry in parts of Pakistan," Badey said. "He's the one foreign Islamic terrorist prosecuted in the United States who has been sentenced to death. The question is how effective is that as a tool in fighting terror, because he becomes a martyr for the cause."

Kasi's victims, like Kasi, hope there is no retaliation.

"We will spend time in prayer for Kasi, that God will have mercy on his soul, for his family, that there be no terrorism reprisal, and for world peace," Becker-Darling's family said in a statement.

Staff writer Dana Priest contributed to this report.

In 1993, Mir Aimal Kasi killed two people and wounded three.In Quetta, Pakistan, home town of Mir Aimal Kasi, demonstrators burn tires to protest his impending execution. The sign reads, "Down with America. Aimal Kasi should be released." Kasi killed two people and wounded three in 1993.