The American Civil Liberties Union filed a federal lawsuit Monday on behalf of the Libertarian Party against Virginia’s rules for circulating petitions to get candidates on the state’s presidential ballot.

Under Virginia law, candidates who are not from a major party have to follow strict guidelines to qualify for the general election ballot, collecting a minimum of 400 signatures from each congressional district and at least 10,000 overall. The signatures can only be collected by Virginia residents, a requirement the ACLU specifically targets in its suit, which was filed in U.S. District Court in Richmond.

“People from out of state have every right to promote their political ideas in Virginia, and the government has no legitimate interest in preventing them from doing so by circulating petitions,” said Rebecca K. Glenberg, the ACLU of Virginia’s legal director.

The Libertarian Party is hoping that a favorable ruling will allow it to use out-of-state residents to collect signatures ahead of the Aug. 24 deadline to make the November ballot.

Virginia’s ballot rules have come under heavy scrutiny this election cycle. After every candidate other than former Massachusetts governor Mitt Romney and Rep. Ron Paul (Tex.) failed to qualify for Virginia’s Republican presidential primary ballot, the other GOP hopefuls teamed up to file suit against the same residency requirement for petition circulators.

U.S. District Judge John A. Gibney Jr. in January denied their request to be added to the ballot, since none of them had collected the required 10,000 valid signatures. But he did indicate in his ruling that he thought the residency requirement was unconstitutional.

Caroline Gibson, a spokeswoman for the office of Virginia Attorney General Ken Cuccinelli II (R), said: “We have not yet seen the suit papers, but we plan to vigorously defend the law.”

This post has been updated since it was first published.