2
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

AWS SNS APNSの証明書の有効期限を確認する方法

Posted at

エラー表示

有効期限が切れていると下記のようなエラーがでます。

Platform application is disabled

リファレンス

https://docs.aws.amazon.com/sns/latest/api/API_GetPlatformApplicationAttributes.html
https://docs.aws.amazon.com/cli/latest/reference/sns/get-platform-application-attributes.html

aws cli で実行してみる

$ aws sns get-platform-application-attributes --platform-application-arn {確認したいSNSのarn}
$ aws sns get-platform-application-attributes --platform-application-arn arn:aws:sns:ap-northeast-1:0123456789:app/APNS/hogehoge
{
    "Attributes": {
        "SuccessFeedbackSampleRate": "100",
        "EventDeliveryFailure": "arn:aws:sns:ap-northeast-1:0123456789:hogehoge-disabled",
        "SuccessFeedbackRoleArn": "arn:aws:iam::0123456789:role/SNSSuccessFeedback",
        "Enabled": "false",
        "AppleCertificateExpirationDate": "2017-12-01T00:21:01Z",
        "FailureFeedbackRoleArn": "arn:aws:iam::0123456789:role/SNSFailureFeedback",
        "EventEndpointUpdated": "arn:aws:sns:ap-northeast-1:0123456789:hogehoge-disabled"
    }
}

AppleCertificateExpirationDate というキーが有効期限ですね

2
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?