diff --git a/Podfile b/Podfile index 0e125a3..a4a0c03 100644 --- a/Podfile +++ b/Podfile @@ -6,7 +6,7 @@ target 'ShadowsocksX-NG' do use_frameworks! # Pods for ShadowsocksX-NG - pod 'Alamofire', '~> 3.4' + pod 'Alamofire', '~> 3.5' pod 'GCDWebServer', '~> 3.0' target 'ShadowsocksX-NGTests' do diff --git a/Podfile.lock b/Podfile.lock index c3a331c..33ab6b9 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -1,20 +1,20 @@ PODS: - - Alamofire (3.4.0) + - Alamofire (3.5.0) - BRLOptionParser (0.3.1) - GCDWebServer (3.3.3): - GCDWebServer/Core (= 3.3.3) - GCDWebServer/Core (3.3.3) DEPENDENCIES: - - Alamofire (~> 3.4) + - Alamofire (~> 3.5) - BRLOptionParser (~> 0.3.1) - GCDWebServer (~> 3.0) SPEC CHECKSUMS: - Alamofire: c19a627cefd6a95f840401c49ab1f124e07f54ee + Alamofire: b70a7352335f8ea5babd0a923eb7e8eacc67b877 BRLOptionParser: a03256a8ff003ca1f5376c55f55f210e085a3958 GCDWebServer: 1c39a1f0763e4eb492bee021e4270fce097d3555 -PODFILE CHECKSUM: 1c9b3b36679167f8e54cc2369d7d1a22d8446883 +PODFILE CHECKSUM: c8b8f02e60b644ad152c38e879174addd695404c -COCOAPODS: 1.0.1 +COCOAPODS: 1.1.0.rc.2 diff --git a/Pods/Alamofire/README.md b/Pods/Alamofire/README.md index 68e54e9..e72f038 100644 --- a/Pods/Alamofire/README.md +++ b/Pods/Alamofire/README.md @@ -1,6 +1,6 @@ ![Alamofire: Elegant Networking in Swift](https://raw.githubusercontent.com/Alamofire/Alamofire/assets/alamofire.png) -[![Build Status](https://travis-ci.org/Alamofire/Alamofire.svg)](https://travis-ci.org/Alamofire/Alamofire) +[![Build Status](https://travis-ci.org/Alamofire/Alamofire.svg?branch=master)](https://travis-ci.org/Alamofire/Alamofire) [![CocoaPods Compatible](https://img.shields.io/cocoapods/v/Alamofire.svg)](https://img.shields.io/cocoapods/v/Alamofire.svg) [![Carthage Compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage) [![Platform](https://img.shields.io/cocoapods/p/Alamofire.svg?style=flat)](http://cocoadocs.org/docsets/Alamofire) @@ -32,7 +32,8 @@ In order to keep Alamofire focused specifically on core networking implementatio ## Requirements - iOS 8.0+ / Mac OS X 10.9+ / tvOS 9.0+ / watchOS 2.0+ -- Xcode 7.3+ +- Xcode 8.0+ +- Swift 2.2 or 2.3 ## Migration Guides @@ -67,10 +68,12 @@ To integrate Alamofire into your Xcode project using CocoaPods, specify it in yo ```ruby source 'https://github.com/CocoaPods/Specs.git' -platform :ios, '9.0' +platform :ios, '10.0' use_frameworks! -pod 'Alamofire', '~> 3.4' +target '' do + pod 'Alamofire', '~> 3.5' +end ``` Then, run the following command: @@ -93,7 +96,7 @@ $ brew install carthage To integrate Alamofire into your Xcode project using Carthage, specify it in your `Cartfile`: ```ogdl -github "Alamofire/Alamofire" ~> 3.4 +github "Alamofire/Alamofire" ~> 3.5 ``` Run `carthage update` to build the framework and drag the built `Alamofire.framework` into your Xcode project. @@ -385,6 +388,14 @@ Alamofire.request(.GET, "https://httpbin.org/get", headers: headers) } ``` +The default Alamofire `Manager` provides a common set of headers for every request. These include: + +* `Accept-Encoding`, which defaults to `gzip;q=1.0, compress;q=0.5`, per [RFC7230](https://tools.ietf.org/html/rfc7230#section-4.2.3). +* `Accept-Language`, which defaults to up to the top 6 preferred languages on the system, formatted like `en;q=1.0`, per [RFC7231](https://tools.ietf.org/html/rfc7231#section-5.3.5). +* `User-Agent`, which contains versioning information about the current app. For example: `iOS Example/1.0 (com.alamofire.iOS-Example; build:1; iOS 9.3.0) Alamofire/3.4.2`, per [RFC7231](https://tools.ietf.org/html/rfc7231#section-5.5.3). + +Customizing these headers, since they need to be added to every request, should be done by creating a customized `Manager` instance and modifying the `defaultHTTPHeaders` dictionary, as shown in the [Modifying Session Configuration](#modifying-session-configuration) section. + ### Caching Caching is handled on the system framework level by [`NSURLCache`](https://developer.apple.com/library/mac/documentation/Cocoa/Reference/Foundation/Classes/NSURLCache_Class/Reference/Reference.html#//apple_ref/occ/cl/NSURLCache). @@ -711,6 +722,20 @@ Requests can be suspended, resumed, and cancelled: ### Response Serialization +#### Handling Errors + +Before implementing custom response serializers or object serialization methods, it's important to be prepared to handle any errors that may occur. Alamofire recommends handling these through the use of either your own `NSError` creation methods, or a simple `enum` that conforms to `ErrorType`. For example, this `BackendError` type, which will be used in later examples: + +```swift +public enum BackendError: ErrorType { + case Network(error: NSError) + case DataSerialization(reason: String) + case JSONSerialization(error: NSError) + case ObjectSerialization(reason: String) + case XMLSerialization(error: NSError) +} +``` + #### Creating a Custom Response Serializer Alamofire provides built-in response serialization for strings, JSON, and property lists, but others can be added in extensions on `Alamofire.Request`. @@ -719,26 +744,24 @@ For example, here's how a response handler using [Ono](https://github.com/mattt/ ```swift extension Request { - public static func XMLResponseSerializer() -> ResponseSerializer { + public static func XMLResponseSerializer() -> ResponseSerializer { return ResponseSerializer { request, response, data, error in - guard error == nil else { return .Failure(error!) } + guard error == nil else { return .Failure(.Network(error: error!)) } guard let validData = data else { - let failureReason = "Data could not be serialized. Input data was nil." - let error = Error.errorWithCode(.DataSerializationFailed, failureReason: failureReason) - return .Failure(error) + return .Failure(.DataSerialization(reason: "Data could not be serialized. Input data was nil.")) } do { let XML = try ONOXMLDocument(data: validData) return .Success(XML) } catch { - return .Failure(error as NSError) + return .Failure(.XMLSerialization(error: error as NSError)) } } } - public func responseXMLDocument(completionHandler: Response -> Void) -> Self { + public func responseXMLDocument(completionHandler: Response -> Void) -> Self { return response(responseSerializer: Request.XMLResponseSerializer(), completionHandler: completionHandler) } } @@ -754,9 +777,9 @@ public protocol ResponseObjectSerializable { } extension Request { - public func responseObject(completionHandler: Response -> Void) -> Self { - let responseSerializer = ResponseSerializer { request, response, data, error in - guard error == nil else { return .Failure(error!) } + public func responseObject(completionHandler: Response -> Void) -> Self { + let responseSerializer = ResponseSerializer { request, response, data, error in + guard error == nil else { return .Failure(.Network(error: error!)) } let JSONResponseSerializer = Request.JSONResponseSerializer(options: .AllowFragments) let result = JSONResponseSerializer.serializeResponse(request, response, data, error) @@ -769,12 +792,10 @@ extension Request { { return .Success(responseObject) } else { - let failureReason = "JSON could not be serialized into response object: \(value)" - let error = Error.errorWithCode(.JSONSerializationFailed, failureReason: failureReason) - return .Failure(error) + return .Failure(.ObjectSerialization(reason: "JSON could not be serialized into response object: \(value)")) } case .Failure(let error): - return .Failure(error) + return .Failure(.JSONSerialization(error: error)) } } @@ -797,7 +818,7 @@ final class User: ResponseObjectSerializable { ```swift Alamofire.request(.GET, "https://example.com/users/mattt") - .responseObject { (response: Response) in + .responseObject { (response: Response) in debugPrint(response) } ``` @@ -809,10 +830,26 @@ public protocol ResponseCollectionSerializable { static func collection(response response: NSHTTPURLResponse, representation: AnyObject) -> [Self] } +extension ResponseCollectionSerializable where Self: ResponseObjectSerializable { + static func collection(response response: NSHTTPURLResponse, representation: AnyObject) -> [Self] { + var collection = [Self]() + + if let representation = representation as? [[String: AnyObject]] { + for itemRepresentation in representation { + if let item = Self(response: response, representation: itemRepresentation) { + collection.append(item) + } + } + } + + return collection + } +} + extension Alamofire.Request { - public func responseCollection(completionHandler: Response<[T], NSError> -> Void) -> Self { - let responseSerializer = ResponseSerializer<[T], NSError> { request, response, data, error in - guard error == nil else { return .Failure(error!) } + public func responseCollection(completionHandler: Response<[T], BackendError> -> Void) -> Self { + let responseSerializer = ResponseSerializer<[T], BackendError> { request, response, data, error in + guard error == nil else { return .Failure(.Network(error: error!)) } let JSONSerializer = Request.JSONResponseSerializer(options: .AllowFragments) let result = JSONSerializer.serializeResponse(request, response, data, error) @@ -822,12 +859,10 @@ extension Alamofire.Request { if let response = response { return .Success(T.collection(response: response, representation: value)) } else { - let failureReason = "Response collection could not be serialized due to nil response" - let error = Error.errorWithCode(.JSONSerializationFailed, failureReason: failureReason) - return .Failure(error) + return .Failure(. ObjectSerialization(reason: "Response collection could not be serialized due to nil response")) } case .Failure(let error): - return .Failure(error) + return .Failure(.JSONSerialization(error: error)) } } @@ -845,26 +880,12 @@ final class User: ResponseObjectSerializable, ResponseCollectionSerializable { self.username = response.URL!.lastPathComponent! self.name = representation.valueForKeyPath("name") as! String } - - static func collection(response response: NSHTTPURLResponse, representation: AnyObject) -> [User] { - var users: [User] = [] - - if let representation = representation as? [[String: AnyObject]] { - for userRepresentation in representation { - if let user = User(response: response, representation: userRepresentation) { - users.append(user) - } - } - } - - return users - } } ``` ```swift Alamofire.request(.GET, "http://example.com/users") - .responseCollection { (response: Response<[User], NSError>) in + .responseCollection { (response: Response<[User], BackendError>) in debugPrint(response) } ``` @@ -944,7 +965,7 @@ enum Router: URLRequestConvertible { var URLRequest: NSMutableURLRequest { let result: (path: String, parameters: [String: AnyObject]) = { switch self { - case .Search(let query, let page) where page > 1: + case .Search(let query, let page) where page > 0: return ("/search", ["q": query, "offset": Router.perPage * page]) case .Search(let query, _): return ("/search", ["q": query]) @@ -1248,6 +1269,7 @@ There are some important things to remember when using network reachability to d The following rdars have some affect on the current implementation of Alamofire. * [rdar://21349340](http://www.openradar.me/radar?id=5517037090635776) - Compiler throwing warning due to toll-free bridging issue in test case +* [rdar://26761490](http://www.openradar.me/radar?id=5010235949318144) - Swift string interpolation causing memory leak with common usage ## FAQ @@ -1265,6 +1287,20 @@ Alamofire is owned and maintained by the [Alamofire Software Foundation](http:// If you believe you have identified a security vulnerability with Alamofire, you should report it as soon as possible via email to security@alamofire.org. Please do not post it to a public issue tracker. +## Donations + +The [ASF](https://github.com/Alamofire/Foundation#members) is looking to raise money to officially register as a federal non-profit organization. Registering will allow us members to gain some legal protections and also allow us to put donations to use, tax free. Donating to the ASF will enable us to: + +* Pay our legal fees to register as a federal non-profit organization +* Pay our yearly legal fees to keep the non-profit in good status +* Pay for our mail servers to help us stay on top of all questions and security issues +* Potentially fund test servers to make it easier for us to test the edge cases +* Potentially fund developers to work on one of our projects full-time + +The community adoption of the ASF libraries has been amazing. We are greatly humbled by your enthusiam around the projects, and want to continue to do everything we can to move the needle forward. With your continued support, the ASF will be able to improve its reach and also provide better legal safety for the core members. If you use any of our libraries for work, see if your employers would be interested in donating. Our initial goal is to raise $1000 to get all our legal ducks in a row and kickstart this campaign. Any amount you can donate today to help us reach our goal would be greatly appreciated. + +Click here to lend your support to: Alamofire Software Foundation and make a donation at pledgie.com ! + ## License Alamofire is released under the MIT license. See LICENSE for details. diff --git a/Pods/Alamofire/Source/Alamofire.swift b/Pods/Alamofire/Source/Alamofire.swift index cb4b36a..0c2ec32 100644 --- a/Pods/Alamofire/Source/Alamofire.swift +++ b/Pods/Alamofire/Source/Alamofire.swift @@ -27,7 +27,7 @@ import Foundation // MARK: - URLStringConvertible /** - Types adopting the `URLStringConvertible` protocol can be used to construct URL strings, which are then used to + Types adopting the `URLStringConvertible` protocol can be used to construct URL strings, which are then used to construct URL requests. */ public protocol URLStringConvertible { @@ -44,27 +44,25 @@ public protocol URLStringConvertible { } extension String: URLStringConvertible { - public var URLString: String { - return self - } + public var URLString: String { return self } } extension NSURL: URLStringConvertible { public var URLString: String { - return absoluteString + #if swift(>=2.3) + return absoluteString! + #else + return absoluteString + #endif } } extension NSURLComponents: URLStringConvertible { - public var URLString: String { - return URL!.URLString - } + public var URLString: String { return URL!.URLString } } extension NSURLRequest: URLStringConvertible { - public var URLString: String { - return URL!.URLString - } + public var URLString: String { return URL!.URLString } } // MARK: - URLRequestConvertible @@ -78,9 +76,7 @@ public protocol URLRequestConvertible { } extension NSURLRequest: URLRequestConvertible { - public var URLRequest: NSMutableURLRequest { - return self.mutableCopy() as! NSMutableURLRequest - } + public var URLRequest: NSMutableURLRequest { return self.mutableCopy() as! NSMutableURLRequest } } // MARK: - Convenience @@ -91,7 +87,16 @@ func URLRequest( headers: [String: String]? = nil) -> NSMutableURLRequest { - let mutableURLRequest = NSMutableURLRequest(URL: NSURL(string: URLString.URLString)!) + let mutableURLRequest: NSMutableURLRequest + + if let request = URLString as? NSMutableURLRequest { + mutableURLRequest = request + } else if let request = URLString as? NSURLRequest { + mutableURLRequest = request.URLRequest + } else { + mutableURLRequest = NSMutableURLRequest(URL: NSURL(string: URLString.URLString)!) + } + mutableURLRequest.HTTPMethod = method.rawValue if let headers = headers { @@ -355,11 +360,11 @@ public func download(URLRequest: URLRequestConvertible, destination: Request.Dow // MARK: Resume Data /** - Creates a request using the shared manager instance for downloading from the resume data produced from a + Creates a request using the shared manager instance for downloading from the resume data produced from a previous request cancellation. - parameter resumeData: The resume data. This is an opaque data blob produced by `NSURLSessionDownloadTask` - when a task is cancelled. See `NSURLSession -downloadTaskWithResumeData:` for additional + when a task is cancelled. See `NSURLSession -downloadTaskWithResumeData:` for additional information. - parameter destination: The closure used to determine the destination of the downloaded file. diff --git a/Pods/Alamofire/Source/Download.swift b/Pods/Alamofire/Source/Download.swift index 97b146f..ed39e33 100644 --- a/Pods/Alamofire/Source/Download.swift +++ b/Pods/Alamofire/Source/Download.swift @@ -114,8 +114,8 @@ extension Manager { If `startRequestsImmediately` is `true`, the request will have `resume()` called before being returned. - - parameter resumeData: The resume data. This is an opaque data blob produced by `NSURLSessionDownloadTask` - when a task is cancelled. See `NSURLSession -downloadTaskWithResumeData:` for + - parameter resumeData: The resume data. This is an opaque data blob produced by `NSURLSessionDownloadTask` + when a task is cancelled. See `NSURLSession -downloadTaskWithResumeData:` for additional information. - parameter destination: The closure used to determine the destination of the downloaded file. @@ -130,14 +130,14 @@ extension Manager { extension Request { /** - A closure executed once a request has successfully completed in order to determine where to move the temporary - file written to during the download process. The closure takes two arguments: the temporary file URL and the URL + A closure executed once a request has successfully completed in order to determine where to move the temporary + file written to during the download process. The closure takes two arguments: the temporary file URL and the URL response, and returns a single argument: the file URL where the temporary file should be moved. */ public typealias DownloadFileDestination = (NSURL, NSHTTPURLResponse) -> NSURL /** - Creates a download file destination closure which uses the default file manager to move the temporary file to a + Creates a download file destination closure which uses the default file manager to move the temporary file to a file URL in the first available directory with the specified search path directory and search path domain mask. - parameter directory: The search path directory. `.DocumentDirectory` by default. @@ -154,7 +154,11 @@ extension Request { let directoryURLs = NSFileManager.defaultManager().URLsForDirectory(directory, inDomains: domain) if !directoryURLs.isEmpty { + #if swift(>=2.3) + return directoryURLs[0].URLByAppendingPathComponent(response.suggestedFilename!)! + #else return directoryURLs[0].URLByAppendingPathComponent(response.suggestedFilename!) + #endif } return temporaryURL @@ -220,7 +224,7 @@ extension Request { session, downloadTask, bytesWritten, - totalBytesWritten, + totalBytesWritten, totalBytesExpectedToWrite ) } else { diff --git a/Pods/Alamofire/Source/Manager.swift b/Pods/Alamofire/Source/Manager.swift index 7b5f888..8f272b6 100644 --- a/Pods/Alamofire/Source/Manager.swift +++ b/Pods/Alamofire/Source/Manager.swift @@ -32,7 +32,7 @@ public class Manager { // MARK: - Properties /** - A shared instance of `Manager`, used by top-level Alamofire request methods, and suitable for use directly + A shared instance of `Manager`, used by top-level Alamofire request methods, and suitable for use directly for any ad hoc requests. */ public static let sharedInstance: Manager = { @@ -56,19 +56,53 @@ public class Manager { }.joinWithSeparator(", ") // User-Agent Header; see https://tools.ietf.org/html/rfc7231#section-5.5.3 + // Example: `iOS Example/1.0 (com.alamofire.iOS-Example; build:1; iOS 9.3.0) Alamofire/3.4.2` let userAgent: String = { if let info = NSBundle.mainBundle().infoDictionary { let executable = info[kCFBundleExecutableKey as String] as? String ?? "Unknown" let bundle = info[kCFBundleIdentifierKey as String] as? String ?? "Unknown" - let version = info[kCFBundleVersionKey as String] as? String ?? "Unknown" - let os = NSProcessInfo.processInfo().operatingSystemVersionString + let appVersion = info["CFBundleShortVersionString"] as? String ?? "Unknown" + let appBuild = info[kCFBundleVersionKey as String] as? String ?? "Unknown" - var mutableUserAgent = NSMutableString(string: "\(executable)/\(bundle) (\(version); OS \(os))") as CFMutableString - let transform = NSString(string: "Any-Latin; Latin-ASCII; [:^ASCII:] Remove") as CFString + let osNameVersion: String = { + let versionString: String - if CFStringTransform(mutableUserAgent, UnsafeMutablePointer(nil), transform, false) { - return mutableUserAgent as String - } + if #available(OSX 10.10, *) { + let version = NSProcessInfo.processInfo().operatingSystemVersion + versionString = "\(version.majorVersion).\(version.minorVersion).\(version.patchVersion)" + } else { + versionString = "10.9" + } + + let osName: String = { + #if os(iOS) + return "iOS" + #elseif os(watchOS) + return "watchOS" + #elseif os(tvOS) + return "tvOS" + #elseif os(OSX) + return "OS X" + #elseif os(Linux) + return "Linux" + #else + return "Unknown" + #endif + }() + + return "\(osName) \(versionString)" + }() + + let alamofireVersion: String = { + guard + let afInfo = NSBundle(forClass: Manager.self).infoDictionary, + build = afInfo["CFBundleShortVersionString"] + else { return "Unknown" } + + return "Alamofire/\(build)" + }() + + return "\(executable)/\(appVersion) (\(bundle); build:\(appBuild); \(osNameVersion)) \(alamofireVersion)" } return "Alamofire" @@ -93,14 +127,14 @@ public class Manager { public var startRequestsImmediately: Bool = true /** - The background completion handler closure provided by the UIApplicationDelegate - `application:handleEventsForBackgroundURLSession:completionHandler:` method. By setting the background - completion handler, the SessionDelegate `sessionDidFinishEventsForBackgroundURLSession` closure implementation + The background completion handler closure provided by the UIApplicationDelegate + `application:handleEventsForBackgroundURLSession:completionHandler:` method. By setting the background + completion handler, the SessionDelegate `sessionDidFinishEventsForBackgroundURLSession` closure implementation will automatically call the handler. - - If you need to handle your own events before the handler is called, then you need to override the + + If you need to handle your own events before the handler is called, then you need to override the SessionDelegate `sessionDidFinishEventsForBackgroundURLSession` and manually call the handler when finished. - + `nil` by default. */ public var backgroundCompletionHandler: (() -> Void)? @@ -110,11 +144,11 @@ public class Manager { /** Initializes the `Manager` instance with the specified configuration, delegate and server trust policy. - - parameter configuration: The configuration used to construct the managed session. + - parameter configuration: The configuration used to construct the managed session. `NSURLSessionConfiguration.defaultSessionConfiguration()` by default. - parameter delegate: The delegate used when initializing the session. `SessionDelegate()` by default. - - parameter serverTrustPolicyManager: The server trust policy manager to use for evaluating all server trust + - parameter serverTrustPolicyManager: The server trust policy manager to use for evaluating all server trust challenges. `nil` by default. - returns: The new `Manager` instance. @@ -338,14 +372,14 @@ public class Manager { /// Overrides default behavior for NSURLSessionTaskDelegate method `URLSession:task:didReceiveChallenge:completionHandler:`. public var taskDidReceiveChallenge: ((NSURLSession, NSURLSessionTask, NSURLAuthenticationChallenge) -> (NSURLSessionAuthChallengeDisposition, NSURLCredential?))? - /// Overrides all behavior for NSURLSessionTaskDelegate method `URLSession:task:didReceiveChallenge:completionHandler:` and + /// Overrides all behavior for NSURLSessionTaskDelegate method `URLSession:task:didReceiveChallenge:completionHandler:` and /// requires the caller to call the `completionHandler`. public var taskDidReceiveChallengeWithCompletion: ((NSURLSession, NSURLSessionTask, NSURLAuthenticationChallenge, (NSURLSessionAuthChallengeDisposition, NSURLCredential?) -> Void) -> Void)? /// Overrides default behavior for NSURLSessionTaskDelegate method `URLSession:session:task:needNewBodyStream:`. public var taskNeedNewBodyStream: ((NSURLSession, NSURLSessionTask) -> NSInputStream?)? - /// Overrides all behavior for NSURLSessionTaskDelegate method `URLSession:session:task:needNewBodyStream:` and + /// Overrides all behavior for NSURLSessionTaskDelegate method `URLSession:session:task:needNewBodyStream:` and /// requires the caller to call the `completionHandler`. public var taskNeedNewBodyStreamWithCompletion: ((NSURLSession, NSURLSessionTask, NSInputStream? -> Void) -> Void)? @@ -364,8 +398,8 @@ public class Manager { - parameter task: The task whose request resulted in a redirect. - parameter response: An object containing the server’s response to the original request. - parameter request: A URL request object filled out with the new location. - - parameter completionHandler: A closure that your handler should call with either the value of the request - parameter, a modified URL request object, or NULL to refuse the redirect and + - parameter completionHandler: A closure that your handler should call with either the value of the request + parameter, a modified URL request object, or NULL to refuse the redirect and return the body of the redirect response. */ public func URLSession( @@ -502,7 +536,7 @@ public class Manager { /// Overrides default behavior for NSURLSessionDataDelegate method `URLSession:dataTask:didReceiveResponse:completionHandler:`. public var dataTaskDidReceiveResponse: ((NSURLSession, NSURLSessionDataTask, NSURLResponse) -> NSURLSessionResponseDisposition)? - /// Overrides all behavior for NSURLSessionDataDelegate method `URLSession:dataTask:didReceiveResponse:completionHandler:` and + /// Overrides all behavior for NSURLSessionDataDelegate method `URLSession:dataTask:didReceiveResponse:completionHandler:` and /// requires caller to call the `completionHandler`. public var dataTaskDidReceiveResponseWithCompletion: ((NSURLSession, NSURLSessionDataTask, NSURLResponse, NSURLSessionResponseDisposition -> Void) -> Void)? @@ -515,7 +549,7 @@ public class Manager { /// Overrides default behavior for NSURLSessionDataDelegate method `URLSession:dataTask:willCacheResponse:completionHandler:`. public var dataTaskWillCacheResponse: ((NSURLSession, NSURLSessionDataTask, NSCachedURLResponse) -> NSCachedURLResponse?)? - /// Overrides all behavior for NSURLSessionDataDelegate method `URLSession:dataTask:willCacheResponse:completionHandler:` and + /// Overrides all behavior for NSURLSessionDataDelegate method `URLSession:dataTask:willCacheResponse:completionHandler:` and /// requires caller to call the `completionHandler`. public var dataTaskWillCacheResponseWithCompletion: ((NSURLSession, NSURLSessionDataTask, NSCachedURLResponse, NSCachedURLResponse? -> Void) -> Void)? @@ -527,8 +561,8 @@ public class Manager { - parameter session: The session containing the data task that received an initial reply. - parameter dataTask: The data task that received an initial reply. - parameter response: A URL response object populated with headers. - - parameter completionHandler: A completion handler that your code calls to continue the transfer, passing a - constant to indicate whether the transfer should continue as a data task or + - parameter completionHandler: A completion handler that your code calls to continue the transfer, passing a + constant to indicate whether the transfer should continue as a data task or should become a download task. */ public func URLSession( @@ -591,12 +625,12 @@ public class Manager { - parameter session: The session containing the data (or upload) task. - parameter dataTask: The data (or upload) task. - - parameter proposedResponse: The default caching behavior. This behavior is determined based on the current - caching policy and the values of certain received headers, such as the Pragma + - parameter proposedResponse: The default caching behavior. This behavior is determined based on the current + caching policy and the values of certain received headers, such as the Pragma and Cache-Control headers. - - parameter completionHandler: A block that your handler must call, providing either the original proposed - response, a modified version of that response, or NULL to prevent caching the - response. If your delegate implements this method, it must call this completion + - parameter completionHandler: A block that your handler must call, providing either the original proposed + response, a modified version of that response, or NULL to prevent caching the + response. If your delegate implements this method, it must call this completion handler; otherwise, your app leaks memory. */ public func URLSession( @@ -644,8 +678,8 @@ public class Manager { - parameter session: The session containing the download task that finished. - parameter downloadTask: The download task that finished. - - parameter location: A file URL for the temporary file. Because the file is temporary, you must either - open the file for reading or move it to a permanent location in your app’s sandbox + - parameter location: A file URL for the temporary file. Because the file is temporary, you must either + open the file for reading or move it to a permanent location in your app’s sandbox container directory before returning from this delegate method. */ public func URLSession( @@ -665,11 +699,11 @@ public class Manager { - parameter session: The session containing the download task. - parameter downloadTask: The download task. - - parameter bytesWritten: The number of bytes transferred since the last time this delegate + - parameter bytesWritten: The number of bytes transferred since the last time this delegate method was called. - parameter totalBytesWritten: The total number of bytes transferred so far. - - parameter totalBytesExpectedToWrite: The expected length of the file, as provided by the Content-Length - header. If this header was not provided, the value is + - parameter totalBytesExpectedToWrite: The expected length of the file, as provided by the Content-Length + header. If this header was not provided, the value is `NSURLSessionTransferSizeUnknown`. */ public func URLSession( @@ -697,11 +731,11 @@ public class Manager { - parameter session: The session containing the download task that finished. - parameter downloadTask: The download task that resumed. See explanation in the discussion. - - parameter fileOffset: If the file's cache policy or last modified date prevents reuse of the - existing content, then this value is zero. Otherwise, this value is an - integer representing the number of bytes on disk that do not need to be + - parameter fileOffset: If the file's cache policy or last modified date prevents reuse of the + existing content, then this value is zero. Otherwise, this value is an + integer representing the number of bytes on disk that do not need to be retrieved again. - - parameter expectedTotalBytes: The expected length of the file, as provided by the Content-Length header. + - parameter expectedTotalBytes: The expected length of the file, as provided by the Content-Length header. If this header was not provided, the value is NSURLSessionTransferSizeUnknown. */ public func URLSession( diff --git a/Pods/Alamofire/Source/MultipartFormData.swift b/Pods/Alamofire/Source/MultipartFormData.swift index b4087ec..5a7ef09 100644 --- a/Pods/Alamofire/Source/MultipartFormData.swift +++ b/Pods/Alamofire/Source/MultipartFormData.swift @@ -31,10 +31,10 @@ import CoreServices #endif /** - Constructs `multipart/form-data` for uploads within an HTTP or HTTPS body. There are currently two ways to encode - multipart form data. The first way is to encode the data directly in memory. This is very efficient, but can lead - to memory issues if the dataset is too large. The second way is designed for larger datasets and will write all the - data to a single file on disk with all the proper boundary segmentation. The second approach MUST be used for + Constructs `multipart/form-data` for uploads within an HTTP or HTTPS body. There are currently two ways to encode + multipart form data. The first way is to encode the data directly in memory. This is very efficient, but can lead + to memory issues if the dataset is too large. The second way is designed for larger datasets and will write all the + data to a single file on disk with all the proper boundary segmentation. The second approach MUST be used for larger datasets such as video content, otherwise your app may run out of memory when trying to encode the dataset. For more information on `multipart/form-data` in general, please refer to the RFC-2388 and RFC-2045 specs as well @@ -118,7 +118,7 @@ public class MultipartFormData { self.bodyParts = [] /** - * The optimal read/write buffer size in bytes for input and output streams is 1024 (1KB). For more + * The optimal read/write buffer size in bytes for input and output streams is 1024 (1KB). For more * information, please refer to the following article: * - https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/Streams/Articles/ReadingInputStreams.html */ @@ -367,8 +367,8 @@ public class MultipartFormData { /** Encodes all the appended body parts into a single `NSData` object. - It is important to note that this method will load all the appended body parts into memory all at the same - time. This method should only be used when the encoded data will have a small memory footprint. For large data + It is important to note that this method will load all the appended body parts into memory all at the same + time. This method should only be used when the encoded data will have a small memory footprint. For large data cases, please use the `writeEncodedDataToDisk(fileURL:completionHandler:)` method. - throws: An `NSError` if encoding encounters an error. diff --git a/Pods/Alamofire/Source/NetworkReachabilityManager.swift b/Pods/Alamofire/Source/NetworkReachabilityManager.swift index 949ed28..d5e00ae 100644 --- a/Pods/Alamofire/Source/NetworkReachabilityManager.swift +++ b/Pods/Alamofire/Source/NetworkReachabilityManager.swift @@ -61,7 +61,7 @@ public class NetworkReachabilityManager { case WWAN } - /// A closure executed when the network reachability status changes. The closure takes a single argument: the + /// A closure executed when the network reachability status changes. The closure takes a single argument: the /// network reachability status. public typealias Listener = NetworkReachabilityStatus -> Void @@ -116,32 +116,23 @@ public class NetworkReachabilityManager { } /** - Creates a `NetworkReachabilityManager` instance with the default socket IPv4 or IPv6 address. + Creates a `NetworkReachabilityManager` instance that monitors the address 0.0.0.0. + + Reachability treats the 0.0.0.0 address as a special token that causes it to monitor the general routing + status of the device, both IPv4 and IPv6. - returns: The new `NetworkReachabilityManager` instance. - */ + */ public convenience init?() { - if #available(iOS 9.0, OSX 10.10, *) { - var address = sockaddr_in6() - address.sin6_len = UInt8(sizeofValue(address)) - address.sin6_family = sa_family_t(AF_INET6) + var address = sockaddr_in() + address.sin_len = UInt8(sizeofValue(address)) + address.sin_family = sa_family_t(AF_INET) - guard let reachability = withUnsafePointer(&address, { - SCNetworkReachabilityCreateWithAddress(nil, UnsafePointer($0)) - }) else { return nil } + guard let reachability = withUnsafePointer(&address, { + SCNetworkReachabilityCreateWithAddress(nil, UnsafePointer($0)) + }) else { return nil } - self.init(reachability: reachability) - } else { - var address = sockaddr_in() - address.sin_len = UInt8(sizeofValue(address)) - address.sin_family = sa_family_t(AF_INET) - - guard let reachability = withUnsafePointer(&address, { - SCNetworkReachabilityCreateWithAddress(nil, UnsafePointer($0)) - }) else { return nil } - - self.init(reachability: reachability) - } + self.init(reachability: reachability) } private init(reachability: SCNetworkReachability) { diff --git a/Pods/Alamofire/Source/Notifications.swift b/Pods/Alamofire/Source/Notifications.swift index cece87a..a7dbcfe 100644 --- a/Pods/Alamofire/Source/Notifications.swift +++ b/Pods/Alamofire/Source/Notifications.swift @@ -32,7 +32,7 @@ public struct Notifications { /// `NSURLSessionTask`. public static let DidResume = "com.alamofire.notifications.task.didResume" - /// Notification posted when an `NSURLSessionTask` is suspended. The notification `object` contains the + /// Notification posted when an `NSURLSessionTask` is suspended. The notification `object` contains the /// suspended `NSURLSessionTask`. public static let DidSuspend = "com.alamofire.notifications.task.didSuspend" diff --git a/Pods/Alamofire/Source/ParameterEncoding.swift b/Pods/Alamofire/Source/ParameterEncoding.swift index bfa4d12..c54e58b 100644 --- a/Pods/Alamofire/Source/ParameterEncoding.swift +++ b/Pods/Alamofire/Source/ParameterEncoding.swift @@ -38,8 +38,8 @@ public enum Method: String { /** Used to specify the way in which a set of parameters are applied to a URL request. - - `URL`: Creates a query string to be set as or appended to any existing URL query for `GET`, `HEAD`, - and `DELETE` requests, or set as the body for requests with any other HTTP method. The + - `URL`: Creates a query string to be set as or appended to any existing URL query for `GET`, `HEAD`, + and `DELETE` requests, or set as the body for requests with any other HTTP method. The `Content-Type` HTTP header field of an encoded request with HTTP body is set to `application/x-www-form-urlencoded; charset=utf-8`. Since there is no published specification for how to encode collection types, the convention of appending `[]` to the key for array @@ -49,8 +49,8 @@ public enum Method: String { - `URLEncodedInURL`: Creates query string to be set as or appended to any existing URL query. Uses the same implementation as the `.URL` case, but always applies the encoded result to the URL. - - `JSON`: Uses `NSJSONSerialization` to create a JSON representation of the parameters object, which is - set as the body of the request. The `Content-Type` HTTP header field of an encoded request is + - `JSON`: Uses `NSJSONSerialization` to create a JSON representation of the parameters object, which is + set as the body of the request. The `Content-Type` HTTP header field of an encoded request is set to `application/json`. - `PropertyList`: Uses `NSPropertyListSerialization` to create a plist representation of the parameters object, @@ -74,7 +74,7 @@ public enum ParameterEncoding { - parameter URLRequest: The request to have parameters applied. - parameter parameters: The parameters to apply. - - returns: A tuple containing the constructed request and the error that occurred during parameter encoding, + - returns: A tuple containing the constructed request and the error that occurred during parameter encoding, if any. */ public func encode( @@ -229,7 +229,7 @@ public enum ParameterEncoding { //========================================================================================================== // // Batching is required for escaping due to an internal bug in iOS 8.1 and 8.2. Encoding more than a few - // hundred Chinense characters causes various malloc error crashes. To avoid this issue until iOS 8 is no + // hundred Chinese characters causes various malloc error crashes. To avoid this issue until iOS 8 is no // longer supported, batching MUST be used for encoding. This introduces roughly a 20% overhead. For more // info, please refer to: // diff --git a/Pods/Alamofire/Source/Request.swift b/Pods/Alamofire/Source/Request.swift index 817cca5..3e1c731 100644 --- a/Pods/Alamofire/Source/Request.swift +++ b/Pods/Alamofire/Source/Request.swift @@ -25,7 +25,7 @@ import Foundation /** - Responsible for sending a request and receiving the response and associated data from the server, as well as + Responsible for sending a request and receiving the response and associated data from the server, as well as managing its underlying `NSURLSessionTask`. */ public class Request { @@ -126,12 +126,12 @@ public class Request { // MARK: - Progress /** - Sets a closure to be called periodically during the lifecycle of the request as data is written to or read + Sets a closure to be called periodically during the lifecycle of the request as data is written to or read from the server. - - For uploads, the progress closure returns the bytes written, total bytes written, and total bytes expected + - For uploads, the progress closure returns the bytes written, total bytes written, and total bytes expected to write. - - For downloads and data tasks, the progress closure returns the bytes read, total bytes read, and total bytes + - For downloads and data tasks, the progress closure returns the bytes read, total bytes read, and total bytes expected to read. - parameter closure: The code to be executed periodically during the lifecycle of the request. @@ -153,8 +153,8 @@ public class Request { /** Sets a closure to be called periodically during the lifecycle of the request as data is read from the server. - This closure returns the bytes most recently received from the server, not including data from previous calls. - If this closure is set, data will only be available within this closure, and will not be saved elsewhere. It is + This closure returns the bytes most recently received from the server, not including data from previous calls. + If this closure is set, data will only be available within this closure, and will not be saved elsewhere. It is also important to note that the `response` closure will be called with nil `responseData`. - parameter closure: The code to be executed periodically during the lifecycle of the request. @@ -210,7 +210,7 @@ public class Request { // MARK: - TaskDelegate /** - The task delegate is responsible for handling all delegate callbacks for the underlying task as well as + The task delegate is responsible for handling all delegate callbacks for the underlying task as well as executing all operations attached to the serial operation queue upon task completion. */ public class TaskDelegate: NSObject { @@ -458,7 +458,7 @@ public class Request { extension Request: CustomStringConvertible { /** - The textual representation used when written to an output stream, which includes the HTTP method and URL, as + The textual representation used when written to an output stream, which includes the HTTP method and URL, as well as the response status code if a response has been received. */ public var description: String { @@ -556,7 +556,11 @@ extension Request: CustomDebugStringConvertible { components.append("-d \"\(escapedBody)\"") } + #if swift(>=2.3) + components.append("\"\(URL.absoluteString!)\"") + #else components.append("\"\(URL.absoluteString)\"") + #endif return components.joinWithSeparator(" \\\n\t") } diff --git a/Pods/Alamofire/Source/Response.swift b/Pods/Alamofire/Source/Response.swift index dd700bb..9c437ff 100644 --- a/Pods/Alamofire/Source/Response.swift +++ b/Pods/Alamofire/Source/Response.swift @@ -44,7 +44,7 @@ public struct Response { /** Initializes the `Response` instance with the specified URL request, URL response, server data and response serialization result. - + - parameter request: The URL request sent to the server. - parameter response: The server's response to the URL request. - parameter data: The data returned by the server. diff --git a/Pods/Alamofire/Source/ResponseSerialization.swift b/Pods/Alamofire/Source/ResponseSerialization.swift index 5b7b61f..89e3954 100644 --- a/Pods/Alamofire/Source/ResponseSerialization.swift +++ b/Pods/Alamofire/Source/ResponseSerialization.swift @@ -101,7 +101,7 @@ extension Request { Adds a handler to be called once the request has finished. - parameter queue: The queue on which the completion handler is dispatched. - - parameter responseSerializer: The response serializer responsible for serializing the request, response, + - parameter responseSerializer: The response serializer responsible for serializing the request, response, and data. - parameter completionHandler: The code to be executed once the request has finished. @@ -192,10 +192,10 @@ extension Request { extension Request { /** - Creates a response serializer that returns a string initialized from the response data with the specified + Creates a response serializer that returns a string initialized from the response data with the specified string encoding. - - parameter encoding: The string encoding. If `nil`, the string encoding will be determined from the server + - parameter encoding: The string encoding. If `nil`, the string encoding will be determined from the server response, falling back to the default HTTP default character set, ISO-8859-1. - returns: A string response serializer. @@ -214,9 +214,9 @@ extension Request { let error = Error.error(code: .StringSerializationFailed, failureReason: failureReason) return .Failure(error) } - + var convertedEncoding = encoding - + if let encodingName = response?.textEncodingName where convertedEncoding == nil { convertedEncoding = CFStringConvertEncodingToNSStringEncoding( CFStringConvertIANACharSetNameToEncoding(encodingName) @@ -238,8 +238,8 @@ extension Request { /** Adds a handler to be called once the request has finished. - - parameter encoding: The string encoding. If `nil`, the string encoding will be determined from the - server response, falling back to the default HTTP default character set, + - parameter encoding: The string encoding. If `nil`, the string encoding will be determined from the + server response, falling back to the default HTTP default character set, ISO-8859-1. - parameter completionHandler: A closure to be executed once the request has finished. @@ -264,7 +264,7 @@ extension Request { extension Request { /** - Creates a response serializer that returns a JSON object constructed from the response data using + Creates a response serializer that returns a JSON object constructed from the response data using `NSJSONSerialization` with the specified reading options. - parameter options: The JSON serialization reading options. `.AllowFragments` by default. @@ -322,7 +322,7 @@ extension Request { extension Request { /** - Creates a response serializer that returns an object constructed from the response data using + Creates a response serializer that returns an object constructed from the response data using `NSPropertyListSerialization` with the specified reading options. - parameter options: The property list reading options. `NSPropertyListReadOptions()` by default. @@ -358,7 +358,7 @@ extension Request { - parameter options: The property list reading options. `0` by default. - parameter completionHandler: A closure to be executed once the request has finished. The closure takes 3 - arguments: the URL request, the URL response, the server data and the result + arguments: the URL request, the URL response, the server data and the result produced while creating the property list. - returns: The request. diff --git a/Pods/Alamofire/Source/Result.swift b/Pods/Alamofire/Source/Result.swift index ed1df0f..4aabf08 100644 --- a/Pods/Alamofire/Source/Result.swift +++ b/Pods/Alamofire/Source/Result.swift @@ -27,9 +27,9 @@ import Foundation /** Used to represent whether a request was successful or encountered an error. - - Success: The request and all post processing operations were successful resulting in the serialization of the + - Success: The request and all post processing operations were successful resulting in the serialization of the provided associated value. - - Failure: The request encountered an error resulting in a failure. The associated values are the original data + - Failure: The request encountered an error resulting in a failure. The associated values are the original data provided by the server as well as the error that caused the failure. */ public enum Result { @@ -75,7 +75,7 @@ public enum Result { // MARK: - CustomStringConvertible extension Result: CustomStringConvertible { - /// The textual representation used when written to an output stream, which includes whether the result was a + /// The textual representation used when written to an output stream, which includes whether the result was a /// success or failure. public var description: String { switch self { diff --git a/Pods/Alamofire/Source/ServerTrustPolicy.swift b/Pods/Alamofire/Source/ServerTrustPolicy.swift index 44ba100..c721144 100644 --- a/Pods/Alamofire/Source/ServerTrustPolicy.swift +++ b/Pods/Alamofire/Source/ServerTrustPolicy.swift @@ -32,9 +32,9 @@ public class ServerTrustPolicyManager { /** Initializes the `ServerTrustPolicyManager` instance with the given policies. - Since different servers and web services can have different leaf certificates, intermediate and even root - certficates, it is important to have the flexibility to specify evaluation policies on a per host basis. This - allows for scenarios such as using default evaluation for host1, certificate pinning for host2, public key + Since different servers and web services can have different leaf certificates, intermediate and even root + certficates, it is important to have the flexibility to specify evaluation policies on a per host basis. This + allows for scenarios such as using default evaluation for host1, certificate pinning for host2, public key pinning for host3 and disabling evaluation for host4. - parameter policies: A dictionary of all policies mapped to a particular host. @@ -80,31 +80,31 @@ extension NSURLSession { // MARK: - ServerTrustPolicy /** - The `ServerTrustPolicy` evaluates the server trust generally provided by an `NSURLAuthenticationChallenge` when - connecting to a server over a secure HTTPS connection. The policy configuration then evaluates the server trust + The `ServerTrustPolicy` evaluates the server trust generally provided by an `NSURLAuthenticationChallenge` when + connecting to a server over a secure HTTPS connection. The policy configuration then evaluates the server trust with a given set of criteria to determine whether the server trust is valid and the connection should be made. - Using pinned certificates or public keys for evaluation helps prevent man-in-the-middle (MITM) attacks and other - vulnerabilities. Applications dealing with sensitive customer data or financial information are strongly encouraged + Using pinned certificates or public keys for evaluation helps prevent man-in-the-middle (MITM) attacks and other + vulnerabilities. Applications dealing with sensitive customer data or financial information are strongly encouraged to route all communication over an HTTPS connection with pinning enabled. - - PerformDefaultEvaluation: Uses the default server trust evaluation while allowing you to control whether to - validate the host provided by the challenge. Applications are encouraged to always - validate the host in production environments to guarantee the validity of the server's + - PerformDefaultEvaluation: Uses the default server trust evaluation while allowing you to control whether to + validate the host provided by the challenge. Applications are encouraged to always + validate the host in production environments to guarantee the validity of the server's certificate chain. - PinCertificates: Uses the pinned certificates to validate the server trust. The server trust is - considered valid if one of the pinned certificates match one of the server certificates. - By validating both the certificate chain and host, certificate pinning provides a very - secure form of server trust validation mitigating most, if not all, MITM attacks. - Applications are encouraged to always validate the host and require a valid certificate + considered valid if one of the pinned certificates match one of the server certificates. + By validating both the certificate chain and host, certificate pinning provides a very + secure form of server trust validation mitigating most, if not all, MITM attacks. + Applications are encouraged to always validate the host and require a valid certificate chain in production environments. - PinPublicKeys: Uses the pinned public keys to validate the server trust. The server trust is considered - valid if one of the pinned public keys match one of the server certificate public keys. - By validating both the certificate chain and host, public key pinning provides a very - secure form of server trust validation mitigating most, if not all, MITM attacks. - Applications are encouraged to always validate the host and require a valid certificate + valid if one of the pinned public keys match one of the server certificate public keys. + By validating both the certificate chain and host, public key pinning provides a very + secure form of server trust validation mitigating most, if not all, MITM attacks. + Applications are encouraged to always validate the host and require a valid certificate chain in production environments. - DisableEvaluation: Disables all evaluation which in turn will always consider any server trust as valid. @@ -181,13 +181,21 @@ public enum ServerTrustPolicy { switch self { case let .PerformDefaultEvaluation(validateHost): let policy = SecPolicyCreateSSL(true, validateHost ? host as CFString : nil) - SecTrustSetPolicies(serverTrust, [policy]) + #if swift(>=2.3) + SecTrustSetPolicies(serverTrust, policy) + #else + SecTrustSetPolicies(serverTrust, [policy]) + #endif serverTrustIsValid = trustIsValid(serverTrust) case let .PinCertificates(pinnedCertificates, validateCertificateChain, validateHost): if validateCertificateChain { let policy = SecPolicyCreateSSL(true, validateHost ? host as CFString : nil) + #if swift(>=2.3) + SecTrustSetPolicies(serverTrust, policy) + #else SecTrustSetPolicies(serverTrust, [policy]) + #endif SecTrustSetAnchorCertificates(serverTrust, pinnedCertificates) SecTrustSetAnchorCertificatesOnly(serverTrust, true) @@ -211,7 +219,11 @@ public enum ServerTrustPolicy { if validateCertificateChain { let policy = SecPolicyCreateSSL(true, validateHost ? host as CFString : nil) + #if swift(>=2.3) + SecTrustSetPolicies(serverTrust, policy) + #else SecTrustSetPolicies(serverTrust, [policy]) + #endif certificateChainEvaluationPassed = trustIsValid(serverTrust) } @@ -239,13 +251,23 @@ public enum ServerTrustPolicy { private func trustIsValid(trust: SecTrust) -> Bool { var isValid = false - + #if swift(>=2.3) + var result = SecTrustResultType(rawValue: SecTrustResultType.Invalid.rawValue) + let status = SecTrustEvaluate(trust, &result!) + #else var result = SecTrustResultType(kSecTrustResultInvalid) let status = SecTrustEvaluate(trust, &result) + #endif if status == errSecSuccess { + #if swift(>=2.3) + let unspecified = SecTrustResultType(rawValue: SecTrustResultType.Unspecified.rawValue) + let proceed = SecTrustResultType(rawValue: SecTrustResultType.Proceed.rawValue) + #else let unspecified = SecTrustResultType(kSecTrustResultUnspecified) let proceed = SecTrustResultType(kSecTrustResultProceed) + #endif + isValid = result == unspecified || result == proceed } diff --git a/Pods/Alamofire/Source/Stream.swift b/Pods/Alamofire/Source/Stream.swift index 07ebe33..e463d9b 100644 --- a/Pods/Alamofire/Source/Stream.swift +++ b/Pods/Alamofire/Source/Stream.swift @@ -64,7 +64,7 @@ extension Manager { - parameter hostName: The hostname of the server to connect to. - parameter port: The port of the server to connect to. - :returns: The created stream request. + - returns: The created stream request. */ public func stream(hostName hostName: String, port: Int) -> Request { return stream(.Stream(hostName, port)) diff --git a/Pods/Alamofire/Source/Timeline.swift b/Pods/Alamofire/Source/Timeline.swift index 3610f15..f347705 100644 --- a/Pods/Alamofire/Source/Timeline.swift +++ b/Pods/Alamofire/Source/Timeline.swift @@ -54,10 +54,10 @@ public struct Timeline { Creates a new `Timeline` instance with the specified request times. - parameter requestStartTime: The time the request was initialized. Defaults to `0.0`. - - parameter initialResponseTime: The time the first bytes were received from or sent to the server. + - parameter initialResponseTime: The time the first bytes were received from or sent to the server. Defaults to `0.0`. - parameter requestCompletedTime: The time when the request was completed. Defaults to `0.0`. - - parameter serializationCompletedTime: The time when the response serialization was completed. Defaults + - parameter serializationCompletedTime: The time when the response serialization was completed. Defaults to `0.0`. - returns: The new `Timeline` instance. @@ -83,7 +83,7 @@ public struct Timeline { // MARK: - CustomStringConvertible extension Timeline: CustomStringConvertible { - /// The textual representation used when written to an output stream, which includes the latency, the request + /// The textual representation used when written to an output stream, which includes the latency, the request /// duration and the total duration. public var description: String { let latency = String(format: "%.3f", self.latency) @@ -91,35 +91,48 @@ extension Timeline: CustomStringConvertible { let serializationDuration = String(format: "%.3f", self.serializationDuration) let totalDuration = String(format: "%.3f", self.totalDuration) + // NOTE: Had to move to string concatenation due to memory leak filed as rdar://26761490. Once memory leak is + // fixed, we should move back to string interpolation by reverting commit 7d4a43b1. let timings = [ - "\"Latency\": \(latency) secs", - "\"Request Duration\": \(requestDuration) secs", - "\"Serialization Duration\": \(serializationDuration) secs", - "\"Total Duration\": \(totalDuration) secs" + "\"Latency\": " + latency + " secs", + "\"Request Duration\": " + requestDuration + " secs", + "\"Serialization Duration\": " + serializationDuration + " secs", + "\"Total Duration\": " + totalDuration + " secs" ] - return "Timeline: { \(timings.joinWithSeparator(", ")) }" + return "Timeline: { " + timings.joinWithSeparator(", ") + " }" } } // MARK: - CustomDebugStringConvertible extension Timeline: CustomDebugStringConvertible { - /// The textual representation used when written to an output stream, which includes the request start time, the + /// The textual representation used when written to an output stream, which includes the request start time, the /// initial response time, the request completed time, the serialization completed time, the latency, the request /// duration and the total duration. public var debugDescription: String { + let requestStartTime = String(format: "%.3f", self.requestStartTime) + let initialResponseTime = String(format: "%.3f", self.initialResponseTime) + let requestCompletedTime = String(format: "%.3f", self.requestCompletedTime) + let serializationCompletedTime = String(format: "%.3f", self.serializationCompletedTime) + let latency = String(format: "%.3f", self.latency) + let requestDuration = String(format: "%.3f", self.requestDuration) + let serializationDuration = String(format: "%.3f", self.serializationDuration) + let totalDuration = String(format: "%.3f", self.totalDuration) + + // NOTE: Had to move to string concatenation due to memory leak filed as rdar://26761490. Once memory leak is + // fixed, we should move back to string interpolation by reverting commit 7d4a43b1. let timings = [ - "\"Request Start Time\": \(requestStartTime)", - "\"Initial Response Time\": \(initialResponseTime)", - "\"Request Completed Time\": \(requestCompletedTime)", - "\"Serialization Completed Time\": \(serializationCompletedTime)", - "\"Latency\": \(latency) secs", - "\"Request Duration\": \(requestDuration) secs", - "\"Serialization Duration\": \(serializationDuration) secs", - "\"Total Duration\": \(totalDuration) secs" + "\"Request Start Time\": " + requestStartTime, + "\"Initial Response Time\": " + initialResponseTime, + "\"Request Completed Time\": " + requestCompletedTime, + "\"Serialization Completed Time\": " + serializationCompletedTime, + "\"Latency\": " + latency + " secs", + "\"Request Duration\": " + requestDuration + " secs", + "\"Serialization Duration\": " + serializationDuration + " secs", + "\"Total Duration\": " + totalDuration + " secs" ] - return "Timeline: { \(timings.joinWithSeparator(", ")) }" + return "Timeline: { " + timings.joinWithSeparator(", ") + " }" } } diff --git a/Pods/Alamofire/Source/Upload.swift b/Pods/Alamofire/Source/Upload.swift index 7b31ba5..33703f0 100644 --- a/Pods/Alamofire/Source/Upload.swift +++ b/Pods/Alamofire/Source/Upload.swift @@ -194,12 +194,12 @@ extension Manager { public static let MultipartFormDataEncodingMemoryThreshold: UInt64 = 10 * 1024 * 1024 /** - Defines whether the `MultipartFormData` encoding was successful and contains result of the encoding as + Defines whether the `MultipartFormData` encoding was successful and contains result of the encoding as associated values. - - Success: Represents a successful `MultipartFormData` encoding and contains the new `Request` along with + - Success: Represents a successful `MultipartFormData` encoding and contains the new `Request` along with streaming information. - - Failure: Used to represent a failure in the `MultipartFormData` encoding and also contains the encoding + - Failure: Used to represent a failure in the `MultipartFormData` encoding and also contains the encoding error. */ public enum MultipartFormDataEncodingResult { @@ -210,17 +210,17 @@ extension Manager { /** Encodes the `MultipartFormData` and creates a request to upload the result to the specified URL request. - It is important to understand the memory implications of uploading `MultipartFormData`. If the cummulative - payload is small, encoding the data in-memory and directly uploading to a server is the by far the most - efficient approach. However, if the payload is too large, encoding the data in-memory could cause your app to - be terminated. Larger payloads must first be written to disk using input and output streams to keep the memory - footprint low, then the data can be uploaded as a stream from the resulting file. Streaming from disk MUST be + It is important to understand the memory implications of uploading `MultipartFormData`. If the cummulative + payload is small, encoding the data in-memory and directly uploading to a server is the by far the most + efficient approach. However, if the payload is too large, encoding the data in-memory could cause your app to + be terminated. Larger payloads must first be written to disk using input and output streams to keep the memory + footprint low, then the data can be uploaded as a stream from the resulting file. Streaming from disk MUST be used for larger payloads such as video content. - The `encodingMemoryThreshold` parameter allows Alamofire to automatically determine whether to encode in-memory + The `encodingMemoryThreshold` parameter allows Alamofire to automatically determine whether to encode in-memory or stream from disk. If the content length of the `MultipartFormData` is below the `encodingMemoryThreshold`, - encoding takes place in-memory. If the content length exceeds the threshold, the data is streamed to disk - during the encoding process. Then the result is uploaded as data or as a stream depending on which encoding + encoding takes place in-memory. If the content length exceeds the threshold, the data is streamed to disk + during the encoding process. Then the result is uploaded as data or as a stream depending on which encoding technique was used. If `startRequestsImmediately` is `true`, the request will have `resume()` called before being returned. @@ -310,14 +310,20 @@ extension Manager { } else { let fileManager = NSFileManager.defaultManager() let tempDirectoryURL = NSURL(fileURLWithPath: NSTemporaryDirectory()) - let directoryURL = tempDirectoryURL.URLByAppendingPathComponent("com.alamofire.manager/multipart.form.data") let fileName = NSUUID().UUIDString + #if swift(>=2.3) + let directoryURL = tempDirectoryURL.URLByAppendingPathComponent("com.alamofire.manager/multipart.form.data")! + let fileURL = directoryURL.URLByAppendingPathComponent(fileName)! + #else + let directoryURL = tempDirectoryURL.URLByAppendingPathComponent("com.alamofire.manager/multipart.form.data") let fileURL = directoryURL.URLByAppendingPathComponent(fileName) + #endif do { try fileManager.createDirectoryAtURL(directoryURL, withIntermediateDirectories: true, attributes: nil) try formData.writeEncodedDataToDisk(fileURL) + dispatch_async(dispatch_get_main_queue()) { let encodingResult = MultipartFormDataEncodingResult.Success( request: self.upload(URLRequestWithContentType, file: fileURL), diff --git a/Pods/Alamofire/Source/Validation.swift b/Pods/Alamofire/Source/Validation.swift index e90db2d..b94e07d 100644 --- a/Pods/Alamofire/Source/Validation.swift +++ b/Pods/Alamofire/Source/Validation.swift @@ -38,7 +38,7 @@ extension Request { } /** - A closure used to validate a request that takes a URL request and URL response, and returns whether the + A closure used to validate a request that takes a URL request and URL response, and returns whether the request was valid. */ public typealias Validation = (NSURLRequest?, NSHTTPURLResponse) -> ValidationResult @@ -140,7 +140,7 @@ extension Request { - returns: The request. */ - public func validate(contentType acceptableContentTypes: S) -> Self { + public func validate(contentType acceptableContentTypes: S) -> Self { return validate { _, response in guard let validData = self.delegate.data where validData.length > 0 else { return .Success } @@ -192,7 +192,7 @@ extension Request { // MARK: - Automatic /** - Validates that the response has a status code in the default acceptable range of 200...299, and that the content + Validates that the response has a status code in the default acceptable range of 200...299, and that the content type matches any specified in the Accept HTTP header field. If validation fails, subsequent calls to response handlers will have an associated error. diff --git a/Pods/Manifest.lock b/Pods/Manifest.lock index c3a331c..33ab6b9 100644 --- a/Pods/Manifest.lock +++ b/Pods/Manifest.lock @@ -1,20 +1,20 @@ PODS: - - Alamofire (3.4.0) + - Alamofire (3.5.0) - BRLOptionParser (0.3.1) - GCDWebServer (3.3.3): - GCDWebServer/Core (= 3.3.3) - GCDWebServer/Core (3.3.3) DEPENDENCIES: - - Alamofire (~> 3.4) + - Alamofire (~> 3.5) - BRLOptionParser (~> 0.3.1) - GCDWebServer (~> 3.0) SPEC CHECKSUMS: - Alamofire: c19a627cefd6a95f840401c49ab1f124e07f54ee + Alamofire: b70a7352335f8ea5babd0a923eb7e8eacc67b877 BRLOptionParser: a03256a8ff003ca1f5376c55f55f210e085a3958 GCDWebServer: 1c39a1f0763e4eb492bee021e4270fce097d3555 -PODFILE CHECKSUM: 1c9b3b36679167f8e54cc2369d7d1a22d8446883 +PODFILE CHECKSUM: c8b8f02e60b644ad152c38e879174addd695404c -COCOAPODS: 1.0.1 +COCOAPODS: 1.1.0.rc.2 diff --git a/Pods/Pods.xcodeproj/project.pbxproj b/Pods/Pods.xcodeproj/project.pbxproj index 8f69545..9d98167 100644 --- a/Pods/Pods.xcodeproj/project.pbxproj +++ b/Pods/Pods.xcodeproj/project.pbxproj @@ -653,7 +653,7 @@ isa = PBXProject; attributes = { LastSwiftUpdateCheck = 0730; - LastUpgradeCheck = 0700; + LastUpgradeCheck = 0800; }; buildConfigurationList = 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */; compatibilityVersion = "Xcode 3.2"; @@ -781,11 +781,64 @@ /* End PBXTargetDependency section */ /* Begin XCBuildConfiguration section */ - 371E0500757286AB22CAE64ADAE8D83B /* Debug */ = { + 00F75142B9A3AA9BA979B71D2C404698 /* Release */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 9BA2A0099476E08B6CC8026BDF0C603E /* Pods-ShadowsocksX-NGTests.debug.xcconfig */; + baseConfigurationReference = A5055B8EFFFBEDE50909E935D4BCA446 /* Pods-proxy_conf_helper.release.xcconfig */; buildSettings = { CODE_SIGN_IDENTITY = "-"; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_STRICT_OBJC_MSGSEND = YES; + EXECUTABLE_PREFIX = lib; + GCC_NO_COMMON_BLOCKS = YES; + MACH_O_TYPE = staticlib; + MACOSX_DEPLOYMENT_TARGET = 10.10; + MTL_ENABLE_DEBUG_INFO = NO; + OTHER_LDFLAGS = ""; + OTHER_LIBTOOLFLAGS = ""; + PODS_ROOT = "$(SRCROOT)"; + PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = macosx; + SKIP_INSTALL = YES; + }; + name = Release; + }; + 031770946E17E5080E7C1973521ED6BC /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 054C3E84057CD06DB85D99E7AD207F48 /* Pods-proxy_conf_helper.debug.xcconfig */; + buildSettings = { + CODE_SIGN_IDENTITY = "-"; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + EXECUTABLE_PREFIX = lib; + GCC_NO_COMMON_BLOCKS = YES; + MACH_O_TYPE = staticlib; + MACOSX_DEPLOYMENT_TARGET = 10.10; + MTL_ENABLE_DEBUG_INFO = YES; + OTHER_LDFLAGS = ""; + OTHER_LIBTOOLFLAGS = ""; + PODS_ROOT = "$(SRCROOT)"; + PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = macosx; + SKIP_INSTALL = YES; + }; + name = Debug; + }; + 09CCD18A4DD4E0090FA47F079FC15C1F /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 24BCEE536E19B38E28CE6933A0D49A2D /* GCDWebServer.xcconfig */; + buildSettings = { + CODE_SIGN_IDENTITY = ""; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; COMBINE_HIDPI_IMAGES = YES; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; @@ -796,26 +849,95 @@ ENABLE_STRICT_OBJC_MSGSEND = YES; FRAMEWORK_VERSION = A; GCC_NO_COMMON_BLOCKS = YES; - INFOPLIST_FILE = "Target Support Files/Pods-ShadowsocksX-NGTests/Info.plist"; + GCC_PREFIX_HEADER = "Target Support Files/GCDWebServer/GCDWebServer-prefix.pch"; + INFOPLIST_FILE = "Target Support Files/GCDWebServer/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; - MACH_O_TYPE = staticlib; - MACOSX_DEPLOYMENT_TARGET = 10.10; - MODULEMAP_FILE = "Target Support Files/Pods-ShadowsocksX-NGTests/Pods-ShadowsocksX-NGTests.modulemap"; + MACOSX_DEPLOYMENT_TARGET = 10.7; + MODULEMAP_FILE = "Target Support Files/GCDWebServer/GCDWebServer.modulemap"; MTL_ENABLE_DEBUG_INFO = YES; - OTHER_LDFLAGS = ""; - OTHER_LIBTOOLFLAGS = ""; - PODS_ROOT = "$(SRCROOT)"; - PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; - PRODUCT_NAME = Pods_ShadowsocksX_NGTests; + PRODUCT_NAME = GCDWebServer; SDKROOT = macosx; SKIP_INSTALL = YES; + SWIFT_VERSION = 2.3; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; - 4888EEFBEA04FABA2120470F4B676BBD /* Release */ = { + 679D13C7B23A28C7343E08D4EF371384 /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 089EB7E66F64D3A19BB7681AFCE91031 /* Pods-ShadowsocksX-NG.release.xcconfig */; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_IDENTITY = ""; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; + COMBINE_HIDPI_IMAGES = YES; + CURRENT_PROJECT_VERSION = 1; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + ENABLE_STRICT_OBJC_MSGSEND = YES; + FRAMEWORK_VERSION = A; + GCC_NO_COMMON_BLOCKS = YES; + INFOPLIST_FILE = "Target Support Files/Pods-ShadowsocksX-NG/Info.plist"; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; + MACH_O_TYPE = staticlib; + MACOSX_DEPLOYMENT_TARGET = 10.10; + MODULEMAP_FILE = "Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG.modulemap"; + MTL_ENABLE_DEBUG_INFO = NO; + OTHER_LDFLAGS = ""; + OTHER_LIBTOOLFLAGS = ""; + PODS_ROOT = "$(SRCROOT)"; + PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; + PRODUCT_NAME = Pods_ShadowsocksX_NG; + SDKROOT = macosx; + SKIP_INSTALL = YES; + VERSIONING_SYSTEM = "apple-generic"; + VERSION_INFO_PREFIX = ""; + }; + name = Release; + }; + 8346802FCF028CDB890A5034737BEA3E /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = B8B20CB588CB77EA9A11425CA9AC4402 /* Alamofire.xcconfig */; + buildSettings = { + CODE_SIGN_IDENTITY = ""; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; + COMBINE_HIDPI_IMAGES = YES; + CURRENT_PROJECT_VERSION = 1; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + ENABLE_STRICT_OBJC_MSGSEND = YES; + FRAMEWORK_VERSION = A; + GCC_NO_COMMON_BLOCKS = YES; + GCC_PREFIX_HEADER = "Target Support Files/Alamofire/Alamofire-prefix.pch"; + INFOPLIST_FILE = "Target Support Files/Alamofire/Info.plist"; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; + MACOSX_DEPLOYMENT_TARGET = 10.9; + MODULEMAP_FILE = "Target Support Files/Alamofire/Alamofire.modulemap"; + MTL_ENABLE_DEBUG_INFO = NO; + PRODUCT_NAME = Alamofire; + SDKROOT = macosx; + SKIP_INSTALL = YES; + SWIFT_VERSION = 2.3; + VERSIONING_SYSTEM = "apple-generic"; + VERSION_INFO_PREFIX = ""; + }; + name = Release; + }; + 9420A7205B8F85520AF134F4EE25F7CC /* Release */ = { isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; @@ -829,13 +951,18 @@ CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGNING_REQUIRED = NO; COPY_PHASE_STRIP = YES; ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; GCC_PREPROCESSOR_DEFINITIONS = ( "POD_CONFIGURATION_RELEASE=1", "$(inherited)", @@ -847,20 +974,50 @@ GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; MACOSX_DEPLOYMENT_TARGET = 10.10; + PROVISIONING_PROFILE_SPECIFIER = NO_SIGNING/; STRIP_INSTALLED_PRODUCT = NO; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; SYMROOT = "${SRCROOT}/../build"; VALIDATE_PRODUCT = YES; }; name = Release; }; - 4F1BC9CB0D8B1AB0DE3307D170A516B0 /* Release */ = { + 94F5075F5C6F147122E5F274E23FCC42 /* Debug */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 089EB7E66F64D3A19BB7681AFCE91031 /* Pods-ShadowsocksX-NG.release.xcconfig */; + baseConfigurationReference = C12AC1F78F621586EC3C233BD8CF4BE0 /* BRLOptionParser.xcconfig */; buildSettings = { CODE_SIGN_IDENTITY = "-"; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + EXECUTABLE_PREFIX = lib; + GCC_NO_COMMON_BLOCKS = YES; + GCC_PREFIX_HEADER = "Target Support Files/BRLOptionParser/BRLOptionParser-prefix.pch"; + MACOSX_DEPLOYMENT_TARGET = 10.7; + MTL_ENABLE_DEBUG_INFO = YES; + OTHER_LDFLAGS = ""; + OTHER_LIBTOOLFLAGS = ""; + PRIVATE_HEADERS_FOLDER_PATH = ""; + PRODUCT_NAME = "$(TARGET_NAME)"; + PUBLIC_HEADERS_FOLDER_PATH = ""; + SDKROOT = macosx; + }; + name = Debug; + }; + C98675A06B6AE6B2E23238062710F460 /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 98522BF2EB25C0255284080F9CA3E195 /* Pods-ShadowsocksX-NG.debug.xcconfig */; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_IDENTITY = ""; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; COMBINE_HIDPI_IMAGES = YES; CURRENT_PROJECT_VERSION = 1; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; @@ -874,7 +1031,7 @@ MACH_O_TYPE = staticlib; MACOSX_DEPLOYMENT_TARGET = 10.10; MODULEMAP_FILE = "Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG.modulemap"; - MTL_ENABLE_DEBUG_INFO = NO; + MTL_ENABLE_DEBUG_INFO = YES; OTHER_LDFLAGS = ""; OTHER_LIBTOOLFLAGS = ""; PODS_ROOT = "$(SRCROOT)"; @@ -882,101 +1039,20 @@ PRODUCT_NAME = Pods_ShadowsocksX_NG; SDKROOT = macosx; SKIP_INSTALL = YES; - VERSIONING_SYSTEM = "apple-generic"; - VERSION_INFO_PREFIX = ""; - }; - name = Release; - }; - 4F25746D417AD7959CEFE5D13B9045BF /* Debug */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = 054C3E84057CD06DB85D99E7AD207F48 /* Pods-proxy_conf_helper.debug.xcconfig */; - buildSettings = { - CODE_SIGN_IDENTITY = "-"; - DEBUG_INFORMATION_FORMAT = dwarf; - ENABLE_STRICT_OBJC_MSGSEND = YES; - EXECUTABLE_PREFIX = lib; - GCC_NO_COMMON_BLOCKS = YES; - MACH_O_TYPE = staticlib; - MACOSX_DEPLOYMENT_TARGET = 10.10; - MTL_ENABLE_DEBUG_INFO = YES; - OTHER_LDFLAGS = ""; - OTHER_LIBTOOLFLAGS = ""; - PODS_ROOT = "$(SRCROOT)"; - PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = macosx; - SKIP_INSTALL = YES; - }; - name = Debug; - }; - 81B3096945D568104AC14EE4F805950B /* Release */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = B8B20CB588CB77EA9A11425CA9AC4402 /* Alamofire.xcconfig */; - buildSettings = { - CODE_SIGN_IDENTITY = "-"; - COMBINE_HIDPI_IMAGES = YES; - CURRENT_PROJECT_VERSION = 1; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - DEFINES_MODULE = YES; - DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 1; - DYLIB_INSTALL_NAME_BASE = "@rpath"; - ENABLE_STRICT_OBJC_MSGSEND = YES; - FRAMEWORK_VERSION = A; - GCC_NO_COMMON_BLOCKS = YES; - GCC_PREFIX_HEADER = "Target Support Files/Alamofire/Alamofire-prefix.pch"; - INFOPLIST_FILE = "Target Support Files/Alamofire/Info.plist"; - INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; - LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; - MACOSX_DEPLOYMENT_TARGET = 10.9; - MODULEMAP_FILE = "Target Support Files/Alamofire/Alamofire.modulemap"; - MTL_ENABLE_DEBUG_INFO = NO; - PRODUCT_NAME = Alamofire; - SDKROOT = macosx; - SKIP_INSTALL = YES; - SWIFT_VERSION = ""; - VERSIONING_SYSTEM = "apple-generic"; - VERSION_INFO_PREFIX = ""; - }; - name = Release; - }; - 82B1EC5E8815E78991717D970C44B8D8 /* Debug */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = B8B20CB588CB77EA9A11425CA9AC4402 /* Alamofire.xcconfig */; - buildSettings = { - CODE_SIGN_IDENTITY = "-"; - COMBINE_HIDPI_IMAGES = YES; - CURRENT_PROJECT_VERSION = 1; - DEBUG_INFORMATION_FORMAT = dwarf; - DEFINES_MODULE = YES; - DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 1; - DYLIB_INSTALL_NAME_BASE = "@rpath"; - ENABLE_STRICT_OBJC_MSGSEND = YES; - FRAMEWORK_VERSION = A; - GCC_NO_COMMON_BLOCKS = YES; - GCC_PREFIX_HEADER = "Target Support Files/Alamofire/Alamofire-prefix.pch"; - INFOPLIST_FILE = "Target Support Files/Alamofire/Info.plist"; - INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; - LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; - MACOSX_DEPLOYMENT_TARGET = 10.9; - MODULEMAP_FILE = "Target Support Files/Alamofire/Alamofire.modulemap"; - MTL_ENABLE_DEBUG_INFO = YES; - PRODUCT_NAME = Alamofire; - SDKROOT = macosx; - SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - SWIFT_VERSION = ""; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; - 8A2A1FB2B9F55A664E92C5F52B674F7B /* Release */ = { + DBED2E7186D3EE230AACEE213E81582D /* Release */ = { isa = XCBuildConfiguration; - baseConfigurationReference = F67191B1F87DA238C4D87250DFBE43DD /* Pods-ShadowsocksX-NGTests.release.xcconfig */; + baseConfigurationReference = 24BCEE536E19B38E28CE6933A0D49A2D /* GCDWebServer.xcconfig */; buildSettings = { - CODE_SIGN_IDENTITY = "-"; + CODE_SIGN_IDENTITY = ""; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; COMBINE_HIDPI_IMAGES = YES; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; @@ -987,13 +1063,47 @@ ENABLE_STRICT_OBJC_MSGSEND = YES; FRAMEWORK_VERSION = A; GCC_NO_COMMON_BLOCKS = YES; + GCC_PREFIX_HEADER = "Target Support Files/GCDWebServer/GCDWebServer-prefix.pch"; + INFOPLIST_FILE = "Target Support Files/GCDWebServer/Info.plist"; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; + MACOSX_DEPLOYMENT_TARGET = 10.7; + MODULEMAP_FILE = "Target Support Files/GCDWebServer/GCDWebServer.modulemap"; + MTL_ENABLE_DEBUG_INFO = NO; + PRODUCT_NAME = GCDWebServer; + SDKROOT = macosx; + SKIP_INSTALL = YES; + SWIFT_VERSION = 2.3; + VERSIONING_SYSTEM = "apple-generic"; + VERSION_INFO_PREFIX = ""; + }; + name = Release; + }; + E993D4A1EFC27F876EC40C44A15ACB83 /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 9BA2A0099476E08B6CC8026BDF0C603E /* Pods-ShadowsocksX-NGTests.debug.xcconfig */; + buildSettings = { + CODE_SIGN_IDENTITY = ""; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; + COMBINE_HIDPI_IMAGES = YES; + CURRENT_PROJECT_VERSION = 1; + DEBUG_INFORMATION_FORMAT = dwarf; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + ENABLE_STRICT_OBJC_MSGSEND = YES; + FRAMEWORK_VERSION = A; + GCC_NO_COMMON_BLOCKS = YES; INFOPLIST_FILE = "Target Support Files/Pods-ShadowsocksX-NGTests/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; MACH_O_TYPE = staticlib; MACOSX_DEPLOYMENT_TARGET = 10.10; MODULEMAP_FILE = "Target Support Files/Pods-ShadowsocksX-NGTests/Pods-ShadowsocksX-NGTests.modulemap"; - MTL_ENABLE_DEBUG_INFO = NO; + MTL_ENABLE_DEBUG_INFO = YES; OTHER_LDFLAGS = ""; OTHER_LIBTOOLFLAGS = ""; PODS_ROOT = "$(SRCROOT)"; @@ -1004,34 +1114,16 @@ VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; - name = Release; - }; - 92B477579DE5EFCC17E358B57A3A599E /* Debug */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = C12AC1F78F621586EC3C233BD8CF4BE0 /* BRLOptionParser.xcconfig */; - buildSettings = { - CODE_SIGN_IDENTITY = "-"; - DEBUG_INFORMATION_FORMAT = dwarf; - ENABLE_STRICT_OBJC_MSGSEND = YES; - EXECUTABLE_PREFIX = lib; - GCC_NO_COMMON_BLOCKS = YES; - GCC_PREFIX_HEADER = "Target Support Files/BRLOptionParser/BRLOptionParser-prefix.pch"; - MACOSX_DEPLOYMENT_TARGET = 10.7; - MTL_ENABLE_DEBUG_INFO = YES; - OTHER_LDFLAGS = ""; - OTHER_LIBTOOLFLAGS = ""; - PRIVATE_HEADERS_FOLDER_PATH = ""; - PRODUCT_NAME = "$(TARGET_NAME)"; - PUBLIC_HEADERS_FOLDER_PATH = ""; - SDKROOT = macosx; - }; name = Debug; }; - 94D9BC00EEB34DA6CE7149B77BCFB946 /* Debug */ = { + EF056C7261651C7FA8BAEBC28385AA03 /* Debug */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 24BCEE536E19B38E28CE6933A0D49A2D /* GCDWebServer.xcconfig */; + baseConfigurationReference = B8B20CB588CB77EA9A11425CA9AC4402 /* Alamofire.xcconfig */; buildSettings = { - CODE_SIGN_IDENTITY = "-"; + CODE_SIGN_IDENTITY = ""; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; COMBINE_HIDPI_IMAGES = YES; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; @@ -1042,130 +1134,48 @@ ENABLE_STRICT_OBJC_MSGSEND = YES; FRAMEWORK_VERSION = A; GCC_NO_COMMON_BLOCKS = YES; - GCC_PREFIX_HEADER = "Target Support Files/GCDWebServer/GCDWebServer-prefix.pch"; - INFOPLIST_FILE = "Target Support Files/GCDWebServer/Info.plist"; + GCC_PREFIX_HEADER = "Target Support Files/Alamofire/Alamofire-prefix.pch"; + INFOPLIST_FILE = "Target Support Files/Alamofire/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; - MACOSX_DEPLOYMENT_TARGET = 10.7; - MODULEMAP_FILE = "Target Support Files/GCDWebServer/GCDWebServer.modulemap"; + MACOSX_DEPLOYMENT_TARGET = 10.9; + MODULEMAP_FILE = "Target Support Files/Alamofire/Alamofire.modulemap"; MTL_ENABLE_DEBUG_INFO = YES; - PRODUCT_NAME = GCDWebServer; - SDKROOT = macosx; - SKIP_INSTALL = YES; - VERSIONING_SYSTEM = "apple-generic"; - VERSION_INFO_PREFIX = ""; - }; - name = Debug; - }; - 9825B7CD16B076B290073DADEE5E3AEE /* Release */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = A5055B8EFFFBEDE50909E935D4BCA446 /* Pods-proxy_conf_helper.release.xcconfig */; - buildSettings = { - CODE_SIGN_IDENTITY = "-"; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - ENABLE_STRICT_OBJC_MSGSEND = YES; - EXECUTABLE_PREFIX = lib; - GCC_NO_COMMON_BLOCKS = YES; - MACH_O_TYPE = staticlib; - MACOSX_DEPLOYMENT_TARGET = 10.10; - MTL_ENABLE_DEBUG_INFO = NO; - OTHER_LDFLAGS = ""; - OTHER_LIBTOOLFLAGS = ""; - PODS_ROOT = "$(SRCROOT)"; - PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = macosx; - SKIP_INSTALL = YES; - }; - name = Release; - }; - 9B688665FDF44A7A81FB65791A544010 /* Release */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = 24BCEE536E19B38E28CE6933A0D49A2D /* GCDWebServer.xcconfig */; - buildSettings = { - CODE_SIGN_IDENTITY = "-"; - COMBINE_HIDPI_IMAGES = YES; - CURRENT_PROJECT_VERSION = 1; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - DEFINES_MODULE = YES; - DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 1; - DYLIB_INSTALL_NAME_BASE = "@rpath"; - ENABLE_STRICT_OBJC_MSGSEND = YES; - FRAMEWORK_VERSION = A; - GCC_NO_COMMON_BLOCKS = YES; - GCC_PREFIX_HEADER = "Target Support Files/GCDWebServer/GCDWebServer-prefix.pch"; - INFOPLIST_FILE = "Target Support Files/GCDWebServer/Info.plist"; - INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; - LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; - MACOSX_DEPLOYMENT_TARGET = 10.7; - MODULEMAP_FILE = "Target Support Files/GCDWebServer/GCDWebServer.modulemap"; - MTL_ENABLE_DEBUG_INFO = NO; - PRODUCT_NAME = GCDWebServer; - SDKROOT = macosx; - SKIP_INSTALL = YES; - VERSIONING_SYSTEM = "apple-generic"; - VERSION_INFO_PREFIX = ""; - }; - name = Release; - }; - B9E2E17CACCD9DB6ACE1EE1508A63590 /* Release */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = C12AC1F78F621586EC3C233BD8CF4BE0 /* BRLOptionParser.xcconfig */; - buildSettings = { - CODE_SIGN_IDENTITY = "-"; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - ENABLE_STRICT_OBJC_MSGSEND = YES; - EXECUTABLE_PREFIX = lib; - GCC_NO_COMMON_BLOCKS = YES; - GCC_PREFIX_HEADER = "Target Support Files/BRLOptionParser/BRLOptionParser-prefix.pch"; - MACOSX_DEPLOYMENT_TARGET = 10.7; - MTL_ENABLE_DEBUG_INFO = NO; - OTHER_LDFLAGS = ""; - OTHER_LIBTOOLFLAGS = ""; - PRIVATE_HEADERS_FOLDER_PATH = ""; - PRODUCT_NAME = "$(TARGET_NAME)"; - PUBLIC_HEADERS_FOLDER_PATH = ""; - SDKROOT = macosx; - }; - name = Release; - }; - CD7B15AF2FF01E3412E8AA0B13161458 /* Debug */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = 98522BF2EB25C0255284080F9CA3E195 /* Pods-ShadowsocksX-NG.debug.xcconfig */; - buildSettings = { - CODE_SIGN_IDENTITY = "-"; - COMBINE_HIDPI_IMAGES = YES; - CURRENT_PROJECT_VERSION = 1; - DEBUG_INFORMATION_FORMAT = dwarf; - DEFINES_MODULE = YES; - DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 1; - DYLIB_INSTALL_NAME_BASE = "@rpath"; - ENABLE_STRICT_OBJC_MSGSEND = YES; - FRAMEWORK_VERSION = A; - GCC_NO_COMMON_BLOCKS = YES; - INFOPLIST_FILE = "Target Support Files/Pods-ShadowsocksX-NG/Info.plist"; - INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; - LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; - MACH_O_TYPE = staticlib; - MACOSX_DEPLOYMENT_TARGET = 10.10; - MODULEMAP_FILE = "Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG.modulemap"; - MTL_ENABLE_DEBUG_INFO = YES; - OTHER_LDFLAGS = ""; - OTHER_LIBTOOLFLAGS = ""; - PODS_ROOT = "$(SRCROOT)"; - PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; - PRODUCT_NAME = Pods_ShadowsocksX_NG; + PRODUCT_NAME = Alamofire; SDKROOT = macosx; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 2.3; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; - DA2E206EB90DF75A25332AE4AA713F31 /* Debug */ = { + F1ACFFB424C32AEE0367EC6DA3C73FD9 /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = C12AC1F78F621586EC3C233BD8CF4BE0 /* BRLOptionParser.xcconfig */; + buildSettings = { + CODE_SIGN_IDENTITY = "-"; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_STRICT_OBJC_MSGSEND = YES; + EXECUTABLE_PREFIX = lib; + GCC_NO_COMMON_BLOCKS = YES; + GCC_PREFIX_HEADER = "Target Support Files/BRLOptionParser/BRLOptionParser-prefix.pch"; + MACOSX_DEPLOYMENT_TARGET = 10.7; + MTL_ENABLE_DEBUG_INFO = NO; + OTHER_LDFLAGS = ""; + OTHER_LIBTOOLFLAGS = ""; + PRIVATE_HEADERS_FOLDER_PATH = ""; + PRODUCT_NAME = "$(TARGET_NAME)"; + PUBLIC_HEADERS_FOLDER_PATH = ""; + SDKROOT = macosx; + }; + name = Release; + }; + F653E316AB5F825D3AD0CAE700E37071 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; @@ -1179,14 +1189,19 @@ CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGNING_REQUIRED = NO; COPY_PHASE_STRIP = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; ENABLE_TESTABILITY = YES; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; GCC_OPTIMIZATION_LEVEL = 0; GCC_PREPROCESSOR_DEFINITIONS = ( "POD_CONFIGURATION_DEBUG=1", @@ -1202,19 +1217,57 @@ GCC_WARN_UNUSED_VARIABLE = YES; MACOSX_DEPLOYMENT_TARGET = 10.10; ONLY_ACTIVE_ARCH = YES; + PROVISIONING_PROFILE_SPECIFIER = NO_SIGNING/; STRIP_INSTALLED_PRODUCT = NO; SYMROOT = "${SRCROOT}/../build"; }; name = Debug; }; + F99E76EFC4D507D937E3B30FC763860F /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = F67191B1F87DA238C4D87250DFBE43DD /* Pods-ShadowsocksX-NGTests.release.xcconfig */; + buildSettings = { + CODE_SIGN_IDENTITY = ""; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; + COMBINE_HIDPI_IMAGES = YES; + CURRENT_PROJECT_VERSION = 1; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + ENABLE_STRICT_OBJC_MSGSEND = YES; + FRAMEWORK_VERSION = A; + GCC_NO_COMMON_BLOCKS = YES; + INFOPLIST_FILE = "Target Support Files/Pods-ShadowsocksX-NGTests/Info.plist"; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; + MACH_O_TYPE = staticlib; + MACOSX_DEPLOYMENT_TARGET = 10.10; + MODULEMAP_FILE = "Target Support Files/Pods-ShadowsocksX-NGTests/Pods-ShadowsocksX-NGTests.modulemap"; + MTL_ENABLE_DEBUG_INFO = NO; + OTHER_LDFLAGS = ""; + OTHER_LIBTOOLFLAGS = ""; + PODS_ROOT = "$(SRCROOT)"; + PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; + PRODUCT_NAME = Pods_ShadowsocksX_NGTests; + SDKROOT = macosx; + SKIP_INSTALL = YES; + VERSIONING_SYSTEM = "apple-generic"; + VERSION_INFO_PREFIX = ""; + }; + name = Release; + }; /* End XCBuildConfiguration section */ /* Begin XCConfigurationList section */ 0174BA27A62F6F29EEDC03CA3FB0A9C4 /* Build configuration list for PBXNativeTarget "BRLOptionParser" */ = { isa = XCConfigurationList; buildConfigurations = ( - 92B477579DE5EFCC17E358B57A3A599E /* Debug */, - B9E2E17CACCD9DB6ACE1EE1508A63590 /* Release */, + 94F5075F5C6F147122E5F274E23FCC42 /* Debug */, + F1ACFFB424C32AEE0367EC6DA3C73FD9 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; @@ -1222,8 +1275,8 @@ 16ED0890B237DF1B16DA47D0E14DB4DD /* Build configuration list for PBXNativeTarget "GCDWebServer" */ = { isa = XCConfigurationList; buildConfigurations = ( - 94D9BC00EEB34DA6CE7149B77BCFB946 /* Debug */, - 9B688665FDF44A7A81FB65791A544010 /* Release */, + 09CCD18A4DD4E0090FA47F079FC15C1F /* Debug */, + DBED2E7186D3EE230AACEE213E81582D /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; @@ -1231,8 +1284,8 @@ 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */ = { isa = XCConfigurationList; buildConfigurations = ( - DA2E206EB90DF75A25332AE4AA713F31 /* Debug */, - 4888EEFBEA04FABA2120470F4B676BBD /* Release */, + F653E316AB5F825D3AD0CAE700E37071 /* Debug */, + 9420A7205B8F85520AF134F4EE25F7CC /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; @@ -1240,8 +1293,8 @@ 3CFB42910790CF0BDBCCEBAACD6B9367 /* Build configuration list for PBXNativeTarget "Alamofire" */ = { isa = XCConfigurationList; buildConfigurations = ( - 82B1EC5E8815E78991717D970C44B8D8 /* Debug */, - 81B3096945D568104AC14EE4F805950B /* Release */, + EF056C7261651C7FA8BAEBC28385AA03 /* Debug */, + 8346802FCF028CDB890A5034737BEA3E /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; @@ -1249,8 +1302,8 @@ 4AC88E06DEFEEDAF5DAA6F0F774D05D4 /* Build configuration list for PBXNativeTarget "Pods-ShadowsocksX-NG" */ = { isa = XCConfigurationList; buildConfigurations = ( - CD7B15AF2FF01E3412E8AA0B13161458 /* Debug */, - 4F1BC9CB0D8B1AB0DE3307D170A516B0 /* Release */, + C98675A06B6AE6B2E23238062710F460 /* Debug */, + 679D13C7B23A28C7343E08D4EF371384 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; @@ -1258,8 +1311,8 @@ 757EEB566CE14B3A8210DD4A32EBDD7A /* Build configuration list for PBXNativeTarget "Pods-ShadowsocksX-NGTests" */ = { isa = XCConfigurationList; buildConfigurations = ( - 371E0500757286AB22CAE64ADAE8D83B /* Debug */, - 8A2A1FB2B9F55A664E92C5F52B674F7B /* Release */, + E993D4A1EFC27F876EC40C44A15ACB83 /* Debug */, + F99E76EFC4D507D937E3B30FC763860F /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; @@ -1267,8 +1320,8 @@ F1E46DE142216CD3C0327D20F3073961 /* Build configuration list for PBXNativeTarget "Pods-proxy_conf_helper" */ = { isa = XCConfigurationList; buildConfigurations = ( - 4F25746D417AD7959CEFE5D13B9045BF /* Debug */, - 9825B7CD16B076B290073DADEE5E3AEE /* Release */, + 031770946E17E5080E7C1973521ED6BC /* Debug */, + 00F75142B9A3AA9BA979B71D2C404698 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; diff --git a/Pods/Target Support Files/Alamofire/Info.plist b/Pods/Target Support Files/Alamofire/Info.plist index ebdce25..078bbf3 100644 --- a/Pods/Target Support Files/Alamofire/Info.plist +++ b/Pods/Target Support Files/Alamofire/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 3.4.0 + 3.5.0 CFBundleSignature ???? CFBundleVersion diff --git a/Pods/Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG-acknowledgements.plist b/Pods/Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG-acknowledgements.plist index 4293969..fb52059 100644 --- a/Pods/Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG-acknowledgements.plist +++ b/Pods/Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG-acknowledgements.plist @@ -34,6 +34,8 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + License + MIT Title Alamofire Type @@ -66,6 +68,8 @@ ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + License + BSD Title GCDWebServer Type diff --git a/Pods/Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG.debug.xcconfig b/Pods/Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG.debug.xcconfig index d9b9254..48b961a 100644 --- a/Pods/Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG.debug.xcconfig +++ b/Pods/Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG.debug.xcconfig @@ -1,3 +1,4 @@ +ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES CODE_SIGN_IDENTITY = EMBEDDED_CONTENT_CONTAINS_SWIFT = YES FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/Alamofire" "$PODS_CONFIGURATION_BUILD_DIR/GCDWebServer" diff --git a/Pods/Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG.release.xcconfig b/Pods/Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG.release.xcconfig index d9b9254..48b961a 100644 --- a/Pods/Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG.release.xcconfig +++ b/Pods/Target Support Files/Pods-ShadowsocksX-NG/Pods-ShadowsocksX-NG.release.xcconfig @@ -1,3 +1,4 @@ +ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES CODE_SIGN_IDENTITY = EMBEDDED_CONTENT_CONTAINS_SWIFT = YES FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/Alamofire" "$PODS_CONFIGURATION_BUILD_DIR/GCDWebServer" diff --git a/Pods/Target Support Files/Pods-ShadowsocksX-NGTests/Pods-ShadowsocksX-NGTests.debug.xcconfig b/Pods/Target Support Files/Pods-ShadowsocksX-NGTests/Pods-ShadowsocksX-NGTests.debug.xcconfig index 179df76..e16baf7 100644 --- a/Pods/Target Support Files/Pods-ShadowsocksX-NGTests/Pods-ShadowsocksX-NGTests.debug.xcconfig +++ b/Pods/Target Support Files/Pods-ShadowsocksX-NGTests/Pods-ShadowsocksX-NGTests.debug.xcconfig @@ -1,3 +1,4 @@ +ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = NO CODE_SIGN_IDENTITY = FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/Alamofire" "$PODS_CONFIGURATION_BUILD_DIR/GCDWebServer" GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 diff --git a/Pods/Target Support Files/Pods-ShadowsocksX-NGTests/Pods-ShadowsocksX-NGTests.release.xcconfig b/Pods/Target Support Files/Pods-ShadowsocksX-NGTests/Pods-ShadowsocksX-NGTests.release.xcconfig index 179df76..e16baf7 100644 --- a/Pods/Target Support Files/Pods-ShadowsocksX-NGTests/Pods-ShadowsocksX-NGTests.release.xcconfig +++ b/Pods/Target Support Files/Pods-ShadowsocksX-NGTests/Pods-ShadowsocksX-NGTests.release.xcconfig @@ -1,3 +1,4 @@ +ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = NO CODE_SIGN_IDENTITY = FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/Alamofire" "$PODS_CONFIGURATION_BUILD_DIR/GCDWebServer" GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 diff --git a/Pods/Target Support Files/Pods-proxy_conf_helper/Pods-proxy_conf_helper-acknowledgements.plist b/Pods/Target Support Files/Pods-proxy_conf_helper/Pods-proxy_conf_helper-acknowledgements.plist index 42b0d2c..05c3abf 100644 --- a/Pods/Target Support Files/Pods-proxy_conf_helper/Pods-proxy_conf_helper-acknowledgements.plist +++ b/Pods/Target Support Files/Pods-proxy_conf_helper/Pods-proxy_conf_helper-acknowledgements.plist @@ -37,6 +37,8 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + License + MIT Title BRLOptionParser Type diff --git a/Pods/Target Support Files/Pods-proxy_conf_helper/Pods-proxy_conf_helper.debug.xcconfig b/Pods/Target Support Files/Pods-proxy_conf_helper/Pods-proxy_conf_helper.debug.xcconfig index 7a9c2fa..bb1eaa0 100644 --- a/Pods/Target Support Files/Pods-proxy_conf_helper/Pods-proxy_conf_helper.debug.xcconfig +++ b/Pods/Target Support Files/Pods-proxy_conf_helper/Pods-proxy_conf_helper.debug.xcconfig @@ -1,3 +1,4 @@ +ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = NO GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/BRLOptionParser" LIBRARY_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/BRLOptionParser" diff --git a/Pods/Target Support Files/Pods-proxy_conf_helper/Pods-proxy_conf_helper.release.xcconfig b/Pods/Target Support Files/Pods-proxy_conf_helper/Pods-proxy_conf_helper.release.xcconfig index 7a9c2fa..bb1eaa0 100644 --- a/Pods/Target Support Files/Pods-proxy_conf_helper/Pods-proxy_conf_helper.release.xcconfig +++ b/Pods/Target Support Files/Pods-proxy_conf_helper/Pods-proxy_conf_helper.release.xcconfig @@ -1,3 +1,4 @@ +ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = NO GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/BRLOptionParser" LIBRARY_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/BRLOptionParser" diff --git a/ShadowsocksX-NG.xcodeproj/project.pbxproj b/ShadowsocksX-NG.xcodeproj/project.pbxproj index 8a3b965..a2e6a83 100644 --- a/ShadowsocksX-NG.xcodeproj/project.pbxproj +++ b/ShadowsocksX-NG.xcodeproj/project.pbxproj @@ -558,7 +558,7 @@ ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n"; + shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n"; showEnvVarsInLog = 0; }; 3545247EFCD033C3FA63EA6C /* [CP] Check Pods Manifest.lock */ = { @@ -573,7 +573,7 @@ ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n"; + shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n"; showEnvVarsInLog = 0; }; 3E819BD46B855EDB116A3C70 /* [CP] Copy Pods Resources */ = { @@ -633,7 +633,7 @@ ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n"; + shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n"; showEnvVarsInLog = 0; }; D8C2D6AF002916F4095E15E3 /* [CP] Copy Pods Resources */ = { @@ -880,6 +880,7 @@ PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_OBJC_BRIDGING_HEADER = "ShadowsocksX-NG/ShadowsocksX-NG-Bridging-Header.h"; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 2.3; }; name = Debug; }; @@ -907,6 +908,7 @@ PRODUCT_BUNDLE_IDENTIFIER = "com.qiuyuzhou.ShadowsocksX-NG"; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_OBJC_BRIDGING_HEADER = "ShadowsocksX-NG/ShadowsocksX-NG-Bridging-Header.h"; + SWIFT_VERSION = 2.3; }; name = Release; }; diff --git a/ShadowsocksX-NG.xcodeproj/xcshareddata/xcschemes/ShadowsocksX-NG.xcscheme b/ShadowsocksX-NG.xcodeproj/xcshareddata/xcschemes/ShadowsocksX-NG.xcscheme index 19af2fe..a298114 100644 --- a/ShadowsocksX-NG.xcodeproj/xcshareddata/xcschemes/ShadowsocksX-NG.xcscheme +++ b/ShadowsocksX-NG.xcodeproj/xcshareddata/xcschemes/ShadowsocksX-NG.xcscheme @@ -1,6 +1,6 @@