GOG Galaxy Games changeFolderPermissionsAtPath privilege escalation vulnerability
The privileged helper tool in GOG Galaxy for macOS exposes a function that changes a folder's permissions, and everything inside it, to be world-readable, writable and executable. An attacker could use this to alter permissions on privileged folders, crossing a privilege boundary and enabling execution of arbitrary code with elevated privileges.
Originally disclosed on Cisco Talos
An exploitable local privilege escalation vulnerability exists in the privileged helper tool of GOG Galaxy’s Games, version 1.2.47 for macOS. An attacker can globally adjust folder permissions leading to execution of arbitrary code with elevated privileges.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the helper tool accepts a caller-supplied path in changeFolderPermissionsAtPath without validating it, then applies world-readable, writable and executable permissions to that path and its contents while running as root.
Impact
An attacker could change permissions on privileged folders, crossing a privilege boundary and creating a situation that allows arbitrary code execution with elevated privileges; the text does not demonstrate a full exploit chain.
What the attacker needed
GOG Galaxy 1.2.47 installed on macOS; local access to the helper tool
The fix
The vendor patched the issue, presumably by validating the supplied path and restricting which folders the helper will modify.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
GOG Galaxy installs a small background service that runs with the highest level of permission on the computer (root). That service offers a command that makes a folder and its contents open to everyone, including writing and running files. If an attacker can call that command on a sensitive system folder, they can plant or modify files that the system later runs with high privileges.
What is Access control?
A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.