New issue
Advanced search Search tips

Issue 811338 link

Starred by 1 user

Issue metadata

Status: Verified
Owner:
Closed: Feb 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 1
Type: Bug



Sign in to add a comment

Setting device wallpaper can crash chrome://policy

Project Member Reported by ljusten@chromium.org, Feb 12 2018

Issue description

Chrome Version: 66.0.3342.0 (dev)
OS: Chrome OS

What steps will reproduce the problem?
(1) For an Active Directory managed Chromebook, set DeviceWallpaperImage to "\\example\example.jpg"
(2) Go to chrome://policy
(3) Hit the reload button

What is the expected result?
Policy is rejected since it actually requires a JSON string with URL and hash.

What happens instead?
Chrome crashes.

 
Xiaoqian, I can provide you with credentials to reproduce the issue (you won't need to set up an Active Directory server).

Comment 2 by x...@chromium.org, Feb 12 2018

Cc: x...@chromium.org
Owner: wzang@chromium.org
assign to wzang@, since he worked on wallpaper refactoring these days

Comment 3 by wzang@chromium.org, Feb 12 2018

ljusten@, please provide the credentials. Thanks.
Description: Show this description
I think it simply crashes on invalid JSON, probably because it doesn't check for nullptr. Maybe DecodeJsonStringAndDropUnknownBySchema could be used instead.
Labels: -Pri-2 M-66 Pri-1
Owner: rsorokin@chromium.org
Status: Started (was: Assigned)
Project Member

Comment 8 by bugdroid1@chromium.org, Feb 26 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/73920197f02b8e2af020d9ed76c53b41001000f4

commit 73920197f02b8e2af020d9ed76c53b41001000f4
Author: Roman Sorokin <rsorokin@chromium.org>
Date: Mon Feb 26 17:57:52 2018

Check wallpaper image policy for validity.

Fixes that setting the policy to incorrect JSON crashes Chrome.

BUG= chromium:811338 
TEST=DeviceSettingsProviderTest.SetWallpaperSettings

Change-Id: I4f51c4b13975215ec486618c3609b895a39f9718
Reviewed-on: https://chromium-review.googlesource.com/934447
Commit-Queue: Roman Sorokin <rsorokin@chromium.org>
Reviewed-by: Julian Pastarmov <pastarmovj@chromium.org>
Cr-Commit-Position: refs/heads/master@{#539194}
[modify] https://crrev.com/73920197f02b8e2af020d9ed76c53b41001000f4/chrome/browser/chromeos/policy/device_policy_decoder_chromeos.cc
[modify] https://crrev.com/73920197f02b8e2af020d9ed76c53b41001000f4/chrome/browser/chromeos/settings/device_settings_provider.cc
[modify] https://crrev.com/73920197f02b8e2af020d9ed76c53b41001000f4/chrome/browser/chromeos/settings/device_settings_provider_unittest.cc

Status: Fixed (was: Started)
Status: Verified (was: Fixed)
Verified fixed, Chrome doesn't crash when DeviceWallpaperImage is set to "\\example\example.jpg", it just ignores invalid JSON and leaves policy unset.

Chrome OS: 10895.56.0
Chrome: 69.0.3497.95
Device: Robo

Sign in to add a comment