Skip to content

Free-typed install folder bypasses the foldersInUse equality check #141

Description

@Pixnop

installGameVersion refuses folders already in use through exact string comparison, but AddVersion lets the player type the target folder by hand. A trailing slash, or different casing on Windows, slips past the equality check while pointing at the same directory. The CDN install then unpacks into a folder the player manages themselves, registers it as a normal (deletable) version, and the next uninstall removes the whole thing.

This is a second route to the data loss PR #138 closes for registered folders, and the linked flag does not cover it. Surfaced while reviewing #138.

Fix direction: normalize before comparing (resolve, strip trailing separators, casefold on win32) in the domain check, plus a refusal verdict naming which registered path collided.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions