Nearly four months after taking power, the Egyptian military is slowly losing the public affection it enjoyed in the days immediately after Hosni Mubarak was driven from office.
The military has enjoyed public support since army officers seized power in a coup in 1952, toppling the monarchy.
Until now, it has enjoyed a reputation for being the ultimate guarantor of the nation's interests, the country's protector against outside threats and guardian of the people. It has given Egypt all its four presidents since 1952 and fought Israel in three wars.
But the military grew to become a secretive organisation. News about the armed forces could be published only after careful scrutiny by military censors. No criticism was allowed.
In recent years, it made quiet inroads into business, winning lucrative government contracts to build roads, dams and hotels, presenting formidable competition to the country's powerful businessmen, some of whom were closely linked to the Mubarak regime.
Generals took over after Mr Mubarak was forced to step down on February 11. Their ascent to power amounted to a "soft coup" that evolved over many days. Mr Mubarak himself helped to spur it when he called out troops to restore order on January 28.
Passionate chants of "the people and the army are one hand" defined an alliance between the protesters and the soldiers. A pledge by the military not to use violence cemented that partnership and further endeared the armed forces to the protesters and the population. When the armed forces finally took over on February 11, the protesters had nothing but praise for the generals.
There were party-like street scenes that spoke of unity between the people and their armed forces. The jubilation went on for days after Mr Mubarak stepped down.
But with popular expectations running high after nearly 30 years of Mr Mubarak's authoritarian rule, the generals came under the microscope, with every decision scrutinised.
In a poor and corrupt country of 82 million people, the military inevitably made decisions that upset some. The military, after all, is an institution that is by its nature right-wing, conservative and patriarchal, characteristics that place it on a collision course with the liberal and leftist youth groups behind the revolt.
The first sign of serious discord between the military and the "revolutionaries" came in March when military police broke up a protest at Tahrir Square, arresting dozens of protesters. Activists say the soldiers administered "virginity tests" on the women they detained, sparking an outcry at home and abroad.
The accusations were followed by charges made by a member of the Supreme Council of the Armed Forces that male and female protesters were sharing tents and using drugs in their encampment.
"There were girls with young men in one tent. Is this rational? There were drugs; pay attention!" General Ismail Etman, the chief Supreme Council spokesman, said at the end of March.
An unidentified general confirmed that the virginity tests were administered to refute possible allegations that the 18 women detained on March 9 were raped in military custody. Another army general, also unnamed, later denied that the tests were ever carried out.
However, one of the women gave a detailed account of her ordeal. She said she was ordered to strip naked in a room with the door and window open, that a soldier photographed her and a male doctor, not a female one as is customary, examined her to determine whether she was a virgin. She also claimed she was beaten and given electric shocks.
The intense and negative publicity surrounding the virginity test allegations, also documented by Amnesty International, clearly angered the military and, significantly, led to comparisons between their methods and those of Mr Mubarak's security bosses. Amnesty said in its report that one of the women told her jailers she was a virgin but was beaten and given electric shocks when the test supposedly proved otherwise.
"Forcing women to have 'virginity tests' is utterly unacceptable," the Amnesty report said. "Its purpose is to degrade women because they are women."
More importantly, the allegations led many to ponder whether Mr Mubarak has been replaced by about two dozen Mubaraks: the generals who sit on the ruling Supreme Council of the Armed Forces.
Running the country when no one and nothing is spared scrutiny meant that the military could no longer remain the untouchable institution it has been for close to 60 years. The generals began to strike back, using a mix of diplomacy and intimidation.
Statement after statement posted on their Facebook page warned the media against publishing rumours and unconfirmed reports. Journalists have been summoned by the military for a "chat", then given thinly veiled warnings not to write negatively about the military.
Some were asked to sign statements pledging not to publish news about the military that is false or sensational. More seriously, the military has paid no heed to repeated calls by rights groups to stop trying civilians before military tribunals. Three judges who criticised the military in comments made to the media are being investigated by the Justice Ministry.
Activists say there are indications that the generals may be trying to enshrine their elevated status in the country's new constitution.
For example, a member of the Armed Forces' Supreme Council has said that he wanted the new constitution to strip from the head of state the authority of having the final word on the affairs of the armed forces.
Many in the youth groups behind the uprising also see the generals, particularly the defence minister, Mohammed Hussein Tantawi, as essentially remnants of the Mubarak regime. They charge that the generals are not moving fast enough to make good on their promises for reform.
The youth groups made their displeasure known when at least 20 of them turned down an invitation from the generals for a "national dialogue" meeting last week, arguing that it was hastily arranged.
"The way revolutionary groups were invited to the dialogue indicates lack of seriousness in dealing with them," the groups said. "We can't accept this dialogue in light of the military trials of revolutionaries, violations of military police, and lack of investigations into those."
Curiously, a growing number of prominent media personalities are rushing to the defence of the military, effectively campaigning for the armed forces to be placed above criticism or questioning. Others are delivering an identical but much more subtle message: make sure your facts are correct and your sources reliable before you write anything about the military.