Spain's cabinet approved a draft bill on Tuesday that strengthens the country's laws against rape by requiring explicit consent for sex acts, a move long demanded by assault survivors and women's rights groups.

The proposed law "makes clear that silence or passivity do not mean consent, or that not showing opposition can not be an excuse to act against the will of the other person," said government spokeswoman Maria Jesus Montero, who called it "a decisive step forward".

The measure comes in the wake of the notorious 2016 gang rape of an 18-year-old woman by five men at a bull-running festival in Pamplona in northern Spain that shocked the country.

The men, who called themselves "the wolf pack", were initially convicted of sexual abuse instead of the more serious offence of sexual assault, which includes rape, since the court found no proof that they had used physical violence.

Two of the men filmed the assault, during which the woman is silent and passive -- a fact the judges interpreted as consent.

The ruling highlighted how under Spain's existing criminal code, rape must involve violence and intimidation, and it led to noisy demonstrations across the country to demand reform.

Dubbed the "only yes is yes" law, the bill will define rape as sex without clear consent, mirroring pioneering legislation which came into force in Sweden in 2018.

It also proposes jail penalties for work-related sexual harassment and makes catcalling -- sexually harassing a stranger in the street -- a criminal offence for the first time.

A woman holds a placard reading, "No is no, the rest is rape" during a demonstration marking the International Women's Day in Madrid on March 8, 2020
A woman holds a placard reading, "No is no, the rest is rape" during a demonstration marking the International Women's Day in Madrid on March 8, 2020 AFP / OSCAR DEL POZO

The bill also qualifies forced marriage and genital mutilation as criminal offences and stiffens laws against pimping.

"This law puts consent at the centre and that means only you decide about your body and your sexuality. It frees you from having to show that you resisted, that there was violence or that you felt intimidated," said Equality Minister Irene Montero.

The bill now goes to parliament for a debate and vote, probably in September.

Socialist Prime Minister Pedro Sanchez, who has made feminism a banner of his administration, heads a minority government but he is expected to cobble together enough support from smaller regional parties to pass the bill.

"Let's make our country a freer and safer place for women," he tweeted after cabinet approved the draft bill, which he said will protect women's "right to sexual freedom".

Spain is considered a pioneer in the fight against violence against women after it in 2004 approved Europe's first law that specifically cracked down on domestic violence. That law made the victim's gender an aggravating factor in cases of assault.

Only about a dozen European nations have changed their legal definition of rape as sex without consent, according to Amnesty International. They include Belgium, Denmark, Germany and Ireland.