Overview
macOS requires applications to be signed and notarized to run on user systems without security warnings. Container Kit implements:- Code Signing: Cryptographically signs the app with your Developer ID
- Hardened Runtime: Security features required for notarization
- Notarization: Apple verification process for malware
- Update Signing: Secure app updates with Tauri’s updater
Prerequisites
- Apple Developer account ($99/year)
- Developer ID Application certificate
- App-specific password for notarization
- macOS development machine
Code Signing Setup
1. Developer ID Certificate
Request certificate
Sign in to Apple Developer and:
- Go to Certificates, Identifiers & Profiles
- Click + to create a new certificate
- Select Developer ID Application
- Follow prompts to generate and download the certificate
2. Get Your Team ID
Find your Apple Team ID:- Go to Apple Developer Account
- Navigate to Membership
- Copy your Team ID (10-character alphanumeric)
3. Create App-Specific Password
Sign in to Apple ID
Go to appleid.apple.com and sign in.
Environment Configuration
Create a.env file in your project root with the following variables:
Environment Variable Details
| Variable | Description | Example |
|---|---|---|
APPLE_ID | Your Apple Developer email | [email protected] |
APPLE_PASSWORD | App-specific password | xxxx-xxxx-xxxx-xxxx |
APPLE_TEAM_ID | 10-character Team ID | ABCD123456 |
APPLE_SIGNING_IDENTITY | Full signing identity name | Developer ID Application: ... |
TAURI_SIGNING_PRIVATE_KEY | Private key for update signing | Generated key |
TAURI_SIGNING_PRIVATE_KEY_PASSWORD | Password for private key | Your secure password |
Tauri Configuration
Thetauri.conf.json is already configured for signing:
Key Settings
- hardenedRuntime: Required for notarization
- minimumSystemVersion: Minimum macOS version (26.0)
- createUpdaterArtifacts: Generates update signatures
Generating Update Keys
For Tauri’s secure updater, generate a signing key pair:Generate key pair
Install Tauri CLI and generate keys:This creates:
- Private key:
~/.tauri/container-kit.key - Public key: Printed to console
Building with Code Signing
Once configured, build with signing enabled:Verification
Verify Code Signature
Check that your app is properly signed:Verify Notarization
Check notarization status:Verify DMG Signature
Check DMG signing:Troubleshooting
Signing Identity Not Found
If the build can’t find your signing identity:Notarization Fails
Check notarization logs:- Hardened runtime not enabled (check
tauri.conf.json) - Unsigned external binaries (ensure
containerbinary is signed) - Invalid entitlements
App-Specific Password Issues
If notarization authentication fails:- Verify your app-specific password is correct
- Regenerate the password at appleid.apple.com
- Update
.envwith the new password
Hardened Runtime Errors
If you see hardened runtime errors:- Ensure
hardenedRuntime: trueintauri.conf.json - Check that all embedded binaries are signed
- Verify entitlements are properly configured
Security Best Practices
Use environment-specific configs
Create different configs for development and production:
.env.development- No signing variables.env.production- Full signing configuration
Rotate credentials regularly
- Regenerate app-specific passwords periodically
- Update Tauri signing keys if compromised
- Review certificate expiration dates
CI/CD Integration
For automated signing in CI/CD pipelines:- Store secrets securely: Use GitHub Secrets, GitLab CI/CD variables, etc.
- Create .env in CI: Generate
.envfile from secrets before build - Import certificates: Install Developer ID certificate in CI keychain
- Set up keychain access: Unlock keychain for signing
Next Steps
- Production Build - Build process overview
- Development Build - Development setup