<commit_before>Change Log
==========

Version 3.5.0 *(12th September, 2016)*
-------------------------------------

 * [New](https://github.com/segmentio/analytics-ios/pull/592): Adds a `SEGCrypto` API that can be used to configure the at rest encryption strategy for the client.

 ```objc
 SEGAnalyticsConfiguration *configuration = [SEGAnalyticsConfiguration configurationWithWriteKey:@"YOUR_WRITE_KEY"];

 // Set a custom crypto implementation. An AES-256 implementation is provided out of the box.
 configuration.crypto = [SEGAES256Crypto initWithPassword:"<PASSWORD>"];

 // Set any other custom configuration options.
 ...

 // Initialize the SDK with the configuration.
 [SEGAnalytics setupWithConfiguration:configuration]
 ```

 * [New](https://github.com/segmentio/analytics-ios/commit/0c646e1c44df4134a984f1fcb741f5b1d418ab30): Add the ability for the SDK to natively report attribution information via Segment integrations enabled for your project, without needing to bundle their SDKs. Attribution information is sent as a track call as documented in the [mobile lifecycle spec](https://segment.com/docs/spec/mobile/#install-attributed).

 ```objc
 SEGAnalyticsConfiguration *configuration = [SEGAnalyticsConfiguration configurationWithWriteKey:@"YOUR_WRITE_KEY"];

 // Enable attribution tracking.
 configuration.trackAttributionData = @YES;

 // Set any other custom configuration options.
 ...

 // Initialize the SDK with the configuration.
 [SEGAnalytics setupWithConfiguration:configuration]
 ```

 * [New](https://github.com/segmentio/analytics-ios/pull/597): Add the ability for the SDK to disable bluetooth collection. Going forwards, bluetooth information will **not** be collected by default. This is because iOS 10 requires [explicit documentation](https://developer.apple.com/library/prerelease/content/releasenotes/General/WhatsNewIniOS/Articles/iOS10.html) on why the CoreBluetooth APIs are accessed. If you enable this flag, your app's Info.plist must contain an [`NSBluetoothPeripheralUsageDescription` key](https://developer.apple.com/library/ios/documentation/General/Reference/InfoPlistKeyReference/Articles/CocoaKeys.html#//apple_ref/doc/uid/TP40009251-SW20) with a string value explaining to the user how the app uses this data. On this note, you should do the same for [`NSLocationAlwaysUsageDescription`](https://developer.apple.com/library/ios/documentation/General/Reference/InfoPlistKeyReference/Articles/CocoaKeys.html#//apple_ref/doc/uid/TP40009251-SW18) if you have `shouldUseLocationServices` set to `@YES`.

 ```objc
 SEGAnalyticsConfiguration *configuration = [SEGAnalyticsConfiguration configurationWithWriteKey:@"YOUR_WRITE_KEY"];

 // Enable bluetooth collection.
 configuration.shouldUseBluetooth = @YES;

 // Set any other custom configuration options.
 ...

 // Initialize the SDK with the configuration.
 [SEGAnalytics setupWithConfiguration:configuration]
 ```

Version 3.4.0 *(1st September, 2016)*
-------------------------------------

 * [New](https://github.com/segmentio/analytics-ios/commit/d5db28ab9d15aa06b4e3a5c91f813d5c12a419a8): Adds a `SEGRequestFactory` API that can be used to configure the HTTP requests made by Segment.

 ```objc
 SEGAnalyticsConfiguration *configuration = [SEGAnalyticsConfiguration configurationWithWriteKey:@"YOUR_WRITE_KEY"];

 // Set a custom request factory which allows you to modify the way the library creates an HTTP request.
 // In this case, we're transforming the URL to point to our own custom non-Segment host.
 configuration.requestFactory = ^(NSURL *url) {<commit_msg>update changelog with note about why users should/should not upgrade<commit_after>Change Log
==========

Version 3.5.0 *(12th September, 2016)*
-------------------------------------

 * [New](https://github.com/segmentio/analytics-ios/pull/592): Adds a `SEGCrypto` API that can be used to configure the at rest encryption strategy for the client.

 ```objc
 SEGAnalyticsConfiguration *configuration = [SEGAnalyticsConfiguration configurationWithWriteKey:@"YOUR_WRITE_KEY"];

 // Set a custom crypto implementation. An AES-256 implementation is provided out of the box.
 configuration.crypto = [SEGAES256Crypto initWithPassword:"<PASSWORD>"];

 // Set any other custom configuration options.
 ...

 // Initialize the SDK with the configuration.
 [SEGAnalytics setupWithConfiguration:configuration]
 ```

 * [New](https://github.com/segmentio/analytics-ios/commit/0c646e1c44df4134a984f1fcb741f5b1d418ab30): Add the ability for the SDK to natively report attribution information via Segment integrations enabled for your project, without needing to bundle their SDKs. Attribution information is sent as a track call as documented in the [mobile lifecycle spec](https://segment.com/docs/spec/mobile/#install-attributed).

 ```objc
 SEGAnalyticsConfiguration *configuration = [SEGAnalyticsConfiguration configurationWithWriteKey:@"YOUR_WRITE_KEY"];

 // Enable attribution tracking.
 configuration.trackAttributionData = @YES;

 // Set any other custom configuration options.
 ...

 // Initialize the SDK with the configuration.
 [SEGAnalytics setupWithConfiguration:configuration]
 ```

 * [New](https://github.com/segmentio/analytics-ios/pull/597): Add the ability for the SDK to disable bluetooth collection. Going forwards, bluetooth information will **not** be collected by default. This is because iOS 10 requires [explicit documentation](https://developer.apple.com/library/prerelease/content/releasenotes/General/WhatsNewIniOS/Articles/iOS10.html) on why the CoreBluetooth APIs are accessed. If you enable this flag, your app's Info.plist must contain an [`NSBluetoothPeripheralUsageDescription` key](https://developer.apple.com/library/ios/documentation/General/Reference/InfoPlistKeyReference/Articles/CocoaKeys.html#//apple_ref/doc/uid/TP40009251-SW20) with a string value explaining to the user how the app uses this data. On this note, you should do the same for [`NSLocationAlwaysUsageDescription`](https://developer.apple.com/library/ios/documentation/General/Reference/InfoPlistKeyReference/Articles/CocoaKeys.html#//apple_ref/doc/uid/TP40009251-SW18) if you have `shouldUseLocationServices` set to `@YES`. If you are linking against iOS 10, you'll want to update to this version to prevent your app submission from being rejected (or provide `NSBluetoothPeripheralUsageDescription` and/or `NSLocationAlwaysUsageDescription` descriptions in your app's Info.plist).

 ```objc
 SEGAnalyticsConfiguration *configuration = [SEGAnalyticsConfiguration configurationWithWriteKey:@"YOUR_WRITE_KEY"];

 // Enable bluetooth collection.
 configuration.shouldUseBluetooth = @YES;

 // Set any other custom configuration options.
 ...

 // Initialize the SDK with the configuration.
 [SEGAnalytics setupWithConfiguration:configuration]
 ```

Version 3.4.0 *(1st September, 2016)*
-------------------------------------

 * [New](https://github.com/segmentio/analytics-ios/commit/d5db28ab9d15aa06b4e3a5c91f813d5c12a419a8): Adds a `SEGRequestFactory` API that can be used to configure the HTTP requests made by Segment.

 ```objc
 SEGAnalyticsConfiguration *configuration = [SEGAnalyticsConfiguration configurationWithWriteKey:@"YOUR_WRITE_KEY"];

 // Set a custom request factory which allows you to modify the way the library creates an HTTP request.
 // In this case, we're transforming the URL to point to our own custom non-Segment host.
 configuration.requestFactory = ^(NSURL *url) {
{'fraction_non_alphanumeric': 0.11251173394126324, 'fraction_numerical': 0.02735684591658844, 'mean_word_length': 4.900316455696203, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 16, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6288493', 'n_tokens_mistral': 2157, 'n_tokens_neox': 1934, 'n_words': 627}