Search results for

ASWebAuthenticationSession cookie

1,295 results found

Post

Replies

Boosts

Views

Activity

Safari cookies not persisting
I've noticed that in Safari on OSX 10.14 beta (18A314h) that Safari isn't persisting cookies from any site.Anyone else seen that issue and anything that I can do to fix it? I've tried turning on block all cookies (which clears cookies) and this hasn't changed behaviour.Privacy Settings are: https://www.dropbox.com/s/tf92dzn6598qjae/Screenshot%202018-06-28%2022.15.15.png?dl=0Just before I file a bug report on this I thought I'd check if anyone else has seen it...Iain
1
0
2.4k
Jun ’18
iOS 11.4 Always getting NSURLErrorDomain Code=-1005 "The network connection was lost."
Hi Team, I am using iOS 11.4 and hitting web service call but i am always getting status code 1005 when I lunch app first time. Here is my steps to reporduce the bug.Note: I ahve added. setenv(CFNETWORK_DIAGNOSTICS, 3, 1); this line into main.m file1. Launch the app2. Provide UserName and Password for login into the app3. After Receiving successful authentication hitting another api and mean while getting current location as well.4. Location popup is coming and We choose Don't Allow and user is redicted to Settings screen to enable the current location allow and comming back to app and we are getting following error logs:NSURLConnection finished with error - code -1005-[NetworkManager connection:didFailWithError:] [Line 171] connection didFailWithError.. error code -1005 -- Error Domain=NSURLErrorDomain Code=-1005 The network connection was lost. UserInfo={NSUnderlyingError=0x1c005c5c0 {Error Domain=kCFErrorDomainCFNetwork Code=-1005 The network connection was lost. UserInfo={NSErrorFailingURLStringKey=https:
1
0
5.2k
Jul ’18
Authentication manner on HLS-AES128 key server (when client is HTML5 video tag)
Hi, I am trying to configure AES128 encryption for mobile safari and WowzaStreamingEngine(WSE).I verified that the encryption setting of WSE is OK over MAC chrome.I hope someone help me about the manner/way of user authentication on web server which check validity of client and provide key for the valid client (I call this server as key server for short).For PC browser where hls.js can be used as player, we can add custom header/cookie to http request from video tag to the key server via API of hls.js.Thus we can differentiate valid user and other on key server.But for mobile safari, I need to use HTML5 video tag as video player (because hls.js do not work on it).It seems there is no way to add any custom header/cookie to http request from video tag to the key server.So I am stumped how to differentiate valid user and other on key server when client is HTML5 video tag.I wonder if there is standard way/manner to differentiate valid user on key server when client is HTML5 video tag.Please help
0
0
2.7k
Jul ’18
Reply to contentsof:url loads content of truncated URL
First of all, DO NOT USE String.init(contentsOf:) or String.init(contentsOfFile:) for resources on external network.It's a blocking (synchronous) method and the execution of the thread is blocked until whole response reaches to the device. So, unless you know very well how to execute it in non-UI thread, you should never use it.Using synchronous method in the UI thread can be a risk for your app to be rejected.Use URLSession instead. You may not be accustomed to asynchronous methods, but you need to if you want to write an app accessing network resources.This code has shown exactly the same HTML text as I put the URL into my Safari. let url = URL(string: _____//www.amazon.com/gp/aw/d/B00BECJ4R8/ref=mp_s_a_1_1?ie=UTF8&qid=1531620716&sr=8-1-spons&pi=AC_SX236_SY340_QL65&keywords=cole+haan&psc=1)! let task = URLSession.shared.dataTask(with: url) { data, response, error in guard error == nil else { print(error!) return } guard let data = data else { print(data is nil) return } guard let text =
Jul ’18
Reply to iOS 11.3: WKWebView cookie synchronizing stopped working
Thanks for your input!We also solved our problem by calling the websiteDataStore before creating the webview, seems like the commit you are talking about might be the problem.We have kind of the same flow, as mentioned in the main post:1. (native) login with URLSession1,5: Hack: call websiteDataStore2. transfer cookies from HTTPStorage to WKWebView3. navigate to URL in WKWebview that requires a cookie setIf we don't do step 1,5, the cookies for the WKWebView in the decidePolicyFor delegation method is wrongif #available(iOS 11.3, *) { let _ = WKWebViewConfiguration().websiteDataStore }Saw the ticked you made @hshamanskygot an update a few days ago. We have teste with the latest version of iOS 12 (beta 4) - seems like the issue is still there.Any updates on your finds @eskimo?The sad part for us, is that it seems like this will fix the issue 99% of the times. It's hard to tell when it fails, and we can't reproduce it, it just fails now and then.
Topic: Safari & Web SubTopic: General Tags:
Jul ’18
Safari and 3rd party cookies
We have an issue with our safari extension and 3rd party cookies. Our extension injects some UI elements to website A and allow our users add items from website A to shopping cart on our website B.Our website B use cookies for authorization and in this case safari block all cookies, so when we do ajax post requests from A to B, request cookies are empty and website B can't recognize which user did request.We tried to set cookies for 24h - it doesn't help. We tried to call popup window with login function in website A from website B - result is same.Please discribe how to change our code logic to get all things work.Maybe we should use localStorage or something?
1
0
1.2k
Aug ’18
Unarchiving data without secure encoding with new NSKeyedUnarchiver APIs
I'm trying to replace my method calls to NSKeyedArchiver and NSKeyedUnarchiver that were recently deprecated in the most recent iOS SDK. I'm trying to implement these calls on an object that conforms to the NSCoding protocol, not the NSSecureCoding protocol.I managed to replace calls to +[NSKeyedArchiver archivedDataWithRootObject:] with calls to +[NSKeyedArchiver archivedDataWithRootObject:requiringSecureCoding:error:], passing false for requiringSecureCoding and verified that my object is successfully encoding.However, when I attempted to replace calls to +[NSKeyedUnarchiver unarchiveObjectWithData:] with calls to +[NSKeyedUnarchiver unarchivedObjectOfClasses:fromData:error:], there was no error and the call returned nil. What I found especially odd was that I couldn't trigger the object's implemention of the - (void) encodeWithCoder:(NSCoder *) aCoder method from the NSCoding protocol; the log statement I placed there wasn't triggered.Here's my call to 'unarchivedObjectOfClasses:fromData:error:':[NSKeyedUn
15
0
19k
Aug ’18
Reply to Setting cookies with WKHTTPCookieStorage do not sync with wkwebview
I found this solution as well by looking at the WWDC session. However, I shortly thereafter discovered that using a non-persistent WKWebsiteDataStore had other problems. The website I'm integrating was using Web Storage. It appears that if using a non-persistent store, data stored in Window.sessionStorage or Window.localStorage will not be retained over a page refresh. Thus I'm back to square one. If anyone has any idea on how to reliably set cookies even on the default store, I'd be happy to hear.
Aug ’18
Reply to Unarchiving data without secure encoding with new NSKeyedUnarchiver APIs
I have since tried to instantiate and decode my data manually with various permutations of NSKeyedUnarchiver methods, but I keep running into issues. Here's one of the ways I rewrote the call to +[NSKeyedUnarchiver unarchiveObjectWithData:]:NSKeyedUnarchiver *unarchiver = [[NSKeyedUnarchiver alloc] initForReadingWithData:data]; [unarchiver setRequiresSecureCoding:NO]; cookies = [[Cookies alloc] initWithCoder:unarchiver];Here's the initWithCoder: method from my Cookies class:- (id)initWithCoder:(NSCoder *)coder { if (self = [super init]) { _version = [coder decodeObjectForKey:keychainVersion]; _cAccount = [coder decodeObjectForKey:currentAccount]; _pAccount = [coder decodeObjectForKey:primaryAccount]; _dict = [coder decodeObjectForKey:dictionary]; _shouldHaveFirstRunToken = [coder decodeBoolForKey:shouldHaveFirstRunToken]; } return self; }I traced this method call with my debugger, and I found that my call to initWithCoder returns an empty Cookies object. That is, all the ca
Topic: Programming Languages SubTopic: General Tags:
Aug ’18