Anyone engaging in sex outside of marriage in the world’s third-largest democracy could soon face up to five years in prison. Indonesia’s highest court is deliberating whether to broaden existing law to make all casual sex illegal in the latest bid by conservative Islamists in the country to revise a relatively secular legal code.

A decision by the Constitutional Court is expected in December or early next year, with indications that the court is leaning toward enacting the tougher legislation. While adultery is currently punishable by up to nine months in prison, if the new law goes through it would make gay sexual relations illegal in Indonesia for the first time. It has already received backlash from human rights organizations.

“This [petition] consists of discrimination towards all Indonesians,” Bahrain, who like many Indonesians goes by one name, told the court at a hearing in early October, reports the Washington Post. The director of advocacy at the Legal Aid Center continued: “Women as well as men, and those of diverse sexual orientations. The center is one of several progressive advocacy organizations arguing against revising the constitution to ban sex outside of marriage.”

Indonesia lgbt, casual sex This picture taken on May 8, 2016 shows motorists passing by graffiti calling for tolerance in Yogyakarta, Indonesia. Photo: Goh Chai Hin/AFP

While it is the most populous Muslim-majority country in the world, Indonesia’s legal code remains heavily based on Dutch law as a result of nearly 350-years of Dutch colonization. But lawmakers as well as academics at conservative Islamic advocacy groups such as the Family Love Alliance (AILA), which petitioned for the ban on casual sex, are having a growing influence. Amid anti-LGBT campaigns in the media, a recent survey showed that most Indonesian Muslims disliked LGBT people more than they disliked Jews, Shiites or communists.

Last month, the country’s communications and information ministry banned three gay dating applications, including Grindr, after being urged by AILA. Meanwhile, the Youth and Sports Ministry came under fire earlier this month for banning anyone practicing casual or “deviant” sex, defined as lesbian, gay, bisexual and transgender (LGBT). Participants would be required to have their claims proved by a medical doctor.

Some of the nine justices on the Constitutional Court have already voiced their support for outlawing casual sex.

“Our freedom is limited by moralistic values as well as religious values,” Justice Patrialis Akbar said in August when arguing that the country’s legal system was too “liberal,” according to the Jakarta Post. “This is what the declaration of human rights doesn’t have. It’s totally different [from our concept of human rights] because we’re not a secular country, this country acknowledges religion.”

Akbar continued: “If the principles that have been comprehensively explained [by the expert witnesses] are not enforced in the existing law in this country, would this country be a secular country where religion no longer needed to be respected?” 

Another judge, Aswanto, went a step further during a hearing in August.

“I was a bit annoyed with what the government said, [that we should] let people commit zinah [adultery or casual sex] and not regard them as criminals,” he said. “It’s a little bit annoying. I believe casual sex is a crime.”