By Adam Easton
BBC News, Warsaw
In Poland Lech Walesa is a national hero. He is the man who, in the 1980s, led the Solidarity movement, whose defiance of the country's then Communist government started a mass movement which eventually led to its overthrow.
Lech Walesa calls the claims "a fairy tale"
So it is not surprising that a new book published on Monday, accusing the former Nobel peace prize winner of being a communist secret agent in the 1970s, has caused huge controversy here.
The former president strenuously denies the claims.
The book, Lech Walesa and the Secret Services, was written by two historians from the Institute of National Memory, a state institution created to investigate Nazi and communist-era crimes.
Slawomir Cenckiewicz and Piotr Gontarczyk gathered material from the institute's archive, which contains some 86km (54 miles) of communist secret service files.
"In the first half of the 1970s Lech Walesa was treated by the communist secret services as an agent with the codename Bolek," Mr Cenckiewicz told me.
"The documents say he wrote reports and informed on more than 20 people and some of them were persecuted by the communist police. He identified people and eavesdropped on his colleagues at work while they were listening to Radio Free Europe for example."
Similar accusations first surfaced 16 years ago, but this is the first time a state institution has published a comprehensive investigation of Lech Walesa's contacts with the communist secret services.
The authors allege that, as president in the 1990s, Lech Walesa, tried to cover up his past by removing incriminating pages from his secret police file.
The accusations have sharply divided Polish society. Poland's current president, Lech Kaczynski, who fell out with Mr Walesa when he worked as one of his advisers in the early 1990s, said in a national TV interview he was convinced Mr Walesa was an agent.
But Prime Minister Donald Tusk says the accusations are politically motivated.
When I put the book's claims to Mr Walesa himself, he told me it was full of lies.
"Nothing like that happened. I had no influence over what the secret police did and wrote. You will not find any signature of mine agreeing to collaborate anywhere. This is all insinuation and part of the communist secret service campaign against me," he said.
Mr Walesa said a court had cleared him of any suggestion of collaboration when he ran for a second term as president in 2000. He believes the communist authorities falsified his file after he became leader of the Solidarity movement in 1980, to discredit him in the eyes of the world.
"They have created this little fairy tale that Lech Walesa was a brave fighter but in his youth he had a moment of weakness and worked for the secret police. They had to turn up something about me, so they went into ancient history, making it difficult to prove one way or the other," he said.
Many eminent Poles have also come to Mr Walesa's defence. They fear the book could even damage Poland's reputation because Lech Walesa, whose trademark walrus moustache still makes him instantly recognisable, is the one living Pole most foreigners know of.
The book's co-author, Piotr Gontarczyk, argues he had a duty to reveal what he believes is the whole truth about him.
"No serious person denies the importance of Lech Walesa in Polish history. He will remain forever the legendary Solidarity leader. Nobody in their right mind can take that away from him. We have just filled in the unknown gaps in his biography from the 1970s," he told me.
On the streets of Warsaw, the people I asked said the scandal had not influenced their opinion of the great man.
"No, I didn't change the way of thinking about President Walesa," a 49-year-old worker for a non-governmental organisation said.
"In my opinion he deserves much more respect than condemnation actually and it's maybe true that as a young worker he surrendered to the temptation of the secret service, but then with all his work he showed that this was a mistake."
"He was the face of the whole change and for me it really doesn't matter. I think that some people now would like to destroy him, but I think he already has his place in our history," one young mother said.
This scandal has dominated the front pages and television news in the past few weeks.
But it seems to have done little damage to Lech Walesa's reputation.
According to a recent survey, 60% of Poles say even if he did collaborate with the communist police in his youth, he remains a living legend for what he achieved afterwards in helping to bring down the communist regime.