Code: void AwFeatureListCreator::SetUpFieldTrials() {
  auto* metrics_client = AwMetricsServiceClient::GetInstance();

  DCHECK(!field_trial_list_);
  field_trial_list_ = std::make_unique<base::FieldTrialList>(
      metrics_client->CreateLowEntropyProvider());

  std::unique_ptr<variations::SeedResponse> seed = GetAndClearJavaSeed();
  base::Time null_time;
  base::Time seed_date =
      seed ? base::Time::FromJavaTime(seed->date) : null_time;
  variations::UIStringOverrider ui_string_overrider;
  client_ = std::make_unique<AwVariationsServiceClient>();
  auto seed_store = std::make_unique<variations::VariationsSeedStore>(
      local_state_.get(), /*initial_seed=*/std::move(seed),
      /*on_initial_seed_stored=*/base::DoNothing());

  if (!seed_date.is_null())
    seed_store->RecordLastFetchTime(seed_date);

  variations_field_trial_creator_ =
      std::make_unique<variations::VariationsFieldTrialCreator>(
          local_state_.get(), client_.get(), std::move(seed_store),
          ui_string_overrider);
  variations_field_trial_creator_->OverrideVariationsPlatform(
      variations::Study::PLATFORM_ANDROID_WEBVIEW);

  std::set<std::string> unforceable_field_trials;
  variations::SafeSeedManager ignored_safe_seed_manager(true,
                                                        local_state_.get());

  variations_field_trial_creator_->SetupFieldTrials(
      cc::switches::kEnableGpuBenchmarking, switches::kEnableFeatures,
      switches::kDisableFeatures, unforceable_field_trials,
      std::vector<std::string>(),
      content::GetSwitchDependentFeatureOverrides(
           *base::CommandLine::ForCurrentProcess()),
       /*low_entropy_provider=*/nullptr, std::make_unique<base::FeatureList>(),
       aw_field_trials_.get(), &ignored_safe_seed_manager);
 }

Vulnerability Type: 
CWE ID: CWE-20
Summary: Inappropriate implementation in Omnibox in Google Chrome prior to 59.0.3071.92 for Android allowed a remote attacker to perform domain spoofing with RTL characters via a crafted URL page.
Commit Message: [AW] Add Variations.RestartsWithStaleSeed metric.

This metric records the number of consecutive times the WebView browser
process starts with a stale seed. It's written when a fresh seed is
loaded after previously loading a stale seed.

Test: Manually verified with logging that the metric was written.
Bug: 1010625
Change-Id: Iadedb45af08d59ecd6662472670f848e8e99a8d9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1851126
Commit-Queue: Robbie McElrath <rmcelrath@chromium.org>
Reviewed-by: Nate Fischer <ntfschr@chromium.org>
Reviewed-by: Ilya Sherman <isherman@chromium.org>
Reviewed-by: Changwan Ryu <changwan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#709417}