Under a special state secrets bill expected to pass on Friday, public officials and private citizens who leak "special state secrets" face prison terms of up to 10 years, while journalists who seek to obtain the classified information could get up to five years.

Critics of the new law say it marks a return to the days of prewar and wartime Japanese militarism, when the state used the Peace Preservation Act to arrest and imprison political opponents.

"It is a threat to democracy," said Keiichi Kiriyama, an editorial writer for the Tokyo Shimbun newspaper, adding that the legislation would "have a chilling effect on public servants, who could become wary about giving the information" to journalists.

The Japanese prime minister, Shinzo Abe, speaks during the debate on the state secrets bill. Photograph: Aflo/Barcroft Media

In the aftermath of the Edward Snowden leaks, Japan has come under pressure from Washington to better protect state secrets – including intelligence shared by the US – at a time of rising regional tensions.

Japan's prime minister, Shinzo Abe, says the law is crucial if his US-style national security council, approved this week, is to function properly.

The law is seen as part of his conservative project to bolster Japan's security in response to escalating tensions with China and concern over North Korea's nuclear weapons programme.

The state minister in charge of the bill has denied that it would affect the release of information about radiation leaks at Fukushima Daiichi. Photograph: Kyodo/Reuters

Abe, who does not have to fight an election for another three years, is expected to push ahead with his nationalist agenda, including constitutional reforms that would end the military's purely defensive role.

The secrecy bill's hasty passage through the lower house has been marked by noisy public demonstrations and opposition from journalists, lawyers, politicians, academics and scientists, as well as film directors and manga artists concerned about freedom of expression.

They say the prospect of prison terms will deter whistleblowers from leaking sensitive or embarrassing information in the public interest, and journalists from trying to obtain it.

The upper house of Japan's parliament is expected to approve the bill before the end of the current parliamentary session on Friday, possibly later on Thursday.

The chief criticism of the bill is its vague definition of what constitutes a state secret, potentially giving officials carte blanche to block the release of information on a vast range of subjects, including measures to counterbalance China's growing military influence in the region, and the safety of the country's nuclear reactors.

"There are few specifics in the law, which means it can be used to hide whatever the government wishes to keep away from public scrutiny," said Mizuho Fukushima, an opposition MP.

"In its current form, the prime minister can decide by himself what constitutes a secret."

The law would apply to four areas – defence, diplomacy, counter-terrorism and counter-espionage – and gives officials the power to keep sensitive information out of the public domain indefinitely.

Senior politicians insist the law will not be used to gag the press or restrict the public's right to know.

But the justice minister, Sadakazu Tanigaki, refused to rule out police raids of newspapers suspected of breaking the law.

Masako Mori, the state minister in charge of the bill, said the law could be applied to Japan's nuclear power industry, because it is a potential target for terrorists. But she denied the legislation would affect the release of information about radiation leaks at Fukushima Daiichi.

Last week, the secretary general of the governing Liberal Democratic party, Shigeru Ishiba, angered many when he likened people protesting against the bill to terrorists. He later apologised for the remarks.

"There is a demand by the established political forces for greater control over the people," said Lawrence Repeta, a law professor at Meiji University. "This fits with the notion that the state should have broad authority to act in secret. It seems very clear that the law would have a chilling effect on journalism in Japan."

Widespread opposition to the law is testing Abe's popularity. A recent poll by the Asahi Shimbun newspaper found public support for Abe has dropped to below 50% for the first time since he took office last December. More than 60% of those polled expressed concern that the bill was being rushed into law.

In response, Abe this week attempted to dismiss claims that officials would abuse the law to prevent the disclosure of information that is in the public interest. "There is a misunderstanding," he said. "It is obvious that normal reporting activity of journalists must not be a subject to punishment."

Abe said the government would set clearer definitions of state secrets and appoint a third party to oversee possible violations. Critics point out that the proposed body, comprising senior officials from the foreign and defence ministries and the national police agency, is far from independent.

"What we need is a third party, not a quasi-third-party system that can check," said Banri Kaieda, leader of the main opposition Democratic party of Japan. "I can say with certainty now that the bill is created by bureaucrats for the bureaucrats to hide information."

It said in a statement: "How can the government respond to growing demands for transparency from a public outraged by the consequences of the Fukushima nuclear accident if it enacts a law that gives it a free hand to classify any information considered too sensitive as a state secret?"

Navi Pillay, the UN high commissioner for human rights, accused Japan's government of imposing the legislation with little public debate. "They should not rush through the law without first putting in proper safeguards for access of information and freedom of expression as guaranteed in Japan's constitution and international human rights law," she said.

The law reflects a decline in Japan's standing as a protector of the free press. In the Reporters Without Borders press freedom index for 2013, it dropped 31 places from 2012 to a new low of 53rd out of 179 countries.