The top uniformed and civilian officials in the Army, Navy and Air Force faced a rare group grilling in the Senate on Thursday over deficiencies in privatized military housing that have subjected service members and their families to hazards including lead paint, mold and vermin.

The high-ranking Pentagon officials promised to remedy the problems, including by proposing a new tenant bill of rights for military families, which would include the ability to withhold payment for housing in the event of inadequate maintenance and move to new accommodations at no cost if repairs are not completed within 30 days.

“The fact of the matter is we did take our eye off the ball,” Navy Secretary Richard V. Spencer said, promising to remedy the issues. “We know that.”

Gen. David L. Goldfein, Chief of Staff of the Air Force, recounted spending 50 of the last 60 years living in military housing, first as the child of an officer and later as an officer himself, and said he never worried about the safety of his children, infrastructure or the possibility of reprisal if he complained. He said airmen now have those concerns, a situation he described as unacceptable.

“Excitement in the near term based on hearings is interesting, not compelling,” Goldfein said. “We are going to have to keep our boot on the throat of the underperforming contractors and our command chain and leadership to make sure we get after this for the long term. And we’re committed to do so.”

The pledges from the top officials come in response to an outcry over poor housing for military families on certain installations where the Pentagon has contracted management out to an array of private companies.

More than 55 percent of 16,779 individuals surveyed in a recent study by the Military Family Advisory Network reported a negative or very negative experience with such privatized military housing, citing issues including black mold, lead paint, faulty wiring, poor water quality, pesticides, vermin and insects in their homes.

The study found that families were reporting illnesses with lifelong implications caused by poor housing conditions, and said that in some cases representatives from the housing companies tried to silence the concerns of service members. The report found that many service members feared negative impacts to their military careers if they continued to complain.

“Families have little or no recourse,” the study said. “Rent cannot be withheld for poor condition, mismanagement, or noncompliance with lease terms.”

The top Pentagon officials testifying on Thursday promised to change that.

Army Secretary Mark T. Esper said leasing agreements need to be “cleaned up” to empower Army families who say they have been left without recourse. The top officials pledged to introduce more technology and support for residents to report issues, make sure military officials in the chain of command become more engaged and change agreements and leases.

The service secretaries testified that the system of privatized military housing introduced in the 1990s overall has improved the quality of accommodations and did not recommend taking the facilities out of private hands.

“I do think that the housing is better than what we had in the 1990s overall,” Air Force Secretary Heather Wilson said. “That doesn’t mean we change our approach to demanding that when there is a problem, it is promptly fixed, and it is fixed in a competent way.”

Sen. Joni Ernst (R-Iowa) expressed disappointment that some of the poor conditions she experienced in military housing decades ago were still ongoing and said, “this shouldn’t happen.”

“I remember living in Indianhead at Fort Benning, Georgia, and the roaches were horrible — so bad that my husband and I had to move into a new set of quarters. They couldn’t get rid of them,” Ernst said. “But we had to do it at our own expense. I thought that would be alleviated 20-25 years later. Obviously, it hasn’t.”

Ernst said her fear was that the issue would be raised, discussions would be had but the necessary follow through would be lacking. She asked for commitments on follow through from the officials, which they delivered.

series of stories published last year by Reuters documented safety hazards at an array of military installations, including instances in which children of soldiers suffered brain damage from lead poisoning in Army housing. The investigation also showed how one housing contractor grew rich even as military families suffered poor conditions in their accommodations, including flooding, collapsed ceilings and burst pipes.