Skip to content

Release 10.1.6 #445

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 20, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [10.1.6](https://github.com/pusher/pusher-websocket-swift/compare/10.1.5...10.1.6) - 2025-06-20

### Fixed

- Upgrade NWWebSocket library to version 0.5.7 to fix reported crashes due to data race.

## [10.1.3](https://github.com/pusher/pusher-websocket-swift/compare/10.1.2...10.1.3) - 2023-05-19

### Fixed
Expand Down
2 changes: 1 addition & 1 deletion PusherSwift.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'PusherSwift'
s.version = '10.1.5'
s.version = '10.1.6'
s.summary = 'A Pusher client library in Swift'
s.homepage = 'https://github.com/pusher/pusher-websocket-swift'
s.license = 'MIT'
Expand Down
2 changes: 1 addition & 1 deletion PusherSwiftWithEncryption.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'PusherSwiftWithEncryption'
s.version = '10.1.5'
s.version = '10.1.6'
s.summary = 'A Pusher client library in Swift that supports encrypted channels'
s.homepage = 'https://github.com/pusher/pusher-websocket-swift'
s.license = 'MIT'
Expand Down
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '10.0'
use_frameworks!

pod 'PusherSwift', '~> 10.1.0'
pod 'PusherSwift', '~> 10.1.6'
```

Then, run the following command:
Expand Down Expand Up @@ -150,7 +150,7 @@ let package = Package(
targets: ["YourPackage"]),
],
dependencies: [
.package(url: "https://github.com/pusher/pusher-websocket-swift.git", from: "10.1.0"),
.package(url: "https://github.com/pusher/pusher-websocket-swift.git", from: "10.1.6"),
],
targets: [
.target(
Expand Down Expand Up @@ -609,7 +609,7 @@ PusherChannel *myChannel = [pusher subscribeWithChannelName:@"my-channel"];

This returns PusherChannel object, which events can be bound to.

For non-presence channels, you can also provide a function that will be called when a client either subscribes or unsubscribes to a channel with the number of subscribers as a parameter. Also, this function is available as a parameter to `subscribe` function.
For non-presence channels, you can also provide a function that will be called when a client either subscribes or unsubscribes to a channel with the number of subscribers as a parameter. Also, this function is available as a parameter to `subscribe` function.

```swift
let onSubscriptionCountChanged = { (count: Int) in
Expand Down Expand Up @@ -644,9 +644,9 @@ Subscribing to private channels involves the client being authenticated. See the

Similar to Private channels, you can also subscribe to a [private encrypted channel](https://pusher.com/docs/channels/using_channels/encrypted-channels). This library now fully supports end-to-end encryption. This means that only you and your connected clients will be able to read your messages. Pusher cannot decrypt them.

Like with private channels, you must provide an authentication endpoint. That endpoint must be using a [server client that supports end-to-end encryption](https://pusher.com/docs/channels/using_channels/encrypted-channels#server). There is a [demonstration endpoint to look at using nodejs](https://github.com/pusher/pusher-channels-auth-example#using-e2e-encryption).
Like with private channels, you must provide an authentication endpoint. That endpoint must be using a [server client that supports end-to-end encryption](https://pusher.com/docs/channels/using_channels/encrypted-channels#server). There is a [demonstration endpoint to look at using nodejs](https://github.com/pusher/pusher-channels-auth-example#using-e2e-encryption).

The shared secret used to decrypt events is loaded from the same auth endpoint request that is used to authorize your subscription. There is also a mechanism for reloading the shared secret if your encryption master key changes. If an event is encountered that cannot be decrypted, a request is made to your auth endpoint to attempt to load the new shared secret. If that request fails or if the returned secret still cannot decrypt the event then that event will be skipped, the `failedToDecryptEvent` connection delegate function will be called, and the next received event will be processed.
The shared secret used to decrypt events is loaded from the same auth endpoint request that is used to authorize your subscription. There is also a mechanism for reloading the shared secret if your encryption master key changes. If an event is encountered that cannot be decrypted, a request is made to your auth endpoint to attempt to load the new shared secret. If that request fails or if the returned secret still cannot decrypt the event then that event will be skipped, the `failedToDecryptEvent` connection delegate function will be called, and the next received event will be processed.

Because of the requirement to reload the shared secret on demand, you can only use the following [auth methods](#configuration): `endpoint`, `authRequestBuilder`, `authorizer`. It is not possible to pass an instance of `PusherAuth` to the `subscribe` function if you are subscribing to an encrypted channel.

Expand Down Expand Up @@ -833,7 +833,7 @@ Events can be bound to at 2 levels; globally and per channel. When binding to an

### Per-channel events

These are bound to a specific channel, and mean that you can reuse event names in different parts of your client application.
These are bound to a specific channel, and mean that you can reuse event names in different parts of your client application.

#### Swift

Expand Down Expand Up @@ -894,7 +894,7 @@ PusherChannel *chan = [pusher subscribeWithChannelName:@"my-channel"];

### Global events

You can attach behavior to these events regardless of the channel the event is broadcast to.
You can attach behavior to these events regardless of the channel the event is broadcast to.

#### Swift

Expand Down Expand Up @@ -1005,7 +1005,7 @@ myChannel.bind(eventName: "price-update", eventCallback: { (event: PusherEvent)

```

Alternatively, you could use [`JSONSerialization`](https://developer.apple.com/documentation/foundation/jsonserialization) to decode the JSON into Swift data types:
Alternatively, you could use [`JSONSerialization`](https://developer.apple.com/documentation/foundation/jsonserialization) to decode the JSON into Swift data types:

#### Swift

Expand Down Expand Up @@ -1073,7 +1073,7 @@ pusher.bind({ (message: Any?) in
```

#### Objective-C

```objc
[pusher bind:^void (NSDictionary *data) {
NSString *eventName = data[@"event"];
Expand Down
2 changes: 1 addition & 1 deletion Sources/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>10.1.5</string>
<string>10.1.6</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
Expand Down
2 changes: 1 addition & 1 deletion Sources/PusherSwift.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import Foundation
import NWWebSocket

let PROTOCOL = 7
let VERSION = "10.1.5"
let VERSION = "10.1.6"
// swiftlint:disable:next identifier_name
let CLIENT_NAME = "pusher-websocket-swift"

Expand Down
2 changes: 1 addition & 1 deletion Tests/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>BNDL</string>
<key>CFBundleShortVersionString</key>
<string>10.1.5</string>
<string>10.1.6</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
Expand Down
2 changes: 1 addition & 1 deletion Tests/Integration/PusherClientInitializationTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import XCTest

@testable import PusherSwift

let VERSION = "10.1.5"
let VERSION = "10.1.6"

class ClientInitializationTests: XCTestCase {
private var key: String!
Expand Down
Loading