According to security experts, the attacker penetrated a single Internet service provider that hosts all the government Web sites. The hacker left abusive anti-government messages on some of the sites and a photo of a woman's eye on others.
"This could well be political -- a lot of these things come down to political warfare," a security expert said. "I wouldn't like to say how secure the Brazilian government is, but it shows how vulnerable they are and how easy it is to do. It's all right to get ISPs to host your Web server, but there needs to be some form of evidence that they take security seriously."
"If people do have their Web servers hosted, it is important that they find out whether adequate testing has been done," the expert added.
The defacements were logged on www.zone-h.org. According to the site, the attacks began on Monday. They appeared to be continuing on Tuesday.
Many of the Web site defacements appear to have been removed, although recorded images of them can still be seen on Zone-H's Web site.
Last week, in a nationwide swoop involving 160 officers, the Brazilian Federal Police arrested 53 suspected hackers who are accused of involvement in phishing scams.
Security experts last month said that Brazil was a cybercrime hotspot, housing around 80 percent of the world's hackers.