FIRPhoneMultiFactorGenerator.h 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. /*
  2. * Copyright 2019 Google
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License");
  5. * you may not use this file except in compliance with the License.
  6. * You may obtain a copy of the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS,
  12. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. * See the License for the specific language governing permissions and
  14. * limitations under the License.
  15. */
  16. #include <TargetConditionals.h>
  17. #if TARGET_OS_IOS
  18. #import <Foundation/Foundation.h>
  19. #import "FIRPhoneAuthCredential.h"
  20. #import "FIRPhoneMultiFactorAssertion.h"
  21. NS_ASSUME_NONNULL_BEGIN
  22. /** @class FIRPhoneMultiFactorGenerator
  23. @brief The data structure used to help initialize an assertion for a second factor entity to the
  24. Firebase Auth/CICP server. Depending on the type of second factor, this will help generate
  25. the assertion.
  26. */
  27. NS_SWIFT_NAME(PhoneMultiFactorGenerator)
  28. @interface FIRPhoneMultiFactorGenerator : NSObject
  29. /** @fn assertionWithCredential:
  30. @brief Initializes the MFA assertion to confirm ownership of the phone second factor. Note that
  31. this API is used for both enrolling and signing in with a phone second factor.
  32. @param phoneAuthCredential The phone auth credential used for multi factor flows.
  33. */
  34. + (FIRPhoneMultiFactorAssertion *)assertionWithCredential:
  35. (FIRPhoneAuthCredential *)phoneAuthCredential;
  36. @end
  37. NS_ASSUME_NONNULL_END
  38. #endif