An environmental group has lost a legal case over unregulated sand extraction from Lough Neagh.
Friends of the Earth had taken a judicial review of how the issue had been enforced.
It said the former Department of the Environment (DoE) should have issued a stop notice which would have led to immediate cessation.
But a judge said the then DoE minister had not been "turning a blind eye".
Mr Justice Maguire said Mark H Durkan had assessed the case carefully and had "reached a decision that was within his remit to reach".
Instead of a stop notice, the minister used what's called an enforcement notice.
It's open to appeal. One was lodged and dredging is continuing pending the outcome of that hearing.
Around 1.5m tonnes of sand is sucked out of the bottom of the lough by special barges every year.
It is used extensively in the construction industry.
However, Lough Neagh is also an important bird sanctuary with EU protections.
Friends of the Earth said that placed a legal requirement on the department to protect it.
During the hearing it was revealed that Mark Durkan had twice rejected the advice of officials to stop unauthorised dredging.
Lawyers for the department said Friends of the Earth had "grossly overstated" the impact of dredging.
Giving judgement, Mr Justice Maguire said the possibility of a stop notice had not been ruled out.
He said it was a case that would require continuous assessment.
Friends of the Earth director in Northern Ireland James Orr said the decision was "a major blow to NI's environment".
"This vitally important wildlife site is supposed to be protected under international law - if we can't protect these precious areas then nowhere is safe," he said.
A spokesperson for the sand traders and the Earl of Shaftesbury, who owns the bed of the lough, welcomed the outcome.
"Lough Neagh Sand Traders and the Shaftesbury Estate welcome the fact that the court has recognised that we have acted lawfully and that we are following proper procedure.
"Indeed since this case we have carried out and submitted a further vast body of research and studies, which further indicates our desire to be compliant with the proper planning process."