Staffers on Bernie Sanders' presidential campaign accessed Clinton data through a brief glitch in a shared information system. Here’s how it happened and what it could mean for Bernie Sanders’ presidential bid. (Jayne W. Orenstein/The Washington Post)

The presidential campaign of Sen. Bernie Sanders of Vermont filed a lawsuit against the Democratic National Committee on Friday, arguing that the party had unfairly suspended the campaign’s access to key voter information. After several tense hours, both sides announced a deal had been reached.

The suit came shortly after campaign manager Jeff Weaver acknowledged at a Washington news conference that Sanders staffers had improperly reviewed information gathered by rival Hillary Clinton earlier in the week. But he accused the DNC of over­reacting to the breach by suspending the Sanders campaign’s ability to access the computer system containing information about Democratic-leaning voters, including data the campaign has gathered about its own supporters.

After midnight, Sanders and the DNC put out statements that both indicated the impasse had been resolved but that put remarkably different spins on the outcome. Sanders’s campaign said the DNC had “capitulated” and that Sanders would soon regain access to the data. The DNC said what happened was “completely unacceptable” and that it would continue to investigate the circumstances even as Sanders regained access to the valuable information.

Without a quick resolution, the messy public brawl threatened to overshadow Saturday’s third Democratic presidential debate and cast doubt on the DNC’s ability to manage the sophisticated data tools necessary for the party to win the White House next year. And it sparked significant suspicions among Sanders supporters that the party was conspiring to give a boost to Clinton.

DNC Chairwoman Debbie Wasserman Schultz rejected that allegation Friday, alleging that Sanders staffers had exploited a software error to essentially “steal” data from Clinton’s campaign. Wasserman Schultz said the party would not allow Sanders access to the critical database again until his campaign agreed to an independent audit of what happened.

Jeff Weaver, campaign manager for U.S. Democratic presidential candidate Bernie Sanders, talks to the media in Washington Friday. (Yuri Gripas/Reuters)

The suit, filed in federal court in Washington, argued that under a contract between the DNC and the campaign governing the data system’s use, formal notice in writing is required if either side believes the other has violated the deal. In addition, each side is supposed to be allowed 10 days to address any concerns, the suit said.

“The DNC may not suspend the Campaign’s access to critical Voter Data out of haste or desperation to clean up after the DNC’s own mistakes,” the suit says.

The voter data is heavily used to raise money, and the Sanders campaign estimated that it is losing $600,000 a day in “critical fundraising and publicity opportunities” without access to the files.

The incident strained the relationship between the campaign of an upstart Vermont senator who until this year has run as an independent and a national party his supporters have long accused of favoring Clinton.

Weaver accused the party of purposely sabotaging Sanders by refusing to restore access to the voter information.

“By their action, the leadership of the Democratic National Committee is now actively attempting to undermine our campaign,” Weaver said. “I think if you look at the pattern of conduct . . . it looks like in this case they’re trying to help the Clinton campaign.”

NGP-VAN, the computer vendor that provides Democrats with detailed information about voters, has said that a computer error on Wednesday briefly allowed the campaigns to review information that had been gathered by their rivals.

The Bernie Sanders presidential campaign held a news conference Friday, Dec. 18, to address DNC accusations that it improperly accessed private voter data gathered by the campaign for Hillary Clinton. (Monica Akhtar/The Washington Post)

The company maintains a master voter list for the DNC and rents it to national and state campaigns, which then add their own, proprietary information gathered by field workers and volunteers. Firewalls are supposed to prevent campaigns from viewing data gathered by rival campaigns.

The Sanders campaign has acknowledged that several of its staffers probed the system during the time of the error cited by NGP-VAN. One operative, data director Josh Uretsky, was fired as a result of the incident. Weaver said the actions of several others are being reviewed.

Landing at the airport in Manchester, N.H., ahead of Saturday’s debate, Wasserman Schultz said that Sanders himself was unaware of the breach until she called to discuss it 24 hours after it took place. “He was stunned,” she said. “I know that Sen. Sanders had absolutely nothing to do with this. . . . Unfortunately, he has staff who acted inappropriately, and they need to be held accountable.”

The severity of the data breach itself remained an issue of serious dispute Friday.

Audit data from NGP-VAN and provided to The Washington Post by the Clinton campaign showed that four Sanders staffers conducted 24 separate searches of Clinton data during a 40-minute window Wednesday, targeting early voting states and searching for lists of voters most and least likely to support Clinton. The logs show that in some cases, the staffers saved the search results in new folders created within the system.

“This was a very egregious breach and our data was stolen. This was not an inadvertent glimpse into our data,” Clinton’s campaign manager, Robby Mook, told reporters.

On CNN, Clinton campaign spokesman Brian Fallon accused the Sanders staffers of acting “like kids in the candy store.”

“They went hog wild, downloading as much data as they could,” he said.

Later Friday, the Clinton camp struck a more conciliatory tone, issuing a statement in which Fallon said that his campaign was hopeful the matter would be resolved Friday night and that the Sanders team would get access to its voter files “right away.”

Uretsky told The Post that he and the others conducted the searches of Clinton data after they discovered the software glitch only in an effort to discover the extent of their own data exposure. “We intentionally did it in a way that was trackable and traceable so that when they did an audit they would be able to see exactly what we did,” he said.

Uretsky said there was no attempt to take Clinton information out of the software system.

Weaver blamed the software vendor for the breach, which allowed all campaigns to access one another’s data for a time, insisting that the Sanders campaign had actually quietly alerted the DNC to problems with another vendor system in October.

In the lawsuit, the campaign argued that a “similar security incident” during the 2008 presidential campaign resulted in “unintentional transmission of confidential information” to Clinton’s unsuccessful presidential campaign against Barack Obama.

Weaver said a tick-tock provided to the Sanders campaign by the computer vendor confirmed that staffers were not attempting to remove significant Clinton data from the system.

“We are running a clean campaign,” he said. “We don’t need dirty tricks.”

Even before this week, Sanders backers had accused the DNC of trying to protect Clinton by limiting the number and prominence of debates — a narrative that plays into his anti-establishment appeal.

“They’ve been sabotaging Bernie’s campaign all along,” said RoseAnn DeMoro, executive director of National Nurses United, an 185,000-member union that is backing Sanders.

News of the data breach broke just as Sanders was enjoying a fresh burst of momentum after months in which his campaign appeared to have stalled.

On Thursday, Sanders received his biggest union endorsement to date, from the 700,000-member Communications Workers of America. He also was endorsed by Democracy for America, a progressive group that claims 1 million members nationwide. That group, founded by former Vermont governor Howard Dean, who is backing Clinton, said it had surveyed its membership and found 88 percent favored endorsing Sanders.

Sanders, who has raised most of his money from small donors over the Internet, also this week celebrated a fundraising milestone: more than 2 million contributions to his campaign. That figure made him competitive with the effort of President Obama’s 2012 re-election effort during the same stretch.