A federal court has cleared limited data-sharing with ICE while protecting immigrants' medical information