BROOKLYN, N.Y. — After serving four years in the military, John Andrews, 42, adjusted to civilian life by working at his local Walmart in Arkansas. Encouraged by co-workers, he also went back to school, hoping to move up in management.

Instead, he ended up $40,000 in debt, with a useless diploma. “I got this degree that I don’t even hang on my wall anymore,” Andrews said.

Last June at a Brooklyn Film Festival screening of “Fail State” — a new documentary by Alex Shebanow that highlights ways for-profit colleges have exploited veterans and vulnerable students — Andrews spoke about his experiences at the University of Phoenix, the for-profit school where he received a degree in business management. He chose the school because his Walmart colleagues taught there, and university administrators encouraged him to use the GI bill, which covered some of his costs. They even helped him fill out required paperwork.

Under a loophole, schools were able to count GI bill money as private dollars, meaning they disproportionately profited from enrolling veterans.

“You can tell there was a focus that I get approved,” said Andrews. When the GI bill did not cover all his tuition, Andrews applied for federal student loans, graduating six years later with his business management degree — and more debt than he could handle.

“The level of harm that is being done [to] students is just staggering,” said filmmaker Shebanow. “The tragedy of this is, if for-profits had done what they said they were doing, we wouldn’t have to make this film.”

A spokesperson for the University of Phoenix did not respond to interview requests. Steve Gunderson, president of the Career Education Colleges and Universities, a membership organization of for-profit schools, called the film “disappointing.”

“Veterans continue to come to our schools because they can get an accelerated, focused, academic program that moves them quickly from the battlefield into the workplace in a career of their choosing,” Gunderson said. “That would not happen if we destroyed veterans’ careers.”

A Century Foundation report in May found that college fraud claims have increased 29 percent from August of last year. Ninety-eight percent of those claims involve for-profit colleges.

Veterans Education Success, a nonprofit providing free legal assistance to student veterans, also released a report last year showing that for-profit schools are targeting student veterans even as these institutions’ non-military enrollment has declined.

In order to capitalize on GI bill dollars, these schools took advantage of a loophole in a federal law that bars for-profit institutions from obtaining more than 90 percent of their revenue from federal aid. Under the loophole, the schools were able to count GI bill money as private dollars, meaning they disproportionately profited from enrolling veterans.

“That regulation alone provided a perverse incentive for schools to really target veterans,” said Tyson Manker, an attorney at Veterans Education Success who attended the screening. “They wanted to get [the veterans] in classes because the most important thing to them was to collect the federal education benefit, the GI bill for veterans.”

“Once you have your GI bill, they know they’re going to get paid.”

Indeed, that’s what a Senate report from 2014 found: Some 66 percent of veterans who attended for-profit colleges using their GI bill benefits left the program without a degree. Four of the 10 schools described in the report failed to provide job placement services that allowed students to repay loans they took out to supplement the GI bill.

Like Andrews, Navy veteran Milo Jones, 46, also found himself heavily in debt after completing a degree in information technology from the now-defunct ITT Tech. The school made a point of helping him apply for GI bill benefits and loan applications and promised to help him find a good job. He was working full time to support his family and thought he’d chosen the fastest and best route.

“At the time I thought ‘OK, they’re really going to help me maneuver it,’” said Jones. “But once you have your GI bill, they know they’re going to get paid.”

Jones completed his degree in 2015, graduating with both bad debt — his loans total $40,000 — and bad credit. “Unfortunately, when you take the easy way out, those are the consequences,” Jones said. He is now a data analyst at Rikers Island.

The film also follows the collapse of the for-profit chain Corinthian Colleges by tracing the Obama administration’s establishment of an investigative team to look into wrongdoings of for-profits. Any crackdown on such schools ended with President Donald Trump’s appointment of Betsy DeVos; the new U.S. secretary of education has dramatically scaled back such regulations. Noted attorney Manker, Devos “turns it back into the Wild, Wild West.”

DeVos has defended for-profit schools, maintaining that the U.S. needs to “expand, not limit, paths to higher education for students, while also continuing to hold accountable those institutions that do not serve students well.”

Some 66 percent of veterans who attended for-profit colleges using GI bill benefits left the program without a degree, according to a Senate report.

Shebanow said he plans to screen his film in veteran communities across the country.

“A lot of people who are well-intentioned are getting ruined by these institutions,” he said. “We need a public outcry to put an end to this.”

Jones, the Navy veteran, agrees. After the screening, he went home to warn his high-school son about for-profit schools.

“I wish he could have seen this film because he is about to start his college search,” said Jones. “I let him know, ‘We’re not going to do that, you’re going to a regular college.’”

This story on for-profit colleges was produced by The Hechinger Report, a nonprofit, independent news organization focused on inequality and innovation in education. Sign up for Hechinger’s newsletter here.