Search results for

file uri scheme

78,492 results found

Post

Replies

Boosts

Views

Activity

Security and Your Apps notes
Network securityHTTPS, TLSIn 2015, TLS is a minimum baselineMany servers default to TLSv1.0, from 1999Newest version is TLSv1.2TLSv1.2 is not enough. Compromise of a server key lets you decrypt all TLS traffic that was encrypted in the past.With forward secrecy, a server key compromise will only let you read future traffic. Past traffic will not be able to be decrypted.By default, apps linked against iOS 9 and OS X 10.11 cannot make unprotected HTTP connections.TLS connections will need to comply with best practices- Exceptions can be declared on a case-by-case basis in your app's Info.plist file.System Integrity ProtectionDefense in DepthSecurity is about layersOne layer failing shouldn't defeat all securityRely on multiple layers of protectionDelay the attackerReduce your attack surfaceSeque into talking about Vauban and star fortresses. History lesson FTW.OS X's star fortress security model:Outermost line - Developer ID and GatekeeperSecond layer - Sandbox - attacker only gets access to the data which the
0
0
3.1k
Jun ’15
In-App Purchase Receipt in wrong format
HiI'm validating my receipts against the appstore, following the Apple's guide The receipt is retrieved from the bundle using the following code:NSURL *receiptURL = [[NSBundle mainBundle] appStoreReceiptURL];NSData *receipt = [NSData dataWithContentsOfURL:receiptURL];NSString *base64Receipt = [receipt base64EncodedStringWithOptions:0];The encoded receipt is a signed binary file, as described in the documentation. However, in some weird cases the receipt is not the expected binary file but an NSDictionary with the form{ pod = 50; purchase-info = ewo...; signature = Apdx...; signing-status = 0;}When I try to validate those receipts against the appstore, the result is always 21002 (The data in the receipt-data property was malformed or missing). Any ideas in why the receipt retrieved from the bundle is in the wrong format?Regards
5
0
5.5k
Jun ’15
Unable to run updated WatchKit app in Xcode 7's simulator
I've updated the app for watchOS 2 using the built in suggestion with Xcode 7 when you first build it. I've changed all the necessary code so there's no errors or warnings but I can't seem to run either the containing app or the watch app in the simulator; they never launch but they do copy over to the simulators.Is there a new scheme I should be using? I'm using the previous scheme for the main watch app which now automatically lets you choose between running the iPhone 6 simulator with either the 38mm or 42mm watch simulator.
5
0
1.2k
Jun ’15
Reply to iOS 9 Error 14
Never underestimate a bad cable as the possible reason. For some reason, since the beginning of iPhone, you can have a cable that's good enough to get through charging and sometimes syncing, but fails when doing restores and more sensitive tasks. A few tips:Make sure your device registered with the developer program's UDIDs.Make sure iTunes is up to date.Make sure your hosts file on your computer hasn't been modded.Ensure there's no dust or debris in the bottom of your device that may be blocking a solid connection.Try a different cable.Try a different computerAnd if all else fails, the apple store will usually try restoring it for you, even if it's OoW -- though if they also can't restore it, you may be looking at an Out of Warranty service repair.https://support.apple.com/en-us/HT204770Check your USB connectionsErrors: 13, 14, 1600, 1601, 1602, 1603, 1604, 1611, 1643-1650, 2000, 2001, 2002, 2005, 2006, 2009, 4005, 4013, 4014. You might also see a message that includes invalid response.If the USB co
Topic: App & System Services SubTopic: Core OS Tags:
Jun ’15
Reply to Loading an .Obj model file
Maybe a problem with the file? I created a Torus in Blender and exported it as a triangulated obj file. Seemed to load fine.Code:let urlForAsset = NSBundle.mainBundle().URLForResource(Torus, withExtension: obj)! let boxAsset = MDLAsset(URL: urlForAsset)Console:2015-06-09 17:53:06.669 MetalX[1406:75348] Creating vertex buffer for 3456 vertices 2015-06-09 17:53:06.669 MetalX[1406:75348] Adding 2 submeshesI'm tried this on OSX
Topic: Graphics & Games SubTopic: SceneKit Tags:
Jun ’15
Reply to Loading an .Obj model file
when I ran your code I saw the actual problem 🙂when creating the URL I needed to specifically create a file URL.//var torusModel = MDLAsset(URL: NSURL(string: path!)!) let torusModel = MDLAsset(URL: NSURL.fileURLWithPath(path!))Loaded just fine after that
Topic: Graphics & Games SubTopic: SceneKit Tags:
Jun ’15
Swift frameworks and unmapped SDK libraries?
Over the course of Swift's existence I've had to take advantage of a number of workarounds (i.e., hacks) to compile a Swift framework that utilizes non-modular system code, e.g., CommonCrypto, sqlite3, etc.These solutions have included:Renaming the umbrella header to be something different than the module name in order to exploit a bug that let frameworks compile with bridging headers, wherein the non-modular import happened: #import <CommonCrypto/CommonCrypto.h>Building a dummy, optional framework with a custom module map specifying the absolute path to an SDK header (relative SDK paths don't work): module CommonCrypto [system] [extern_c] { header /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/usr/include/CommonCrypto/CommonCrypto.h export * }Specifying a custom module map with an additional header specifying the absolute path to an SDK header: framework module MyCrypto { umbrella header MyCrypto.h header /Applications/Xcode.app/Contents/Developer/Pla
7
0
9.7k
Jun ’15
Reply to Is it possible to run Xcode 7 UI Tests from command line?
Yes, with something like this ...xcodebuild test -scheme YourAppScheme -destination platform=iOS Simulator,OS=9.0,name=iPhone 6Replace your project's scheme name in for 'YourAppScheme'Used to be you had to export/share the scheme (go to manage schemes in Xcode) to get this to work. Not sure if that is still the case. Just a warning.You can play with the destination settings to pick different devices, etc.Cheers.
Topic: App & System Services SubTopic: Core OS Tags:
Jun ’15
Reply to Invalid conversion with do-try-catch in a block
Adding a catch-all catch will let things compile:moc.performBlock { do { try moc.save() print(Success) } catch let error as NSError { print(Fail: (error.localizedDescription)) } catch { print(Fail: (error)) } }If you're not using the NSError, you may as well use just a single, generic catch.If you don't catch all possible errors, the throws propagates to the caller, in this case, performBlock. However, performBlock doesn't expect an error, so you must catch all possible errors, or you must call try!, unsafely, instead.The error isn't super friendly, so it may be worth filing a bug report to make it easier to understand.
Topic: Programming Languages SubTopic: Swift Tags:
Jun ’15
Revert to Saved error messages
I am working on an App where after the user completes the Revert to Saved… time machine like dialog the system sends a bunch of error messages to the XCode console:Jun 9 20:16:52 BDM-2.local Mandelbrot[36183] <Error>: CGContextClipToRects: invalid context 0x0. This is a serious error. This application, or a library it uses, is using an invalid context and is thereby contributing to an overall degradation of system stability and reliability. This notice is a courtesy: please fix this problem. It will become a fatal error in an upcoming update.Jun 9 20:16:52 BDM-2.local Mandelbrot[36183] <Error>: CGContextSetFillColorWithColor: invalid context 0x0. This is a serious error. This application, or a library it uses, is using an invalid context and is thereby contributing to an overall degradation of system stability and reliability. This notice is a courtesy: please fix this problem. It will become a fatal error in an upcoming update....None of these graphics commands are part of my code. The document w
Topic: UI Frameworks SubTopic: AppKit Tags:
0
0
246
Jun ’15