Trial and error. They have a pretty good record this far, from what I know.
Why not have private industry do this? They're far more efficient, able to do things faster and with less red tape. I'd rather there be both, private and public working in accordance. But then, my sister has never been bitten by a rat.
I've worked for NASA. Getting things done was difficult and frustrating. That's why I'm in the private space industry now. The Space Shuttle, despite the enormous amount of money spent on it, didn't have a wonderful record either. Flight 25 was the challenger disaster. This was Flight 19 of the Falcon 9, which has been rapidly improving since the first flight.
I'm OK with rocket science on the public dolla being difficult and frustrating. They have to answer to Congresspeople that don't believe in dinosaurs ... who represent people that don't believe in science. And I don't trust private industry. It needs regulation. And those regulations can't be made by people who don't believe in dinosaurs.
Is there some kind of regulation you feel commercial rockets are currently lacking? There are already multiple licenses from the FAA and FCC required to launch a rocket and put a payload in space. NASA has deep involvement as a customer if it is their payload or their astronauts or coming close to the ISS.