Policyedit
A Python program which is able to modify the device policies on a Chrome OS system. (WIP)
Install / Use
/learn @ading2210/PolicyeditREADME
Chrome OS Policy Editor
This is a Python program which is able to modify the device policies on a Chrome OS system, based on lilac.
Installation:
You must have Python 3 installed on Linux, with support for virtual environments and pip.
Clone this repository, and run the following commands:
python3 -m venv .venv
source .venv/bin/activate
pip3 install -r requirements.txt
Usage:
usage: main.py [-h] {view,patch} ...
positional arguments:
{view,patch}
view Read the device settings without modifying anything.
patch Patch an existing device policy file.
options:
-h, --help show this help message and exit
On Real Chrome OS:
- Make sure you are in developer mode and have rootfs verification off.
- Add
--disable-policy-key-verificationto the end of/etc/chrome_dev.conf. - Edit
/etc/lsb-releaseto change the release channel totestimage-channel. - Run
main.pywith the correct arguments, specifying any policy files that are in/var/lib/devicesettings/. - Copy the public key to
/var/lib/devicesettings/owner.key. - Overwrite the original policy files with the patched versions.
On Linux-ChromiumOS:
- Locate the user data directory (this defaults to
~/.config/chromium) or explicitly set it with--user-data-dir=DATA_DIR. - Run
main.py, specifying the policy file atDATA_DIR/stub_device_policy. - Overwrite the original policy with the patched version.
- Copy the public key to
DATA_DIR/stub_owner.key.
Copyright:
This repository is licensed under the GNU GPL v3.
ading2210/policyedit - A program to modify Chrome OS device policies
Copyright (C) 2024 ading2210
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>.
Related Skills
node-connect
344.1kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
96.8kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
344.1kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
344.1kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
