Skip to content

Commit f64e8a6

Browse files
committed
Restore Old Behavior of Empty Passwords in .p12s
This fixes a regression in ac9086a
1 parent ac9086a commit f64e8a6

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

_ldid

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
_arguments \
44
'-S-[Add signature]:entitlements:_files' \
5-
'-w[Shallow sign]' \
5+
'-w[Shallow sign]' \
66
'-Q-[Embed requirements]:requirements:_files' \
77
'(-S)-r[Remove signature]' \
88
'(-r)-h[Print signature information]' \

ldid.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@
116116

117117
bool flag_w(false);
118118
bool flag_U(false);
119-
std::string password;
119+
std::string password = "";
120120
std::vector<std::string> cleanup;
121121
bool flag_H(false);
122122

@@ -1826,7 +1826,7 @@ class Stuff {
18261826
exit(1);
18271827
}
18281828

1829-
if (!flag_U) {
1829+
if (PKCS12_verify_mac(value_, "", 0) == 0 && !flag_U) {
18301830
char passbuf[2048];
18311831
UI_UTIL_read_pw_string(passbuf, 2048, "Enter password: ", 0);
18321832
password = passbuf;

0 commit comments

Comments
 (0)