The announcement is part of its push toward a "privacy sandbox," which is aimed to let publishers target ads based on people's interests without violating their privacy. It also comes as Google's search is being attacked by lawmakers, state and federal prosecutors.