Capt Moussa Dadis Camara took power in a bloodless coup last year
Guinea's military leader has been fired on by one of his aides in the capital, Conakry, a government spokesman says.
Officials said Capt Moussa Dadis Camara had been injured in the shooting but was "in good health".
Communication Minister Idrissa Cherif named aide-de-camp Aboubacar "Toumba" Diakite as being behind the attack.
Analysts say the shooting highlights deep rifts within the junta after the killing of an estimated 157 opposition supporters in September.
A team of UN investigators has been in the capital Conakry this week to unearth exactly what happened when soldiers opened fire in a stadium packed with protesters. Several women have reported being gang-raped by soldiers.
CAPT MOUSSA DADIS CAMARA
Seized power in December 2008 as a little known army captain
Promised democracy, but now shows signs of holding onto power
Increasingly erratic behaviour and public humiliation of officials
"The president of the republic is still the president of the republic and he is in good health," Mr Cherif was quoted as saying by the Associated Press news agency.
He warned that those behind the attack would face punishment.
Mr Cherif said that Lt Diakite "has been located, meaning arrested". However, other reports suggest he has gone into hiding.
Lt Diakite has been accused by witnesses and human rights groups of being one of those at the stadium during the massacre.
There are unconfirmed reports that Capt Camara may have sent soldiers to arrest Lt Diakite when the shooting broke out.
Mr Cherif hinted that there may have been a link between the stadium killings and the shooting of Capt Camara, by pointing out that the military strongman had called for "complete transparency" with the international commission of enquiry.
The military authorities have always said that just 57 people died and most of these were trampled to death, not shot at the rally which was called to urge Capt Camara not to contest elections scheduled for next year.
Mr Cherif said Capt Camara, who took power in a bloodless coup last year, was at a military camp when the shooting occurred.
David Bamford, BBC News
Guinea's mineral wealth makes it potentially one of Africa's richest countries, yet its people are among the poorest in West Africa. Largely to blame are a procession of strong-arm leaders who have run the country since independence half a century ago.
When former President Lansana Conte died last year it was the turn of Captain Moussa Dadis Camara to seize control. Though Capt Camara declared himself president following the coup, he also maintained he had no intention of clinging on to power.
In August this year, he announced that presidential elections would be held in January 2010. But in September, government troops opened fire on an opposition rally at a stadium in Conakry, called to protest Captain Camara's rumoured intention to stand as a candidate.
Since then the situation has grown ever more unstable.
Reports from the city said gunfire broke out at about 1900 GMT, near a radio station and a base of the presidential guard.
Meanwhile, neighbouring Senegal has flown a medical team to Guinea to help treat Capt Camara, officials said.
"He is injured. We don't know the degree and the nature of his injury," a Senegalese official said, quoted by AFP news agency.
The official said the plane was sent to evacuate Capt Camara to Dakar, but a report on the Guineenews website said Senegalese doctors were treating him at the junta's headquarters in Conakry.
The BBC's Mark Doyle, who was recently in Guinea, says tensions have been extremely high there since September.
Capt Camara was at first popular when he seized power because he promised to return the country to civilian rule, our correspondent says.
However, since appearing to renege on that promise Capt Camara has become unpopular with all but his closest allies, he adds.
Arms embargoes and travel restrictions have been imposed against the junta by the European Union and West African alliance Ecowas.
The EU has called for Capt Camara to be tried for crimes against humanity, while the African Union has been urging him to stand down.