A gunman was shot outside the White House yesterday after he refused to surrender to secret service agents.

President George W Bush was in the executive office at the time but never in danger, said officials.

Foreign Secretary Robin Cook had left the White House only moments earlier after meeting Bush administration officials.

Secret service agents and Washington police ringed the White House in a security clampdown .

The gunman - identified as Robert Pickett, 47, of Evansville, Indiana - was shot in the leg after he was found brandishing a gun outside the White House's south-west gate.

Witness Martin Manley told how he heard two or three shots being fired before police arrived at the scene, but security sources insisted the only bullet fired was the one that hit the gunman.

One possibility being investigated is that Pickett was trying to provoke a shooting by police.

He appeared to be shot in his right knee, and was taken by ambulance to the nearby George Washington University Hospital.

Security has been tightened in and around the White House in recent years. The most significant change was the closing of the section of Pennsylvania Avenue that passed in front of the Executive Mansion. Wednesday's incident was on the opposite side of the White House, the back side facing toward the Washington Monument.

In May 1995, the Secret Service shot a man who scaled a White House fence, carrying an unloaded gun. An official said at the time the man had asked to see President Clinton.

Nine months earlier, a pilot died when he crashed a small plane on the South Lawn of the White House. About a month later, a man pulled a rifle from under his trench coat and sprayed the front of the White House with bullets.

More than a mile east of the White House, in 1998, a gunman went on a shooting spree in the US capital, killing two policemen.