Search results for

ASWebAuthenticationSession cookie

1,295 results found

Post

Replies

Boosts

Views

Activity

Reply to ASWebAuthenticationSession not working in Preview
Hi, Sorry to hear you are having problems getting previews working with ASWebAuthenticationSession. This sounds like an infrastructure issue in how previews interacts with the rest of the operating system. The best next step will be to file a feedback with diagnostics so we can take a look. Install the logging profile using instructions available here: https://developer.apple.com/bug-reporting/profiles-and-logs/?name=swift On your mac running Xcode, and on your physical preview device (if you are using one). Install the logging profile using the following instructions on your mac running Xcode; and if you are using one, your physical preview device (iOS or visionOS): https://developer.apple.com/bug-reporting/profiles-and-logs/?name=swift Then when you reproduce the problem in Xcode: Either (a) an error banner will appear, click the Diagnostics button in that banner; or (b) if you're not seeing an error but you still want to provide diagnostics you can get the same diagnostics window by going under th
Dec ’24
Unknown error -12881 when using AVAssetResourceLoader
Here we are focusing to change the cookie at every 120 seconds while playing , in apple avplayer we can't modify cookie after initialisation due to that we followed the approach to using Resource loader delegate to pass cookie as a header value . What I notice is that the playlist file (.m3u8) gets downloaded correctly. Then video file (.m4a) some chunks also gets downloaded. I know that the .ts file is downloaded because I can see the GET request completing on the web server with status 200. I also set a breakpoint at the following line: loadingRequest.dataRequest?.respond(with: data) immediately got error from avplayer status as The operation could not be completed. An unknown error occurred (-12881) From core media Need confirmation on why I am unable to load HLS using resource loader. is it possible to update cookie value while paying continuously on avplayer. override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after loading the view. let urlS
0
0
524
Dec ’24
ASWebAuthenticationSession not working in Preview
class ViewModel : NSObject, ObservableObject, ASWebAuthenticationPresentationContextProviding { private var authSession: ASWebAuthenticationSession? func signInWithOpenID(provider: OAuthProvider) { let url = getOIDCAuthenticationURL(provider: provider) authSession?.cancel() authSession = nil authSession = ASWebAuthenticationSession(url: url, callbackURLScheme: com.ninjanutri) { callbackURL, error in if let error = error { print(Error: (error.localizedDescription)) return } guard let callbackURL = callbackURL else { return } guard let idToken = callbackURL.valueOf(id_token) else { return } self.signInWithIdToken(provider: provider, idToken: idToken) } authSession?.prefersEphemeralWebBrowserSession = false authSession?.presentationContextProvider = self authSession?.start() } public func presentationAnchor(for session: ASWebAuthenticationSession) -> ASPresentationAnchor { return ASPresentationAnchor() } } struct ContentView: View { @StateObject private var viewModel = ViewModel() v
1
0
460
Dec ’24
XSRF-TOKEN can not be set in Safari 17.0 over IPv6
Hi, When we using Safari on MacOS with IPv6 we found that the XSRF-TOKEN can be set into the cookies. We have set-cookie in the authentication response headers 'Set-Cookie: XSRF-TOKEN=*******; SameSite=Strict; Secure'. It works by using Safari with IPv4. And also works with Chrome/FireFox with IPv4/IPv6. And also worked with Safari 15.6.1 over IPv6. May I know if this an issue or by design? Anyone aware of this? Thanks.
0
0
373
Dec ’24
Issues with Apple Developer Account and Revoked Certificates
Hello, I am experiencing a critical issue with my Apple Developer Program account. I successfully enrolled months ago, and my subscription is active as per my account details. However, I am now unable to access my developer membership features, and when I sign into my account it redirects me to the enrollment page as if I had never enrolled. Key details of the issue: Active subscription: My Apple Developer Program membership is active and set to renew on 17 October 2025. The subscription page confirms this, and the payment was successfully processed. REVOKED CERTIFICATES: Certificates I created weeks ago have been revoked without any explanation or notification. No email notifications: I have not received any communication from Apple regarding issues with my account or certificates. Attempts to Resolve: Cleared cookies and cache. Tried logging in on multiple devices and browsers. Signed out of all devices and logged back in. Could someone please assist me in understanding why my account is behaving t
3
0
635
Dec ’24
Removing Cookie HTTP Header via declarativeNetRequest
I'm porting to Safari a Chrome/Firefox Extension that makes use of declarativeNetRequest.updateDynamicRules to remove some HTTP headers from requests to a specific URL. This works mostly fine, except for some headers for which this is not allowed by WebKit, such as the Priority header (which is however served by Safari). An annoying corner-case I found is that of the Cookie header. When trying to remove it from the request by adding the following rule { id: , priority: , action: { type: modifyHeaders, requestHeaders: [{ header: Cookie, operation: remove }] }, condition: { urlFilter: , resourceTypes: [main_frame, sub_frame] } } nothing error is thrown, yet the Cookie header is still being sent. This rule however works for other headers, such as Referer. Changing Cookie for cookie does not help. Questions: Is there an alternative way of removing the Cookie header from the HTTP request? Is this just a bug in WebKit? Is there any way of removing unsupported he
0
0
507
Dec ’24
How does the Reddit app detect Safari’s Private Browsing mode when opening a Universal Link?
I’m trying to understand how the Reddit app knows to open in its anonymous mode when a link is opened from Safari’s Private Browsing mode. Does Safari explicitly pass any flag or metadata indicating the request originated from Private Browsing? Or is it inferred by the absence of shared cookies, session tokens, or other stateful data? If the detection is based on the absence of cookies, could this logic misidentify other stateless scenarios as ‘private’?
1
0
572
Dec ’24
Reply to Instagram login using ASWebAuthenticationSession
Error code 2 here is ASWebAuthenticationSessionErrorCode.PresentationContextNotProvided, because you're not setting the presentationContextProvider on your ASWebAuthenticationSession instance. This method tells the system which window of your app to lay out relative to. Since you're in SwiftUI, there's a separate SwiftUI version of this API which handles the presentation context for you. Also, starting in iOS 17.4, ASWebAuthenticationSession now supports callbacks using https URLs, in addition to custom schemes. Using https callbacks requires you to set up Associated Domains with your callback URL. Putting those two things together would look something like @Environment(.webAuthenticationSession) private var webAuthenticationSession func startInstagramLogin() { ... let callbackURL = try await webAuthenticationSession.authenticate(using: authURL, callback: .https(host: mysite.com, path: /myAuthEndpoint)) ... }
Topic: Privacy & Security SubTopic: General Tags:
Dec ’24
How to update data in a DataFrame
My project loads a CSV into a DataFrame and displays it in a Table (a MacOS app). So far so good ... but when trying to update a value in a column, I dont see anyway to update this value. The table gets the value for the column like this: func getColumnValue(row :DataFrame.Rows.Element, columnName :String) -> String { if row.base.containsColumn(columnName) { var value = if row[columnName] != nil { value = (row[columnName]!) } return value } ... But the documentation and googles dont show any way to update the same column. Any help is appreciated with cookies. Attempt to update: func setColumnValue(row :DataFrame.Rows.Element, columnName :String, value :String) { var column: [String?] = data[columnName] column[row.id] = value ... }
6
0
658
Nov ’24
ASWebAuthenticationSession + https iOS <17.4
Hi everyone, I am trying to use ASWebAuthenticationSession to authorize user using OAuth2. Service Webcredentials is set. /.well-known/apple-app-site-association file is set. When using API for iOS > 17.4 using new init with callback: .https(...) everything works as expected, however i cannot make .init(url: ,callbackURLScheme: ....) to work. How can i intercept callback using iOS <17.4? Do I really need to use universal links? callbackURL = https://mydomain.com/auth/callback
1
0
411
Nov ’24
Trends in App Store Connect--Swirling Circle
Using a Chrome browser in Windows, for several weeks (months?) now when I go to the Trends tab in App Store Connect (https://appstoreconnect.apple.com/trends/insights?pageid=8), the page loads, but the top two charts don't show up with current sales (units). Instead there is a swirling circle that doesn't resolve. I've deleted cookies and refreshed (F5) multiple times. The results are the same. Edge does the same thing. Anyone else?
1
0
277
Nov ’24