Skip to content

Conversation

@kristianjaeger
Copy link
Contributor

@kristianjaeger kristianjaeger commented Jan 29, 2021

For example in C# you may need to use Encoding.UTF8.GetBytes(payload) instead of Encoding.ASCII.GetBytes(payload). Thanks. Cheers.

Why:

What's being changed:

Check off the following:

For example in C# you may need to use Encoding.UTF8.GetBytes(payload) instead of Encoding.ASCII.GetBytes(payload). Thanks. Cheers.
@welcome
Copy link

welcome bot commented Jan 29, 2021

Thanks for opening this pull request! A GitHub docs team member should be by to give feedback soon. In the meantime, please check out the contributing guidelines.

@kristianjaeger
Copy link
Contributor Author

@The-Pharoah Yes, this is related to securing the web hook. For someone to properly validate the web hook they need to treat the payload as unicode. Otherwise if there's a unicode character in the webhook JSON the signature will not be validated properly. A few examples of how this can happen are 1) if there's a long merge commit title GitHub automatically puts a "..." unicode character in the message field of the JSON, 2) if someone's name has unicode characters, or 3) if someone uses unicode characters in their pull request title. Cheers.

@janiceilene
Copy link
Contributor

@kristianjaeger Thanks so much for opening a PR! I'll get this triaged for review ⚡

@janiceilene janiceilene added content This issue or pull request belongs to the Docs Content team ecosystem This issue or pull request should be reviewed by the Docs Ecosystem team labels Feb 1, 2021
@kristianjaeger
Copy link
Contributor Author

Thanks, @janiceilene !

@janiceilene janiceilene added the waiting for review Issue/PR is waiting for a writer's review label Feb 5, 2021
@lucascosti lucascosti self-assigned this Feb 10, 2021
@lucascosti lucascosti dismissed a stale review via f69d036 February 10, 2021 06:56
Copy link
Contributor

@lucascosti lucascosti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot for this contribution, @kristianjaeger! 🙇‍♂️

I've reworded the new encoding note and separated it into a separate block closer to the complete code example.

I'll get this merged in! 🎉

@lucascosti lucascosti enabled auto-merge (squash) February 10, 2021 07:02
@lucascosti lucascosti merged commit f61b9a7 into github:main Feb 10, 2021
@github-actions
Copy link
Contributor

Thanks very much for contributing! Your pull request has been merged 🎉 You should see your changes appear on the site in approximately 24 hours.

@kristianjaeger
Copy link
Contributor Author

Thanks so much, @lucascosti and @janiceilene ! Cheers.

@kristianjaeger kristianjaeger deleted the patch-1 branch February 10, 2021 15:33
Dmarch28 pushed a commit to Dmarch28/docs that referenced this pull request Mar 4, 2021
Co-authored-by: Lucas Costi <lucascosti@users.noreply.github.com>
Dmarch28 pushed a commit to Provider-of-Algorithms/docs that referenced this pull request Mar 7, 2021
Co-authored-by: Lucas Costi <lucascosti@users.noreply.github.com>
Dmarch28 pushed a commit to Provider-of-Algorithms/docs that referenced this pull request Mar 7, 2021
Co-authored-by: Lucas Costi <lucascosti@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

content This issue or pull request belongs to the Docs Content team ecosystem This issue or pull request should be reviewed by the Docs Ecosystem team waiting for review Issue/PR is waiting for a writer's review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants