aws / aws-sdk-php

Official repository of the AWS SDK for PHP (@awsforphp)
http://aws.amazon.com/sdkforphp
Apache License 2.0
6k stars 1.21k forks source link

Legacy references to Message and MessageValidator classes in SDK documentation #2027

Open j13k opened 4 years ago

j13k commented 4 years ago

As of May 2020, the SDK documentation still indicates that the Message and MessageValidator classes are available in the main library, when according to issue #625 these classes were migrated to an auxilliary library in 2015.

https://docs.aws.amazon.com/aws-sdk-php/v3/api/namespace-Aws.Sns.html

Namespace_Aws_Sns___AWS_SDK_for_PHP_3_x

I'm presuming the documentation is auto-generated, but it's not clear when it was last updated.

For what it's worth, the main SNS docs also indicate this:

https://docs.aws.amazon.com/sns/latest/dg/sns-verify-signature-of-message.html

image

diehlaws commented 4 years ago

Hi @j13k, thanks for bringing this to our attention. Message validation for SNS has indeed been moved to a separate package, we'll work on updating our documentation to reflect this change. While we cannot make changes to the SNS developer guide, I'll be reaching out to their docs team internally to have the page you mention updated to highlight the requirement of this package for message validation using the AWS SDK for PHP.

j13k commented 4 years ago

Thanks for responding so promptly @diehlaws. I did discover that information about the separate package, but only after stumbling upon the discussion in issue #625 via a general web search.

As a more general comment, it would be great if the documentation could be regenerated/updated whenever a new release of the SDK is minted. As you can imagine, it's frustrating when the docs aren't in parity with the code they're describing, and clearly these SNS message classes haven't been available in the main package for quite some time.

Thanks again for your help.

jmcgrory commented 3 years ago

I agree with @j13k here, the documentation is possibly intentionally vague to allow for changes in the API?

When possible, use one of the supported AWS SDKs for Amazon SNS to validate and verify messages. For example, with the AWS SDK for PHP you would use the isValid method from the MessageValidator class.

From the above it seems that this would be available in "the AWS SDK for PHP" (or even in multiple "use one of"). However it appears to now be in a separate/dedicated ancilliary package.

ameotoko commented 2 years ago

No progress😁

github-actions[bot] commented 1 year ago

We have noticed this issue has not recieved attention in 1 year. We will close this issue for now. If you think this is in error, please feel free to comment and reopen the issue.

j13k commented 1 year ago

We have noticed this issue has not recieved attention in 1 year. We will close this issue for now. If you think this is in error, please feel free to comment and reopen the issue.

The published documentation still seems to be out-of-date.