Skip to content

fix(macos-sign): import the signing certificate as an explicit pkcs12 (fix: #15843) - #15844

Open
lazerg wants to merge 1 commit into
tauri-apps:devfrom
lazerg:fix/issue-15843-p12-import-format
Open

fix(macos-sign): import the signing certificate as an explicit pkcs12 (fix: #15843)#15844
lazerg wants to merge 1 commit into
tauri-apps:devfrom
lazerg:fix/issue-15843-p12-import-format

Conversation

@lazerg

@lazerg lazerg commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

security import was left to guess the file format. On macOS 26 that guess goes wrong for p12 files using modern PBES2/AES encryption and the import dies with MAC verification failed during PKCS12 import (wrong password?), even when the password is correct.

I reproduced it on macOS 26.6.1 with a p12 encrypted using AES-256-CBC with a SHA-256 MAC. Keychain::with_certificate_file fails on it, and the same file with the same password imports fine as soon as -f pkcs12 is passed. Older p12s using the legacy RC2/3DES encoding import either way, so nothing changes for those.

One thing worth flagging: naming the format means the import no longer accepts a bare PEM or DER certificate, which inference used to let through. Every caller in the tree passes a p12 and ENVIRONMENT_VARIABLES.md documents these variables as p12, so I left it strict rather than adding a fallback, but say the word if you would rather it retried without the flag.

Fixes #15843

@lazerg
lazerg requested a review from a team as a code owner August 8, 2026 11:45
@lazerg
lazerg force-pushed the fix/issue-15843-p12-import-format branch from df89909 to 13d288d Compare August 8, 2026 11:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[bug] iOS PKCS#12 certificate import fails on macOS 26 when import format is implicit

1 participant