Skip to content

Commit b599153

Browse files
committed
bump version
1 parent 248cd43 commit b599153

File tree

3 files changed

+34
-24
lines changed

3 files changed

+34
-24
lines changed

Diff for: CHANGELOG.md

+3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# I am terrible at keeping this up-to-date.
22

3+
## 1.14.0 (2021-07-28)
4+
bug: accept all VAPID key instances (thanks @mthu)
5+
36
## 1.13.0 (2021-03-15)
47
Support requests_session param in webpush fn too
58

Diff for: README.md

+30-23
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,10 @@ and push data.
3232
As illustration, a `subscription_info` object may look like:
3333

3434
```json
35-
{"endpoint": "https://updates.push.services.mozilla.com/push/v1/gAA...", "keys": {"auth": "k8J...", "p256dh": "BOr..."}}
35+
{
36+
"endpoint": "https://updates.push.services.mozilla.com/push/v1/gAA...",
37+
"keys": { "auth": "k8J...", "p256dh": "BOr..." }
38+
}
3639
```
3740

3841
How you send the PushSubscription data to your backend, store it
@@ -60,19 +63,19 @@ in the `subscription_info` block.
6063

6164
**Parameters**
6265

63-
*subscription_info* - The `dict` of the subscription info (described above).
66+
_subscription_info_ - The `dict` of the subscription info (described above).
6467

65-
*data* - can be any serial content (string, bit array, serialized JSON, etc), but be sure that your receiving
68+
_data_ - can be any serial content (string, bit array, serialized JSON, etc), but be sure that your receiving
6669
application is able to parse and understand it. (e.g. `data = "Mary had a little lamb."`)
6770

68-
*content_type* - specifies the form of Encryption to use, either `'aes128gcm'` or the deprecated `'aesgcm'`. NOTE that
71+
_content_type_ - specifies the form of Encryption to use, either `'aes128gcm'` or the deprecated `'aesgcm'`. NOTE that
6972
not all User Agents can decrypt `'aesgcm'`, so the library defaults to the RFC 8188 standard form.
7073

71-
*vapid_claims* - a `dict` containing the VAPID claims required for authorization (See
74+
_vapid_claims_ - a `dict` containing the VAPID claims required for authorization (See
7275
[py_vapid](https://github.com/web-push-libs/vapid/tree/master/python) for more details). If `aud` is not specified,
7376
pywebpush will attempt to auto-fill from the `endpoint`.
7477

75-
*vapid_private_key* - Either a path to a VAPID EC2 private key PEM file, or a string containing the DER representation.
78+
_vapid_private_key_ - Either a path to a VAPID EC2 private key PEM file, or a string containing the DER representation.
7679
(See [py_vapid](https://github.com/web-push-libs/vapid/tree/master/python) for more details.) The `private_key` may be
7780
a base64 encoded DER formatted private key, or the path to an OpenSSL exported private key file.
7881

@@ -126,23 +129,23 @@ Send the data using additional parameters. On error, returns a `WebPushException
126129

127130
**Parameters**
128131

129-
*data* Binary string of data to send
132+
_data_ Binary string of data to send
130133

131-
*headers* A `dict` containing any additional headers to send
134+
_headers_ A `dict` containing any additional headers to send
132135

133-
*ttl* Message Time To Live on Push Server waiting for the client to reconnect (in seconds)
136+
_ttl_ Message Time To Live on Push Server waiting for the client to reconnect (in seconds)
134137

135-
*gcm_key* Google Cloud Messaging key (if using the older GCM push system) This is the API key obtained from the Google
138+
_gcm_key_ Google Cloud Messaging key (if using the older GCM push system) This is the API key obtained from the Google
136139
Developer Console.
137140

138-
*reg_id* Google Cloud Messaging registration ID (will be extracted from endpoint if not specified)
141+
_reg_id_ Google Cloud Messaging registration ID (will be extracted from endpoint if not specified)
139142

140-
*content_encoding* ECE content encoding type (defaults to "aes128gcm")
143+
_content_encoding_ ECE content encoding type (defaults to "aes128gcm")
141144

142-
*curl* Do not execute the POST, but return as a `curl` command. This will write the encrypted content to a local file
145+
_curl_ Do not execute the POST, but return as a `curl` command. This will write the encrypted content to a local file
143146
named `encrpypted.data`. This command is meant to be used for debugging purposes.
144147

145-
*timeout* timeout for requests POST query.
148+
_timeout_ timeout for requests POST query.
146149
See [requests documentation](http://docs.python-requests.org/en/master/user/quickstart/#timeouts).
147150

148151
**Example**
@@ -159,9 +162,9 @@ Encode the `data` for future use. On error, returns a `WebPushException`
159162

160163
**Parameters**
161164

162-
*data* Binary string of data to send
165+
_data_ Binary string of data to send
163166

164-
*content_encoding* ECE content encoding type (defaults to "aes128gcm")
167+
_content_encoding_ ECE content encoding type (defaults to "aes128gcm")
165168

166169
**Example**
167170

@@ -175,22 +178,26 @@ If you're not really into coding your own solution, there's also a "stand-alone"
175178
./bin directory.
176179

177180
This uses two files:
178-
* the *data* file, which contains the message to send, in whatever form you like.
179-
* the *subscription info* file, which contains the subscription information as JSON encoded data. This is usually returned by the Push `subscribe` method and looks something like:
181+
182+
- the _data_ file, which contains the message to send, in whatever form you like.
183+
- the _subscription info_ file, which contains the subscription information as JSON encoded data. This is usually returned by the Push `subscribe` method and looks something like:
180184

181185
```json
182-
{"endpoint": "https://push...",
183-
"keys": {
184-
"auth": "ab01...",
185-
"p256dh": "aa02..."
186-
}}
186+
{
187+
"endpoint": "https://push...",
188+
"keys": {
189+
"auth": "ab01...",
190+
"p256dh": "aa02..."
191+
}
192+
}
187193
```
188194

189195
If you're interested in just testing your applications WebPush interface, you could use the Command Line:
190196

191197
```bash
192198
./bin/pywebpush --data stuff_to_send.data --info subscription.info
193199
```
200+
194201
which will encrypt and send the contents of `stuff_to_send.data`.
195202

196203
See `./bin/pywebpush --help` for available commands and options.

Diff for: setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
from setuptools import find_packages, setup
55

66

7-
__version__ = "1.13.0"
7+
__version__ = "1.14.0"
88

99

1010
def read_from(file):

0 commit comments

Comments
 (0)