President Bush and Sen. John McCain (R-Ariz.) joined forces yesterday to seek legal action to reduce the influence of "527" political organizations, but the two remained in disagreement over whether Bush should condemn a television ad by the group Swift Boat Veterans for Truth attacking John F. Kerry's Vietnam service.

Bush called McCain en route to a campaign event in New Mexico to say his campaign would go to federal court to force the Federal Election Commission to prevent the independent groups -- named for the section of the tax code that governs their activities -- from raising and spending money in unlimited amounts.

McCain said he secured Bush's commitment to support legislation to regulate the groups. The organizations have used a loophole in the new campaign finance law -- of which McCain was one of the two principal architects -- to become significant and controversial actors in the campaign on behalf of both the president and the senator from Massachusetts.

Separately, Kerry agreed to take off the air a commercial using footage from a debate during the 2000 GOP primaries in which McCain directly criticized Bush for allowing supporters of his to question McCain's commitment to veterans. McCain had asked Kerry to stop running the ad.

In an interview with Washington Post editors and reporters, McCain said that he is grateful for Kerry's action and that he still hopes Bush will condemn the Swift boat veterans' ad attacking Kerry's service. McCain added that he plans to raise the issue when he campaigns with Bush next week.

But McCain, who has tried to put behind him bitterness over his defeat at Bush's hands in 2000 while becoming one of the president's most significant allies this year, also said he saw Bush's willingness to go to court to rein in the groups as more significant than not singling out the ad for criticism.

"I would like for him to specifically condemn that ad," McCain said. "But the most important thing to me is his commitment to bring them all under control, and that way we can do that. I can't dictate the president's response. I can only dictate my view, and my view is the ads are wrong and they should be taken down."

Later, asked why he is not willing to use his leverage with the Bush campaign to force a condemnation of the anti-Kerry ad, McCain said, "I'm just not sure that in the grand scheme of things that should determine whether I support the president's reelection or not. If I threatened him with some kind of retaliation, that obviously would have some impact on his reelectability."

McCain, a prisoner of war in Vietnam, was among the first to condemn the veterans group for challenging Kerry's combat record and spoke out against the ad throughout his 90-minute luncheon interview. But he also said Kerry had invited scrutiny of his record by putting so much emphasis on Vietnam at the Democratic National Convention in Boston last month.

"His critics are saying, 'Look, you made it fair game,' " McCain said. "I mean, that's very legitimate, and I think there's a risk that he took when he made it such a centerpiece. He may be paying a very heavy price."

McCain said that he urged Kerry sometime ago not to talk about Vietnam during his campaign. "I did advise John. I said, 'Look, you shouldn't talk about Vietnam because everybody else will. Let everybody else do it.' His advisers figured that was probably not enough, that he had to emphasize that in his campaign. In my campaign, as you know, I didn't talk about it because I didn't need to."

McCain also said he drew a distinction between the first anti-Kerry ad by the veterans group, which focused on Kerry's Vietnam service, and a second ad now airing that criticizes Kerry for his leadership in the antiwar movement after he returned from Vietnam. McCain condemned the first ad but not the second.

Speaking with emotion, McCain said he is pained that the attacks on Kerry's Vietnam record are "ripping up all the old wounds" from three decades ago that he said he worked for years to heal. He said neither Kerry nor Bush should have their service records challenged.

"I believe President Bush served honorably in the National Guard. I believe Senator Kerry served honorably," he said. "Let's worry about the war that's going on in Iraq. Probably some American is dying today in Iraq. I'd like us to focus our attention on the war at hand and how we can win it, rather than revisiting the one that was over 30 years ago."

Asked whether he is equally passionate in wanting to put Kerry's antiwar activities off-limits, he said, "I think his activities after the war open, and are subject to, any debate and discussion that they want to, but I still say that it has the effect of reopening these wounds. Everybody is accountable for what they do, and certainly John Kerry is accountable for what he did after the war, and people can make a judgment."

Throughout much of the interview, McCain carefully chose his words as he tried to demonstrate his commitment to Bush's reelection while preserving a reputation for independence and straight talk. He blamed Bush's campaign and allies for attacks leveled against him in the 2000 primary campaign but said that although others have charged that the Swift boat controversy follows a similar pattern, he has seen no proof that Bush or his team is behind the effort.

"I think from what we learned during the campaign, the president's people were behind that [a third-party ad attacking him] and many, many other things that happened in South Carolina," McCain said. "But the most important aspect of this whole thing for me is to not look back in anger. . . . For to me to look back in anger at something that happened in the year 2000 is, one, sore loser, which Americans don't like, and two, would impair my ability to serve the country."

He said his high-profile support for Bush this year is not materially different from the campaigning he did for Bush in 2000 and for GOP candidates in 2002, but said he will continue to speak out when he disagrees with Bush or others in his party. McCain will speak Monday at the Republican National Convention and will campaign with Bush next week.

"I said since January, when the Bush campaign asked me to campaign for him in January in New Hampshire, that I was supporting his reelection. Now if that's called being a good soldier, then fine, I will take that indictment. But my M.O. has not changed in the slightest," he said.

McCain said the president deserves reelection for rallying the country after the attacks of Sept. 11, 2001. He said he supports Bush's decision to invade Iraq, despite the failure to find weapons of mass destruction, saying Saddam Hussein was a threat.

He enumerated disagreements with Kerry on foreign policy, including the Democratic nominee's vote against the resolution authorizing the Persian Gulf War in 1991 and his vote against the $87 billion authorization for Iraq and Afghanistan last year. "But I do not mean to say that would make him a bad president," McCain added.

Although McCain expressed satisfaction that Bush had joined the legal battle against the 527 groups, he said he believes it is too late to have any impact on the current campaign.

Sen. John McCain said "527" groups need to be brought "under control."McCain said he had urged Democrat John F. Kerry not to talk about his Vietnam service during his campaign.