Losing your job comes with an extra sting if you live in Belarus.

Citizens of the eastern European country are now being forced to pay penalties if they find themselves out of work for too long.

Belarus President Alexander Lukashenko signed a decree this month that sets fines for unemployed people, and puts them at risk of temporary detention.

Lukashenko has ruled the country of nine million since 1994, and is considered by many to be Europe's last dictator.

Under the new law, people who haven't worked for at least six months -- and therefore haven't paid taxes - must pay the government at least $252.

Those who don't pay could be detained, and forced to undertake community service.

Related: These workers are striking for $15 an hour

The move is reminiscent of Soviet-era tactics that criminalized people who didn't contribute to the state.

The decree aims to "stimulate able-bodied citizens to engage in labor activity and fulfill their constitutional obligation to participate in financing state expenditures."

Some people, including minors, disabled people and the elderly, are exempt from the law.

The International Federation for Human Rights has called for the rule to be scrapped and for Belarus to eliminate the practice of "forced labor."

The group says the country also pushes alcohol and drug addicts into forced labor by locking them up in so-called therapy centers against their will.

Nearly 28,000 people have signed a Change.org petition against the decree.

Related: Now might be the time to invest in Russia. No, really.

-- CNN's Alla Eshchenko and Emma Burrows contributed to this report.