GithubHelp home page GithubHelp logo

Comments (5)

andrewjharms avatar andrewjharms commented on August 30, 2024 1

Oh, I see you committed a patch yesterday: 435f87c

Thanks! Will test soon.

from it-cpe.

andrewjharms avatar andrewjharms commented on August 30, 2024

Looks like changing ManagedBookmarks from :multi_string to :string prevents the error. However, bookmarks are not getting created properly. Here's some notes from me trying to debug why:

  • The ManagedBookmarks key can accept a few different formats (see https://www.chromium.org/administrators/complex-policies-on-windows). I'm assuming the desired output would be a single JSON string value for the ManagedBookmarks key.
  • When multiple bookmarks are defined, separately indexed keys are getting created - one for each bookmark - due to the if data_has_mulitple_entries? logic in to_chef_reg_provider. Assuming the desired output is a single JSON string, this logic should be modified to exclude ManagedBookmarks (as well as any other potential keys that require JSON strings for values).
  • The registry_key resource call in cpe_chrome_win.rb uses the full path for the key, e.g. HKLM\\Software\\Policies\\Google\\Chrome\\ManagedBookmarks. This additional folder/subkey is not required and should be at the root (HKLM\\Software\\Policies\\Google\\Chrome). Changing the registry_key resource to use setting.path instead of setting.fullpath solves this but may break other keys. The reference registry file linked in the source should be reviewed again to match the hierarchy (https://dl.google.com/dl/edgedl/chrome/policy/policy_templates.zip)
  • Unsurprisingly, using Ruby hash rockets syntax in the value of the ManagedBookmarks key results in an invalid JSON string, so bookmarks don't get created. The bookmarks do get created after changing the hash rockets to colons/proper JSON.

I will try to start a PR to address some of these things, but would appreciate some feedback on the above so I know that I'm taking the right approach.

from it-cpe.

svmastersamurai avatar svmastersamurai commented on August 30, 2024

Thanks for the bug report. I have a patch internally for this specific setting that should be up shortly.

from it-cpe.

andrewjharms avatar andrewjharms commented on August 30, 2024

Thanks @svmastersamurai, let me know how I can help with a PR.

from it-cpe.

andrewjharms avatar andrewjharms commented on August 30, 2024

Works great! Thanks for the patch.

from it-cpe.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.