Search results for

ASWebAuthenticationSession cookie

1,295 results found

Post

Replies

Boosts

Views

Activity

Safari 14 - Cookies are not sent for XHR requests on a subdomain
It seems to be a question that comes up often in different ways, but despite several hours of research I still haven't found a solution. I currently face an issue in Safari 14 on MacOS BigSur where cookies are never sent by Safari on XmlHttpRequests to an api on the same root domain. Indeed, i'm working on an Angular SPA where the client app is locally hosted at https://myapp.local and for tests purpose I have an api running locally on https://api.myapp.local. For some requests, we need to attach 2 cookies that are originally set by the API. I am able to see the said cookies in the API responses and in the storage section of Safari's DevTools, however they are never sent back to the server for subsequent XHR requests. (XHR with credentials) I did try different cookie's attributes but none of my tries were successful : sameSite=None, domain=myapp.local, Secure, httpOnly sameSite=Lax, domain=myapp.local, Secure, httpOnly The only way I found to get around the problem was to d
3
0
5.1k
Sep ’22
Is there a way to clear Auth cookies in SFSafariViewController?
My iOS application uses WKWebView to login to the application. Recently the application release has been rejected by Apple team for using WKWebView for login. Instead they suggested to go with SFSafariController. I need to clear the cookies before hitting the login url for fresh login. In WKWebView, I can clear cookies before opening an URL. I don't find an option to clear cookies in SFSafariController. If we dont clear auth cookies, user is getting auto logged into the app because of the existing cookie. Is there a way to clear Auth cookies in SFSafariViewController?
1
0
971
Sep ’22
Reply to "An error has occurred" while saving Pricing tiers in Appstore Connect – for 2 days already
SOLUTION FROM APPLE: I've got a reply from Apple support as follows: Follow this basic troubleshooting to attempt to solve it as this issue was previously reported and solved by our engineering team on August 8th. Make sure you are using the latest version of your browser. Clean the cache, cookies and history (all website data). Get out of your browser completely. Try again I would also like to recommend that you try Safari, since our website is optimized for Safari. If the error still appears, to better assist you, we need more information. Please provide the following: • Steps to reproduce the issue • Full-window screenshots or video illustrating the issue • Username of each user experiencing the issue • Web browsers that you were able to reproduce the issue in • Web browser version numbers • Apple ID of the In App Purchase **Works for me! **
Sep ’22
Reply to ASWebAuthenticationSession with Universal link never dismiss the sign-in screen
I create a singleton class to handle this SceneDelegate @available(iOS 13.0, *) func scene(_ scene: UIScene, continue userActivity: NSUserActivity) { // handle here OAuthManager.instance.callBackUserActivity(userActivity: userActivity) } OAuthManager.swift import Foundation import AuthenticationServices protocol UserActivityListener { func callBackUserActivity( userActivity : NSUserActivity ) } class OAuthManager { public static let instance = OAuthManager() var asWebSession: ASWebAuthenticationSession? } extension OAuthManager : UserActivityListener { func callBackUserActivity(userActivity: NSUserActivity) { // Get URL components from the incoming user activity. guard userActivity.activityType == NSUserActivityTypeBrowsingWeb, let incomingURL = userActivity.webpageURL, let components = NSURLComponents(url: incomingURL, resolvingAgainstBaseURL: true) else { return } // Check for specific URL components that you need. guard let path = components.path, let params = components.queryItems else { return }
Topic: Programming Languages SubTopic: Swift Tags:
Sep ’22
The items below are required to start the review process: There are still screenshot uploads in progress.
When I try to add my app for review for an update. The following error is displayed: The items below are required to start the review process: There are still screenshot uploads in progress. What I tried so far: Trying with different devices (Macbook, Windows) Deleting cookies and search history in the browser Trying with different browsers (Chrome MacOS, Chrome Windows, Safari MacOS) Trying with different IP addresses. Checking ALL THE SCREENSHOTS IN ALL LANGUAGES to ensure THERE IS NOT ANY SCREENSHOT IN UPLOAD PROCESS. Deleting all localized screenshots and using only default English-US screenshots for all localized languages. Deleting all the screenshots. Even in the case there is no screenshot at all, it prompts the same error. Here are the console logs when I click Add for Review button in Chrome Browser:
1
0
420
Aug ’22
Reply to Safari 14 - Cookies are not sent for XHR requests on a subdomain
Hate this inconsistent functionality with Safari. Doesn't happen on iPadOS Safari, either. Been roughly a year here and good solution or informative yet. What's worse is, for me, this is resulting in a redirect loop at the network level and unfortunately Safari's DevTools interface doesn't even show basic HTTP requests that are pure 301 redirects. This would at least help me confirm that my issue is relating to cookies since then I could see the actual HTTP headers.
Topic: Safari & Web SubTopic: General Tags:
Aug ’22
Cookies not visible in WKWebView on iOS 16 Simulators
We are injecting cookies using a nonPersistent() data store before creating the WKWebView (on completion). This works fine on prior versions (and I know Xcode 14 is in beta) but is no longer working in Xcode 14 / iOS 16 simulators and I see no posts, bugs raised or release notes for this so I'm raising it here to see if anyone else is experiencing this? I can see that the cookies are present in the WKHTTPCookieStore accessed via webView.configuration.websiteDataStore.httpCookieStore.getAllCookies. But both Safari debugging and our JS code embedded on the site can see no cookies.
3
0
2.4k
Aug ’22
The problem of sharing cookies between ios14 embedded browser and external browser
We encountered a problem in the development of ios14 and have not been able to solve it We expect to open the embedded browser in the APP through the embedded browser SFSafariViewController or SFAuthenticationSession, ASWebAuthenticationSession. Set the cookie in the webpage of the embedded browser. The webpage setting the cookie is complete. The APP launches the safari browser. In safari, you can get the cookie to manipulate the cookie value. iOS14 allows chrome to be set as the default browser, the app cannot retrieve the cookies in the above operations after launching chrome, and cannot perform cookie-related operations. If safari is used as the default browser, you can get cookies and perform normal operations on cookies. Would like to consult. How does iOS development determine whether the default browser of the ios14 system is chrome or safari How does iOS development realize that the cookie value set by the embedd
2
0
2.6k
Aug ’22
Reply to Safari keeps logging me out of any logged in web site after a short period. Have to constantly re-login.
@fpappledeveloper - I was able to resolve the issue and you are correct. When you open the web inspector it immediately resets logins (cookies?). I resolved the issue. Here's what I tried, sorry I didn't pin down exactly what fixed it: Resetting all experiments: Develop -> Experimental Features -> Reset all to defaults Re-enabling Safari -> Preferences -> Privacy -> enable Prevent cross site tracking + enable Allow privacy-preserving measurements of ad effectiveness (I suspect this is the issue but not sure) Disabling all content blockers on various websites (i don't think this does anything) Disabling Syncing Platform Authenticator Updating macOS from 12.4 to 12.5
Topic: App & System Services SubTopic: Core OS Tags:
Aug ’22
Reply to Accessing Developer Forums on Google Chrome?
I have been encountering this issue on Chrome on developer.apple.com and discussions.apple.com for at least a year. True to form, opening up the Developer Tools > Network, the request header was sending a massive amount of cookie data. I cleared only cookies from *.apple.com and was able to access the website again. Only apple.com can set and receive apple.com cookies, right?
Aug ’22
Reply to TestFlight - I Can't Submit to Beta, Nor Edit Test Info, Add External Users, Properly Complete Export Compliance
The issue appears to be resolved. The following may just be a coincidence, but I'll describe what I did before it started working. I have two developer accounts on my employer's team account. One account for my company email and one for my personal email Apple ID. Again, might just be a coincidence, but I tried signing out of my company email account and signing into App Store Connect->TestFlight with my personal Apple ID. At which point, I had access to update the test information and add external testers! I then signed out of my personal account and signed back into App Store Connect with my default company email account. And I had access to update the test info and add external tester groups as well. Before I tried all this signing in-out stuff, I had already confirmed this morning that I was still seeing the issue. Either Apple fixed this issue later today or [queue magical thinking now:] I was hitting some sort of caching/cookies conflict or something? So if you're still seeing this issue and
Aug ’22
Safari Extension: Please make sure your manifest.json file contains valid syntax
This is my manifest.json file for my safari extension that I've just developed: { manifest_version: 2, default_locale: en, name: BeTimeful, description: Never regret going to social media or YouTube again!, version: 1.0, icons: { 48: images/icon-48.png, 64: images/icon-64.png, 96: images/icon-96.png, 128: images/icon-128.png, 256: images/icon-256.png, 512: images/icon-512.png }, web_accessible_resources: [images/*, *], browser_action: { default_popup: popup/index.html, default_title: Betimeful, default_icon: { 16: images/toolbar-icon-16.png, 19: images/toolbar-icon-19.png, 32: images/toolbar-icon-32.png, 38: images/toolbar-icon-38.png, } }, background: { scripts: [Libraries/jquery.js,Libraries/raygun.min.js, js/background.js], persistent: true }, content_scripts: [ { matches: [ *://www.betimeful.com/cancel, *://www.betimeful.com/success ], js: [js/success.js] }, { matches: [*://calendar.google.com/*, http://blank.org/*], js: [ Libraries/jquery.js, Libraries/party.min.js, Libraries/popper.min.js, Libraries/boo
3
0
4.4k
Aug ’22
Reply to Cookies not visible in WKWebView on iOS 16 Simulators
This is broken for wildcard cookie injection. Definitely an issue with iOS 16 and I see no release notes or documentation that covers it. Specifically injecting a cookie on a site such as sub.example.com with the domain .example.com used to work but no longer does and this contradicts the Apple documentation: https://developer.apple.com/documentation/foundation/httpcookie/1393015-domain If the domain does not start with a dot, then the cookie is only sent to the exact host specified by the domain. If the domain does start with a dot, then the cookie is sent to other hosts in that domain as well, subject to certain restrictions. See RFC 6265 for more detail. Injecting with sub.example.com works as expected. Injecting with example.com does not work.
Topic: App & System Services SubTopic: Core OS Tags:
Aug ’22