There's nothing dirty about it. Public investors prefer to have a single price, because that's, well, how public markets generally operate after an IPO. They don't want to have to participate in an auction. The purpose of underwriting banks is to provide a single price to public investors while also providing a competitive market for the companies.
The auction occurs between the underwriting banks, who compete for the company's business. The company chooses the bank that they want to use for their IPO (price being one of several factors, as is true for any marketplace). There's some risk involved, which is why underwriting banks effectively take a cut - in that sense, they're acting like an insurer, which takes a premium in exchange for absorbing risk for both parties.