Sydney rioter Ahmed Elomar, whose brother Mohamed died fighting for Islamic State, is to be released from jail after the New South Wales government lost its challenge to his being granted parole.

It challenged the decision of the Parole Authority in July to grant parole to the 33-year-old, who has served three years of his maximum sentence of four years and eight months for assaulting a police officer during the 2012 riots at Sydney’s Hyde park.

Lester Fernandez, a lawyer for the New South Wales corrective services minister, David Elliott, said at the time the authority had made several errors of law, including finding the parole decision was in the public interest despite two senior police figures saying they had concerns for community safety if it were granted.

In the supreme court on Thursday, Justice Geoffrey Bellew dismissed the appeal and ordered the government to pay Elomar’s legal costs.

As a result Elomar was due to walk free from Goulburn Jail on Thursday. He will be subject to electronic monitoring and strict parole supervision until May 2018, NSW Corrective Services said.

Elliot said he was bitterly disappointed by the court’s decision.

“I do not support the release of an offender to the community from the secure environment of the correctional system where, in my view, that offender remains untreated and continues to threaten the safety of the community,” he said in a statement.