Skip to content

Escape double quotes with reg_set #38

@rasta-mouse

Description

@rasta-mouse

I feel like this is a silly question, but how do you escape double quotes when using reg_set? I tried a few variants.

Command:

reg_set HKCU Software\Microsoft\Windows\CurrentVersion\Run Payload REG_SZ "C:\Path\to\payload.exe" /q /n

Result:

C:\Path\to\payload.exe

Command:

reg_set HKCU Software\Microsoft\Windows\CurrentVersion\Run Payload REG_SZ "\"C:\Path\to\payload.exe\" /q /n"

Result:

\

Command:

reg_set HKCU Software\Microsoft\Windows\CurrentVersion\Run Payload REG_SZ '"C:\Path\to\payload.exe" /q /n'

Result:

'"C:\Path\to\payload.exe"

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