codesign issue with files with space #122

Open
opened 2022-06-21 11:05:12 -05:00 by etrinh · 1 comment
etrinh commented 2022-06-21 11:05:12 -05:00 (Migrated from github.com)

Hi,

Thank you very much for the sigtool addition!
Just a small remark, it fails to sign files with spaces.

In file /cctools/include/stuff/port.h
On line 60:
snprintf(codesign_command, sizeof(codesign_command), "%s -s - -f %s", codesign, filename);
Can be replaced with something like (quotes added):
snprintf(codesign_command, sizeof(codesign_command), "%s -s - -f '%s'", codesign, filename); \

Hi, Thank you very much for the sigtool addition! Just a small remark, it fails to sign files with spaces. In file /cctools/include/stuff/port.h On line 60: snprintf(codesign_command, sizeof(codesign_command), "%s -s - -f %s", codesign, filename); \ Can be replaced with something like (quotes added): snprintf(codesign_command, sizeof(codesign_command), "%s -s - -f '%s'", codesign, filename); \
tpoechtrager commented 2022-06-21 11:53:01 -05:00 (Migrated from github.com)

Hi,
thanks for the hint. I think it should be replaced by execvp or something similar to get rid of the issue. Adding quotes doesn't fix the issue entirely. The entire macro needs some rework. There seem to be some obvious bugs.

Hi, thanks for the hint. I think it should be replaced by `execvp` or something similar to get rid of the issue. Adding quotes doesn't fix the issue entirely. The entire macro needs some rework. There seem to be some obvious bugs.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
miles/cctools-port#122
No description provided.