When the National Security Agency’s routine collection of Americans’ telephone and electronic communication records became known last summer, President Barack Obama defended the program and said the nation “is going to have to make some choices” about the balance between privacy and security.

But choosing overly intrusive security would create an insecurity all its own.

And though the U.S. Supreme Court on Monday rejected a petition challenging the NSA’s massive personal-records grab, the courts — and Congress — should still have more to say on this troubling issue.

Indeed, though that legal action by Electronic Privacy Information Center was turned back by the high court, the wording from that challenge is all too accurate — and chilling. It argued that the Foreign Intelligence Surveillance Court “exceeded its statutory jurisdiction when it ordered production of millions of domestic telephone records that cannot plausibly be relevant to an authorized investigation.”

But that hasn’t stopped Sen. Dianne Feinstein, D-Calif., chair of the Senate Select Committee on Intelligence, from pushing her bill, introduced along with Sen. Saxby Chambliss, R-Ga., to enshrine in law an NSA right to collect bulk electronic communications data in a potentially huge expansion of government domestic surveillance powers.

The 1978 Foreign Intelligence Surveillance Act was supposed to place constraints on NSA surveillance. It has not lived up to its billing. For example, the FISA court effectively rewrote the controversial Section 215 of the Patriot Act that required any seizure be relevant to an ongoing probe.

Elizabeth Goitein, co-director of the Liberty and National Security Program at New York University’s Brennan Center for Justice, recently told The Washington Post: “The court accepted the NSA’s argument that all of the [telephone] records qualified as relevant because a tiny fraction of them might prove to be relevant in the future. It turned what was supposed to be a limiting principle into a license to cast a dragnet.”

If Sen. Feinstein’s bill becomes law, law enforcement and intelligence agencies might be able to persuade courts that this dragnet principle should be extended to emails, tax records, credit card statements and bank accounts. In effect, the law could allow the government to sweep up data on every significant activity of every American as it willed.

Sen. Feinstein, the president and others have offered assurances that collecting the data isn’t the same as listening to and reading the personal communications.

But that’s a distinction with precious little difference.

A better bill has been proposed by Rep. James Sensenbrenner, R-Wisc., an author of the Patriot Act, and Sen. Patrick Leahy, D-Vt., chair of the Senate Judiciary Committee. It would restore the original intent of Section 215 — that any government demand for data be “relevant” to an ongoing probe. That would at least stop the mindless bulk collection of sensitive data on all Americans.

And even better would be a serious effort to restore privacy protections to personal data entrusted to service providers like telephone and Internet companies and banks.

Extending the Fourth Amendment to such personal data would restore a healthy balance between privacy and the power of the state.