Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[acition] adds 'Apple Distribution' as valid authority when verifying builds #16196

Merged

Conversation

rpassis
Copy link
Contributor

@rpassis rpassis commented Mar 21, 2020

Checklist

  • I've run bundle exec rspec from the root directory to see all new and existing tests pass
  • I've followed the fastlane code style and run bundle exec rubocop -a to ensure the code style is valid
  • I've read the Contribution Guidelines
  • I've updated the documentation if necessary.

Motivation and Context

Fixes #16020

verify_build command fails when using the new cross-platform distribution certificates.

Description

The current logic in verify build expects the certificate authority to match a regex of Authority=i(Phone|OS) Distribution.

However, the new cross-platform certificates made available by Apple with Xcode 11 have the certificate authority as Apple Distribution, which does not match the regex and causes validation to fail.

This PR addresses the issue by adding Apple Distribution as a valid authority option during build validation.

Note that the implementation of the regex has to use a more specific expression because matching only for (iOS|iPhone|Apple) will cause Apple Root CA and Apple Worldwide Certificate Authority certificates to be incorrectly identified as a match.

@rpassis rpassis force-pushed the fix-verify-build-certificate-authority branch from 00ea8a0 to b7ab7ae Compare March 22, 2020 02:14
@joshdholtz joshdholtz changed the title Adds 'Apple Distribution' as valid authority when verifying builds [acition] adds 'Apple Distribution' as valid authority when verifying builds Apr 3, 2020
Copy link
Member

@joshdholtz joshdholtz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good! Thanks for making the fix 😊 Appreciate it! ❤️

@joshdholtz joshdholtz merged commit 373921c into fastlane:master Apr 3, 2020
@rpassis rpassis deleted the fix-verify-build-certificate-authority branch April 3, 2020 17:12
@fastlane-bot
Copy link

Hey @rpassis 👋

Thank you for your contribution to fastlane and congrats on getting this pull request merged 🎉
The code change now lives in the master branch, however it wasn't released to RubyGems yet.
We usually ship about once a week, and your PR will be included in the next one.

Please let us know if this change requires an immediate release by adding a comment here 👍
We'll notify you once we shipped a new release with your changes 🚀

Copy link

@fastlane-bot fastlane-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Congratulations! 🎉 This was released as part of fastlane 2.145.0 🚀

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

verify_build searches for wrong Authority for provision_type
4 participants