在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称:aerogear/aerogear-ios-oauth2开源软件地址:https://github.com/aerogear/aerogear-ios-oauth2开源编程语言:Swift 98.4%开源软件介绍:aerogear-ios-oauth2OAuth2 Client based on aerogear-ios-http.
Table of ContentFeatures
InstallationCocoaPodsIn your pod 'AeroGearOAuth2' and then: pod install to install your dependencies UsageGrant for GET with a predefined config like Facebooklet facebookConfig = FacebookConfig(
clientId: "YYY",
clientSecret: "XXX",
scopes:["photo_upload, publish_actions"]
)
let oauth2Module = AccountManager.addFacebookAccount(config: facebookConfig)
let http = Http()
http.authzModule = oauth2Module
http.request(method: .get, path: "/get", completionHandler: {(response, error) in
// handle response
}) OpenID Connect with Keycloaklet keycloakConfig = KeycloakConfig(
clientId: "sharedshoot-third-party",
host: "http://localhost:8080",
realm: "shoot-realm",
isOpenIDConnect: true
)
let oauth2Module = AccountManager.addKeycloakAccount(config: keycloakConfig)
let http = Http()
http.authzModule = oauth2Module
oauth2Module.login {(accessToken: AnyObject?, claims: OpenIdClaim?, error: NSError?) in // [1]
// Do your own stuff here
}
DocumentationFor more details about that please consult our documentation. Demo appsTake a look in our demo apps: DevelopmentIf you would like to help develop AeroGear you can join our developer's mailing list, join #aerogear on Freenode, or shout at us on Twitter @aerogears. Also takes some time and skim the contributor guide Questions?Join our user mailing list for any questions or help! We really hope you enjoy app development with AeroGear! Found a bug?If you found a bug please create a ticket for us on Jira with some steps to reproduce it. |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论