The disclosure – the second such revelation in a matter of days – came in response to questions posed by The Associated Press.
The White House Web site uses what's known as a Web bug to anonymously keep track of who's visiting and when. A Web bug is essentially a tiny graphic image - a dot, really - that's virtually invisible. In this case, the bug is pulled from a server maintained by WebTrends and lets the traffic analytic company know that another person has visited a specific page on the site.
Last week, theafter a privacy activist complained and Wednesday, agency officials acknowledged they had made a mistake.
Until Tuesday, the NSA site was creating two cookie files that do not expire until 2035 — likely beyond the life of any computer in use today.
As for the White House web site, David Almacy, the White House's Internet director, is promising that there will be an investigation into whether the practice is consistent with a 2003 policy from the White House's Office of Management and Budget banning the use of most such technologies at government sites.
"No one even knew it was happening," Almacy said. "We're going to work with the contractor to ensure that it's consistent with the OMB policy."
An official with the contractor for the White House web site, WebTrends Inc., said later in the day that although a cookie may be used, no data from it is actually sent back to the company.
Web bugs themselves are not prohibited, but when they are linked to a cookie so that a site can tell if the same person has visited again - a federal agency using them must demonstrate a "compelling need," get a senior official's signoff and disclose such usage, said Peter Swire, a Clinton administration official who helped draft the original rules.
Cookies are widely used at commercial Web sites and can make Internet browsing more convenient by letting sites remember user preferences. For instance, visitors would not have to repeatedly enter passwords at sites that require them.
But privacy advocates complain that cookies can also track Web surfing, even if no personal information is actually collected.
In a 2003 memo, the White House's Office of Management and Budget prohibits federal agencies from using persistent cookies — those that aren't automatically deleted right away — unless there is a "compelling need."
Jason Palmer, vice president of product management for Portland, Ore.-based WebTrends, insisted the cookies are not used in such manner.