In mid-2016, 33-year-old Ekwanto set out from his village of Gunem in Central Java and headed to Malaysia, where he hoped to earn enough working on a construction project to open a small grocery store when he returned home.
But it was not to be. The job ended after three months when the project owner suddenly returned to his village in southern Sumatra. Instead of heading home too, Mr Ekwanto stayed on because he did not have a proper work permit.
He had bypassed recruiters that arrange such things, sometimes for fees equivalent to more than three months' pay.
Despite eventually finding work in Malaysia, intensifying police raids made his life unbearable.
After 18 months, Mr Ekwanto paid the Indonesian embassy RM1,800 ($595) to send him home. His savings? Ten million rupiah ($970) - the equivalent of a month's pay for a university-educated office worker in Jakarta. "It was very hard there," said Mr Ekwanto, who now works at a bank in his village. "I failed to achieve my dream."
Malaysia's expanding palm oil, construction and manufacturing sectors are magnets for the region's legions of unskilled workers from Indonesia, Bangladesh and elsewhere, drawn by higher wages and pushed by few opportunities at home. But unscrupulous recruiters, police and an unforgiving legal system that affords both domestic and foreign workers few rights make the journey risky for many.
We need to ensure the dignity and protection not only of domestic workers but also foreign ones.
MALAYSIAN HUMAN RESOURCES MINISTER M. KULASEGARAN
That may be about to change. Malaysia's Human Resources Minister M. Kulasegaran said the Pakatan Harapan government of Prime Minister Mahathir Mohamad would propose changes to the country's patchwork of decades-old labour laws to offer both domestic and foreign workers more legal protection.
"We need to ensure the dignity and protection not only of domestic workers but also foreign ones," Mr Kulasegaran told The Sunday Times.
At issue are as many as nine industrial relations laws dating as far back as the 1950s that give the government broad powers to prevent or disband unions and limit collective bargaining.
The government is consulting labour groups, including the Malaysian Trade Union Congress and International Labour Organisation (ILO), Mr Kulasegaran said.
The government has said it is considering extending worker's compensation to foreign workers and ban the use of private recruiting agencies over fears that some are engaging in what amounts to human trafficking.
Mr Kulasegaran said Malaysia needs a steady supply of unskilled workers and must repair the damage to the country's reputation as a dangerous place for foreign workers following media reports alleging abuse.
Malaysia's unemployment rate at the end of September was 3.4 per cent. Recent agricultural sector surveys, including among oil palm plantations, suggest that foreign workers make up more than 80 per cent of labour on hand.
"Foreign workers are an indispensable part of the economy," Mr Kulasegaran said.
An amnesty for undocumented workers is "in the pipeline", the minister said, adding that the final decision belongs to Home Affairs Minister Muhyiddin Yassin.
Last August, the government wrapped up a partial amnesty, charging fees and fines of up to RM400 to undocumented workers who turned themselves in for deportation.
Just how many foreign workers are in Malaysia is unclear. The most recent government data shows that it is host to just shy of 1.8 million documented foreign workers.
A report published last April by ISEAS - Yusof Ishak Institute reckons that there can be a similar number of undocumented workers.
That brings the number of foreign workers to nearly four million. That compares with the seven million Malaysians in the workforce.
Ample stores of cheap, vulnerable and pliant undocumented workers are fertile ground for abuse and corruption, activists warn.
Top Glove, the world's biggest rubber glove maker, said it was monitoring workers' hours after media reports alleged that staff at two of its factories were working much longer hours than permitted by law to repay recruiting agencies.
"The types of conditions alleged in the Top Glove case are not an anomaly. There are many more cases like the one described," said Mr David Welsh, Malaysia and Indonesia country director for labour advocacy group Solidarity Centre.
Still, the government deserves credit for tackling the issue and consulting widely, Mr Welsh said. "They are giving stakeholders a chance for feedback. The process is encouraging and badly needed. Of course, the proof is in the pudding."
The ILO confirmed that Malaysia has asked for its help "as part of a holistic review of a revision of its main labour acts", said its Kuala-Lumpur-based chief technical advisor, Mr Hugo van Noord.
He is heading the international body's review of Malaysia's labour laws and is aiming to secure labour rights like freedom of association, union organisation and collective bargaining.
"Successful passage of all these and other legal and institutional reforms... would lead to a new industrial relations landscape in Malaysia with less government intervention," Mr Van Noord said.