Skip to content

Commit

Permalink
fix: remove codeChallenge and codeChallengeMethod
Browse files Browse the repository at this point in the history
This are not supported through `additionalParameters`.
Closes #25
  • Loading branch information
ColinFrick committed Dec 19, 2024
1 parent d9254b5 commit a0f233b
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 18 deletions.
6 changes: 0 additions & 6 deletions Sources/FusionAuth/oauth/OAuthAuthorizationService.swift
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,6 @@ public class OAuthAuthorizationService {
if locale != nil {
additionalParameters.updateValue(locale!, forKey: "locale")
}
if options.codeChallenge != nil {
additionalParameters.updateValue(options.codeChallenge!, forKey: "code_challenge")
}
if options.codeChallengeMethod != nil {
additionalParameters.updateValue(options.codeChallengeMethod!.rawValue, forKey: "code_challenge_method")
}
if options.idpHint != nil {
additionalParameters.updateValue(options.idpHint!, forKey: "idp_hint")
}
Expand Down
8 changes: 0 additions & 8 deletions Sources/FusionAuth/oauth/OAuthAuthorizeOptions.swift
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,6 @@ public struct OAuthAuthorizeOptions {
let redirectUri: String
/// The identity provider hint to be used for the OAuth authorize request.
let idpHint: String?
/// The code challenge to be used for the OAuth authorize request.
let codeChallenge: String?
/// The code challenge method to be used for the OAuth authorize request.
let codeChallengeMethod: OAuthCodeChallengeMethod?
/// An optional email address or top level domain that can allow you to bypass the FusionAuth login
/// page when using managed domains.
let loginHint: String?
Expand All @@ -37,8 +33,6 @@ public struct OAuthAuthorizeOptions {
bundleId: String = Bundle.main.bundleIdentifier ?? "",
redirectUriSuffix: String = ":/oauth2redirect/ios-provider",
idpHint: String? = nil,
codeChallenge: String? = nil,
codeChallengeMethod: OAuthCodeChallengeMethod? = nil,
loginHint: String? = nil,
deviceDescription: String? = nil,
nonce: String? = nil,
Expand All @@ -49,8 +43,6 @@ public struct OAuthAuthorizeOptions {
self.bundleId = bundleId
self.redirectUri = bundleId + redirectUriSuffix
self.idpHint = idpHint
self.codeChallenge = codeChallenge
self.codeChallengeMethod = codeChallengeMethod
self.loginHint = loginHint
self.deviceDescription = deviceDescription
self.nonce = nonce
Expand Down
4 changes: 0 additions & 4 deletions Sources/FusionAuth/oauth/OAuthCodeChallengeMethod.swift

This file was deleted.

0 comments on commit a0f233b

Please sign in to comment.