Ad

Safari Push Notifications - Verifying Hashes In Manifest.json Failed Even Though Correct

- 1 answer

I have created a push package with the appropriate files as per the Apple spec for APNS. This manifest file represents all of the files that are present:

{
    "icon.iconset/icon_128x128.png": "78609fcff69688f969a38f957ac2f10fc79d6732",
    "icon.iconset/[email protected]": "78609fcff69688f969a38f957ac2f10fc79d6732",
    "icon.iconset/icon_16x16.png": "d348589e2cf37d8f23940f8545afe75a2e98b4ac",
    "icon.iconset/[email protected]": "d348589e2cf37d8f23940f8545afe75a2e98b4ac",
    "icon.iconset/icon_32x32.png": "e4418a1c5f2ecfbb702961515aaa65d5449b1c53",
    "icon.iconset/[email protected]": "e4418a1c5f2ecfbb702961515aaa65d5449b1c53",
    "website.json": "45be9c4a6f1bf96e27a9eecab219304b35c5ac24"
}

I have manually checked the sha1 values on the CLI and they are all correct, along with the file locations. And yet I still get this error back from Safari each time I try to get permission:

{ '{"logs":': { '"Verifying hashes in manifest.json failed"]': '' } }

Which is not valid JSON either. Any ideas why this would be failing?

Ad

Answer

I recently implemented push notifications through pushwoosh. They automatically created the package for me and I checked how they done it. The only difference between mine manifest file and your is a back slash before the normal slash. Maybe it could do the difference for you. Copy and paste this code in your manifest (I have already added your SHA1 values):

{"icon.iconset\/icon_16x16.png":"d348589e2cf37d8f23940f8545afe75a2e98b4ac","icon.iconset\/[email protected]":"d348589e2cf37d8f23940f8545afe75a2e98b4ac","icon.iconset\/icon_32x32.png":"e4418a1c5f2ecfbb702961515aaa65d5449b1c53","icon.iconset\/[email protected]":"e4418a1c5f2ecfbb702961515aaa65d5449b1c53","icon.iconset\/icon_128x128.png":"78609fcff69688f969a38f957ac2f10fc79d6732","icon.iconset\/[email protected]":"78609fcff69688f969a38f957ac2f10fc79d6732","website.json":"45be9c4a6f1bf96e27a9eecab219304b35c5ac24"}
Ad
source: stackoverflow.com
Ad