The settlement agreement, part of which required Gov. Ralph S. Northam's approval, has been in the works for months but was finalized this week, according to court documents. In that time, the U.S. Justice Department released a scathing report that concluded the jail's treatment of inmates amounted to cruel and unusual punishment. One of the correctional officers named in the suit also was indicted on felony assault charges.