Skip to content
This repository has been archived by the owner on Jul 13, 2023. It is now read-only.

Web Push: Empty messages don't need crypto headers #132

Closed
ghost opened this issue Aug 17, 2015 · 2 comments
Closed

Web Push: Empty messages don't need crypto headers #132

ghost opened this issue Aug 17, 2015 · 2 comments

Comments

@ghost
Copy link

ghost commented Aug 17, 2015

IIRC, it's okay to omit the Content-Encoding and Encryption headers for push messages without a body. The DOM API can distinguish these from empty encrypted messages: pushEvent.data === null for the former; pushEvent.data.text() === "" for the latter.

@ghost ghost changed the title Empty messages don't need crypto headers Web Push: Empty messages don't need crypto headers Aug 17, 2015
@ghost
Copy link
Author

ghost commented Aug 18, 2015

Though, now that I look at the latest spec, I see pushEvent.data is required.

ghost pushed a commit that referenced this issue Aug 19, 2015
@ghost
Copy link
Author

ghost commented Aug 21, 2015

From IRC:

15:40 — mt kitcambridge, benbangert: re: encryption, the idea is that a push without any data would be fine, but we would return no data object. An empty message is different, it should include an authentication tag then.

Sounds like the distinction is still relevant, and the spec should be updated accordingly.

ghost pushed a commit that referenced this issue Aug 24, 2015
ghost pushed a commit that referenced this issue Aug 25, 2015
ghost pushed a commit that referenced this issue Aug 25, 2015
ghost pushed a commit that referenced this issue Aug 25, 2015
ghost pushed a commit that referenced this issue Aug 25, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

0 participants