Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow request verification using req.rawBody #758

Closed
4 of 9 tasks
shaydewael opened this issue Mar 28, 2019 · 0 comments · Fixed by #844
Closed
4 of 9 tasks

Allow request verification using req.rawBody #758

shaydewael opened this issue Mar 28, 2019 · 0 comments · Fixed by #844
Labels
enhancement M-T: A feature request for new functionality pkg:interactive-messages (deprecated) applies to `@slack/interactive-messages`

Comments

@shaydewael
Copy link
Contributor

Description

Created from slackapi/node-slack-interactive-messages#91

Description
Some hosting platforms (like Firebase Cloud) always parse the request body, and create the req.body property for convenience. Unfortunately, this prevents this library from being able to verify requests. However, there's a convention of placing the unparsed (but buffered) body on the req.rawBody property instead.

Using req.rawBody as a fallback for req.body during verification would allow users to deploy code using this package to more hosting platforms.

NOTE: We can probably just port the work from slackapi/node-slack-events-api#90 into the interactive-messages package

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.
@shaydewael shaydewael added enhancement M-T: A feature request for new functionality pkg:interactive-messages (deprecated) applies to `@slack/interactive-messages` labels Mar 28, 2019
troysteinbauer added a commit to troysteinbauer/node-slack-sdk that referenced this issue Jun 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement M-T: A feature request for new functionality pkg:interactive-messages (deprecated) applies to `@slack/interactive-messages`
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant