AMENDED and RESTATED UNDERWRITING AGREEMENT