Skip to content

Commit

Permalink
Ensure paths are passed properly escaped into codesign command in mac…
Browse files Browse the repository at this point in the history
…-crafter

Signed-off-by: Claudio Cambra <[email protected]>
  • Loading branch information
claucambra authored and backportbot[bot] committed Nov 20, 2024
1 parent 8d0a614 commit 3050c24
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion admin/osx/mac-crafter/Sources/Utils/Codesign.swift
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ func codesign(
options: String = "--timestamp --force --preserve-metadata=entitlements --verbose=4 --options runtime --deep"
) throws {
print("Code-signing \(path)...")
let command = "codesign -s \"\(identity)\" \(options) \(path)"
let command = "codesign -s \"\(identity)\" \(options) \"\(path)\""
guard shell(command) == 0 else {
throw CodeSigningError.failedToCodeSign("Failed to code-sign \(path).")
}
Expand Down

0 comments on commit 3050c24

Please sign in to comment.